diff --git a/renderdoc/driver/d3d12/d3d12_outputwindow.cpp b/renderdoc/driver/d3d12/d3d12_outputwindow.cpp index 8a9e63107..7b6f8deed 100644 --- a/renderdoc/driver/d3d12/d3d12_outputwindow.cpp +++ b/renderdoc/driver/d3d12/d3d12_outputwindow.cpp @@ -71,14 +71,14 @@ void D3D12Replay::OutputWindow::MakeRTV(bool msaa) D3D12_RESOURCE_STATE_RENDER_TARGET, NULL, __uuidof(ID3D12Resource), (void **)&col); - col->SetName(L"Output Window RTV"); - if(FAILED(hr)) { RDCERR("Failed to create colour texture for window, HRESULT: %s", ToStr(hr).c_str()); return; } + col->SetName(L"Output Window RTV"); + colResolve = NULL; if(msaa && D3D12_MSAA_SAMPLECOUNT > 1) @@ -89,13 +89,13 @@ void D3D12Replay::OutputWindow::MakeRTV(bool msaa) D3D12_RESOURCE_STATE_COPY_SOURCE, NULL, __uuidof(ID3D12Resource), (void **)&colResolve); - colResolve->SetName(L"Output Window Resolve"); - if(FAILED(hr)) { RDCERR("Failed to create resolve texture for window, HRESULT: %s", ToStr(hr).c_str()); return; } + + colResolve->SetName(L"Output Window Resolve"); } dev->CreateRenderTargetView(col, NULL, rtv); @@ -134,14 +134,14 @@ void D3D12Replay::OutputWindow::MakeDSV() D3D12_RESOURCE_STATE_DEPTH_WRITE, NULL, __uuidof(ID3D12Resource), (void **)&depth); - depth->SetName(L"Output Window Depth"); - if(FAILED(hr)) { RDCERR("Failed to create DSV texture for output window, HRESULT: %s", ToStr(hr).c_str()); return; } + depth->SetName(L"Output Window Depth"); + dev->CreateDepthStencilView(depth, NULL, dsv); if(FAILED(hr))