diff options
| author | Egor Yusov <egor.yusov@gmail.com> | 2019-04-25 06:14:27 +0000 |
|---|---|---|
| committer | Egor Yusov <egor.yusov@gmail.com> | 2019-04-25 06:14:27 +0000 |
| commit | eaf444aa176db2631c0a5ad6fa718026eb01fcfe (patch) | |
| tree | 514cd2c2599c88dcb83e2d72c69367fac7d132a0 /Graphics/GraphicsEngineD3D12 | |
| parent | Added IShaderResourceVariable::IsBound method (updated API version to 240024) (diff) | |
| download | DiligentCore-eaf444aa176db2631c0a5ad6fa718026eb01fcfe.tar.gz DiligentCore-eaf444aa176db2631c0a5ad6fa718026eb01fcfe.zip | |
Improved error messages about incorrect resource states specified in the barrier
Diffstat (limited to 'Graphics/GraphicsEngineD3D12')
| -rw-r--r-- | Graphics/GraphicsEngineD3D12/src/CommandContext.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/Graphics/GraphicsEngineD3D12/src/CommandContext.cpp b/Graphics/GraphicsEngineD3D12/src/CommandContext.cpp index ef79ba3d..e1f0b473 100644 --- a/Graphics/GraphicsEngineD3D12/src/CommandContext.cpp +++ b/Graphics/GraphicsEngineD3D12/src/CommandContext.cpp @@ -180,7 +180,10 @@ void CommandContext::TransitionResource(const StateTransitionDesc& Barrier) } else { - DEV_CHECK_ERR(Barrier.OldState == RESOURCE_STATE_UNKNOWN || Barrier.OldState == OldState, "Resource state is known (", OldState, ") and does not match OldState (", Barrier.OldState, ") specified in resource barrier. Set OldState member to RESOURCE_STATE_UNKNOWN to make the engine use current resource state"); + DEV_CHECK_ERR(Barrier.OldState == RESOURCE_STATE_UNKNOWN || Barrier.OldState == OldState, + "Resource state is known (", GetResourceStateString(OldState), ") and does not match the OldState (", + GetResourceStateString(Barrier.OldState), ") specified in the resource barrier. Set OldState member to " + "RESOURCE_STATE_UNKNOWN to make the engine use current resource state"); } // Check if required state is already set |
