mirror of
https://github.com/RetroDECK/Duckstation.git
synced 2024-11-22 22:05:38 +00:00
System: Fix crash toggling debug GPU device
When postfx is enabled.
This commit is contained in:
parent
c0e6750ad3
commit
480c78502f
|
@ -900,7 +900,10 @@ bool System::RecreateGPU(GPURenderer renderer, bool force_recreate_device, bool
|
|||
// create new renderer
|
||||
g_gpu.reset();
|
||||
if (force_recreate_device)
|
||||
{
|
||||
PostProcessing::Shutdown();
|
||||
Host::ReleaseGPUDevice();
|
||||
}
|
||||
|
||||
if (!CreateGPU(renderer, true))
|
||||
{
|
||||
|
@ -2042,6 +2045,7 @@ bool System::CreateGPU(GPURenderer renderer, bool is_switching)
|
|||
Log_ErrorPrintf("Failed to create fallback software renderer.");
|
||||
if (!s_keep_gpu_device_on_shutdown)
|
||||
{
|
||||
PostProcessing::Shutdown();
|
||||
Host::ReleaseGPUDevice();
|
||||
Host::ReleaseRenderWindow();
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue