From f9fd3e5fecc63bebc68900ea6799d1ec6b1d14dd Mon Sep 17 00:00:00 2001 From: illusion0001 <37698908+illusion0001@users.noreply.github.com> Date: Wed, 21 Oct 2020 08:32:09 -0500 Subject: [PATCH] AVPack cvar --- src/xenia/kernel/xam/xam_info.cc | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/xenia/kernel/xam/xam_info.cc b/src/xenia/kernel/xam/xam_info.cc index 0bfe7c97b..5662ebe11 100644 --- a/src/xenia/kernel/xam/xam_info.cc +++ b/src/xenia/kernel/xam/xam_info.cc @@ -7,6 +7,7 @@ ****************************************************************************** */ +#include "xenia/base/cvar.h" #include "xenia/base/logging.h" #include "xenia/base/string_util.h" #include "xenia/kernel/kernel_state.h" @@ -24,6 +25,8 @@ #include "third_party/fmt/include/fmt/format.h" +DEFINE_int32(avpack, 8, "Video modes", "Video"); + namespace xe { namespace kernel { namespace xam { @@ -191,12 +194,13 @@ void XCustomRegisterDynamicActions_entry() { DECLARE_XAM_EXPORT1(XCustomRegisterDynamicActions, kNone, kStub); dword_result_t XGetAVPack_entry() { + // Value from https://github.com/Free60Project/libxenon/blob/920146f/libxenon/drivers/xenos/xenos_videomodes.h // DWORD // Not sure what the values are for this, but 6 is VGA. // Other likely values are 3/4/8 for HDMI or something. // Games seem to use this as a PAL check - if the result is not 3/4/6/8 // they explode with errors if not in PAL mode. - return 6; + return (cvars::avpack); } DECLARE_XAM_EXPORT1(XGetAVPack, kNone, kStub);