mirror of
https://github.com/microsoft/DirectXTex
synced 2024-11-21 20:10:05 +00:00
ScreenGrab12 missing some error handling
This commit is contained in:
parent
ca423ddeb2
commit
ccbaeb528d
@ -764,13 +764,17 @@ namespace
|
||||
// Transition the resource to the next state
|
||||
TransitionResource(commandList.Get(), pSource, D3D12_RESOURCE_STATE_COPY_SOURCE, afterState);
|
||||
|
||||
commandList->Close();
|
||||
hr = commandList->Close();
|
||||
if (FAILED(hr))
|
||||
return hr;
|
||||
|
||||
// Execute the command list
|
||||
pCommandQ->ExecuteCommandLists(1, (ID3D12CommandList**)commandList.GetAddressOf());
|
||||
|
||||
// Signal the fence
|
||||
pCommandQ->Signal(fence.Get(), 1);
|
||||
hr = pCommandQ->Signal(fence.Get(), 1);
|
||||
if (FAILED(hr))
|
||||
return hr;
|
||||
|
||||
// Block until the copy is complete
|
||||
while (fence->GetCompletedValue() < 1)
|
||||
|
Loading…
Reference in New Issue
Block a user