VideoBackends/D3D12: Include HRESULT in error messages

This commit is contained in:
Pokechu22
2021-12-12 13:18:39 -08:00
parent 23cdb5c576
commit 1b32e6dae2
11 changed files with 77 additions and 36 deletions

View File

@ -34,7 +34,7 @@ bool SwapChain::CreateSwapChainBuffers()
{
ComPtr<ID3D12Resource> resource;
HRESULT hr = m_swap_chain->GetBuffer(i, IID_PPV_ARGS(&resource));
ASSERT_MSG(VIDEO, SUCCEEDED(hr), "Failed to get swap chain buffer {}", i);
ASSERT_MSG(VIDEO, SUCCEEDED(hr), "Failed to get swap chain buffer {}: {}", i, DX12HRWrap(hr));
BufferResources buffer;
buffer.texture = DXTexture::CreateAdopted(resource.Get());