mirror of
https://github.com/PCSX2/pcsx2.git
synced 2026-10-12 02:08:45 +00:00
Qt/OSD: Fix GPU stats not updating when Show GPU Usage settings arent enabled
This commit is contained in:
+4
-3
@@ -161,7 +161,8 @@ static bool OpenGSDevice(GSRendererType renderer, bool clear_state_on_fail, bool
|
||||
return false;
|
||||
}
|
||||
|
||||
GSConfig.OsdShowGPU = GSConfig.OsdShowGPU && g_gs_device->SetGPUTimingEnabled(true);
|
||||
if (!g_gs_device->SetGPUTimingEnabled(true))
|
||||
GSConfig.OsdShowGPU = false;
|
||||
|
||||
Console.WriteLn(Color_StrongGreen, "%s Graphics Driver Info:", GSDevice::RenderAPIToString(new_api));
|
||||
Console.WriteLn(g_gs_device->GetDriverInfo());
|
||||
@@ -878,9 +879,9 @@ void GSUpdateConfig(const Pcsx2Config::GSOptions& new_config)
|
||||
g_gs_renderer->PurgeTextureCache(true, false, true);
|
||||
}
|
||||
|
||||
if (GSConfig.OsdShowGPU != old_config.OsdShowGPU)
|
||||
if (GSConfig.OsdShowGPU && !old_config.OsdShowGPU)
|
||||
{
|
||||
if (!g_gs_device->SetGPUTimingEnabled(GSConfig.OsdShowGPU))
|
||||
if (!g_gs_device->SetGPUTimingEnabled(true))
|
||||
GSConfig.OsdShowGPU = false;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -700,8 +700,7 @@ void GSRenderer::VSync(u32 field, bool registers_written, bool idle_frame)
|
||||
|
||||
EndPresentFrame();
|
||||
|
||||
if (GSConfig.OsdShowGPU || GSDumpReplayer::IsReplayingDump())
|
||||
PerformanceMetrics::OnGPUPresent(g_gs_device->GetAndResetAccumulatedGPUTime());
|
||||
PerformanceMetrics::OnGPUPresent(g_gs_device->GetAndResetAccumulatedGPUTime());
|
||||
}
|
||||
|
||||
PerformanceMetrics::Update(registers_written, fb_sprite_frame, false);
|
||||
|
||||
Reference in New Issue
Block a user