System: Fix bogus SW thread CPU in OSD

This commit is contained in:
Stenzek
2024-09-21 16:15:07 +10:00
parent e617f17294
commit ac8461a28b
5 changed files with 15 additions and 8 deletions

View File

@ -5717,6 +5717,13 @@ void System::ToggleSoftwareRendering()
Settings::GetRendererDisplayName(new_renderer)),
Host::OSD_QUICK_DURATION);
RecreateGPU(new_renderer);
// Might have a thread change.
if (const Threading::Thread* sw_thread = g_gpu->GetSWThread(); sw_thread)
s_last_sw_time = sw_thread->GetCPUTime();
else
s_last_sw_time = 0;
g_gpu->UpdateResolutionScale();
}