Merge pull request #3389 from stenzek/d3d-fb-crash-fix

D3D: Fix crash on startup/resize
This commit is contained in:
Pierre Bourdon 2015-12-23 14:21:02 +01:00
commit 3250d80d21
1 changed files with 1 additions and 0 deletions

View File

@ -1000,6 +1000,7 @@ void Renderer::SwapImpl(u32 xfbAddr, u32 fbWidth, u32 fbStride, u32 fbHeight, co
D3D::context->OMSetRenderTargets(1, &D3D::GetBackBuffer()->GetRTV(), nullptr);
g_framebuffer_manager.reset();
g_framebuffer_manager = std::make_unique<FramebufferManager>();
float clear_col[4] = { 0.f, 0.f, 0.f, 1.f };
D3D::context->ClearRenderTargetView(FramebufferManager::GetEFBColorTexture()->GetRTV(), clear_col);