diff options
-rw-r--r-- | src/gallium/state_trackers/d3d1x/dxgi/src/dxgi_native.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/gallium/state_trackers/d3d1x/dxgi/src/dxgi_native.cpp b/src/gallium/state_trackers/d3d1x/dxgi/src/dxgi_native.cpp index 3cbe056e7b6..2149d83a9c6 100644 --- a/src/gallium/state_trackers/d3d1x/dxgi/src/dxgi_native.cpp +++ b/src/gallium/state_trackers/d3d1x/dxgi/src/dxgi_native.cpp @@ -1381,7 +1381,11 @@ void STDMETHODCALLTYPE GalliumDXGIUseHDC(HDC hdc, PFNHWNDRESOLVER resolver, void */ void STDMETHODCALLTYPE GalliumDXGIMakeDefault() { + if(dxgi_default_binding.backend) + dxgi_default_binding.backend->Release(); dxgi_default_binding = dxgi_thread_binding; + if(dxgi_default_binding.backend) + dxgi_default_binding.backend->AddRef(); } /* TODO: why did Microsoft add this? should we do something different for DXGI 1.0 and 1.1? |