From 6c0f026824b73384c96740abd6180c0025a05843 Mon Sep 17 00:00:00 2001 From: Margen67 Date: Fri, 18 Oct 2024 12:46:34 -0700 Subject: [PATCH] [GPU] Fix internal_display_resolution condition --- src/xenia/gpu/graphics_system.cc | 46 ++++++++++++++++---------------- 1 file changed, 23 insertions(+), 23 deletions(-) diff --git a/src/xenia/gpu/graphics_system.cc b/src/xenia/gpu/graphics_system.cc index 76a3aec55..603bf9e7b 100644 --- a/src/xenia/gpu/graphics_system.cc +++ b/src/xenia/gpu/graphics_system.cc @@ -30,27 +30,27 @@ #include "xenia/ui/window.h" #include "xenia/ui/windowed_app_context.h" -DEFINE_int32(internal_display_resolution, 8, - "Allow game that support different resolutions to be rendered " - "in specific resolution.\n" - " 0=640x480\n" - " 1=640x576\n" - " 2=720x480\n" - " 3=720x576\n" - " 4=800x600\n" - " 5=848x480\n" - " 6=1024x768\n" - " 7=1152x864\n" - " 8=1280x720 (Default)\n" - " 9=1280x768\n" - " 10=1280x960\n" - " 11=1280x1024\n" - " 12=1360x768\n" - " 13=1440x900\n" - " 14=1680x1050\n" - " 15=1920x540\n" - " 16=1920x1080\n", - "Video"); +DEFINE_uint32(internal_display_resolution, 8, + "Allow games that support different resolutions to render " + "in a specific resolution.\n" + " 0=640x480\n" + " 1=640x576\n" + " 2=720x480\n" + " 3=720x576\n" + " 4=800x600\n" + " 5=848x480\n" + " 6=1024x768\n" + " 7=1152x864\n" + " 8=1280x720 (Default)\n" + " 9=1280x768\n" + " 10=1280x960\n" + " 11=1280x1024\n" + " 12=1360x768\n" + " 13=1440x900\n" + " 14=1680x1050\n" + " 15=1920x540\n" + " 16=1920x1080\n", + "Video"); DEFINE_bool( store_shaders, true, @@ -406,7 +406,7 @@ bool GraphicsSystem::Restore(ByteStream* stream) { } std::pair GraphicsSystem::GetInternalDisplayResolution() { - if (cvars::internal_display_resolution > + if (cvars::internal_display_resolution >= internal_display_resolution_entries.size()) { return internal_display_resolution_entries[8]; } @@ -415,4 +415,4 @@ std::pair GraphicsSystem::GetInternalDisplayResolution() { } } // namespace gpu -} // namespace xe \ No newline at end of file +} // namespace xe