GPU/HW: Rewrite automatic internal resolution selection

Make it aspect ratio aware, as well as updating when/if the game changes
resolution. Also include the padding area in the OSD/status resolution.
This commit is contained in:
Stenzek
2024-09-20 20:08:01 +10:00
parent e056bcb5ff
commit b5df06a54a
8 changed files with 71 additions and 56 deletions

View File

@@ -2005,7 +2005,12 @@ void EmuThread::updatePerformanceCounters()
u32 render_height = 0;
if (g_gpu)
std::tie(render_width, render_height) = g_gpu->GetEffectiveDisplayResolution();
{
const u32 render_scale = g_gpu->GetResolutionScale();
std::tie(render_width, render_height) = g_gpu->GetFullDisplayResolution();
render_width *= render_scale;
render_height *= render_scale;
}
if (render_api != m_last_render_api || hardware_renderer != m_last_hardware_renderer)
{