Free swapchain RTV before allocating new one

This commit is contained in:
baldurk
2019-09-19 16:47:57 +01:00
parent 3f9e3e3c94
commit 1f67022280
2 changed files with 2 additions and 1 deletions
+1
View File
@@ -1035,6 +1035,7 @@ IUnknown *WrappedID3D12Device::WrapSwapchainBuffer(IDXGISwapper *swapper, DXGI_F
if(rtv.ptr != 0)
CreateRenderTargetView(pRes, NULL, rtv);
FreeRTV(m_SwapChains[swapper].rtvs[buffer]);
m_SwapChains[swapper].rtvs[buffer] = rtv;
ID3DDevice *swapQ = swapper->GetD3DDevice();
+1 -1
View File
@@ -428,7 +428,7 @@ private:
struct SwapPresentInfo
{
D3D12_CPU_DESCRIPTOR_HANDLE rtvs[8];
D3D12_CPU_DESCRIPTOR_HANDLE rtvs[8] = {};
WrappedID3D12CommandQueue *queue;
};