diff options
| author | assiduous <assiduous@diligentgraphics.com> | 2020-08-03 05:38:31 +0000 |
|---|---|---|
| committer | assiduous <assiduous@diligentgraphics.com> | 2020-08-03 05:38:31 +0000 |
| commit | b10979c67bf9a2c49f46e01873a2cac1e44bc97a (patch) | |
| tree | 87a72136ac06621caa34c794642216b72a0dc551 /Graphics/GraphicsEngine | |
| parent | Added another framebuffer validation check (diff) | |
| download | DiligentCore-b10979c67bf9a2c49f46e01873a2cac1e44bc97a.tar.gz DiligentCore-b10979c67bf9a2c49f46e01873a2cac1e44bc97a.zip | |
Few more updated to render pass desc validation
Diffstat (limited to 'Graphics/GraphicsEngine')
| -rw-r--r-- | Graphics/GraphicsEngine/src/RenderPassBase.cpp | 16 |
1 files changed, 12 insertions, 4 deletions
diff --git a/Graphics/GraphicsEngine/src/RenderPassBase.cpp b/Graphics/GraphicsEngine/src/RenderPassBase.cpp index 683d86aa..a0548e4d 100644 --- a/Graphics/GraphicsEngine/src/RenderPassBase.cpp +++ b/Graphics/GraphicsEngine/src/RenderPassBase.cpp @@ -87,7 +87,9 @@ void ValidateRenderPassDesc(const RenderPassDesc& Desc) Attachment.InitialState != RESOURCE_STATE_UNORDERED_ACCESS && Attachment.InitialState != RESOURCE_STATE_SHADER_RESOURCE && Attachment.InitialState != RESOURCE_STATE_RESOLVE_DEST && - Attachment.InitialState != RESOURCE_STATE_RESOLVE_SOURCE) + Attachment.InitialState != RESOURCE_STATE_RESOLVE_SOURCE && + Attachment.InitialState != RESOURCE_STATE_COPY_DEST && + Attachment.InitialState != RESOURCE_STATE_COPY_SOURCE) { LOG_RENDER_PASS_ERROR_AND_THROW("the initial state of depth-stencil attachment ", i, " (", GetResourceStateString(Attachment.InitialState), ") is invalid."); } @@ -97,7 +99,9 @@ void ValidateRenderPassDesc(const RenderPassDesc& Desc) Attachment.FinalState != RESOURCE_STATE_UNORDERED_ACCESS && Attachment.FinalState != RESOURCE_STATE_SHADER_RESOURCE && Attachment.FinalState != RESOURCE_STATE_RESOLVE_DEST && - Attachment.FinalState != RESOURCE_STATE_RESOLVE_SOURCE) + Attachment.FinalState != RESOURCE_STATE_RESOLVE_SOURCE && + Attachment.FinalState != RESOURCE_STATE_COPY_DEST && + Attachment.FinalState != RESOURCE_STATE_COPY_SOURCE) { LOG_RENDER_PASS_ERROR_AND_THROW("the final state of depth-stencil attachment ", i, " (", GetResourceStateString(Attachment.FinalState), ") is invalid."); } @@ -108,7 +112,9 @@ void ValidateRenderPassDesc(const RenderPassDesc& Desc) Attachment.InitialState != RESOURCE_STATE_UNORDERED_ACCESS && Attachment.InitialState != RESOURCE_STATE_SHADER_RESOURCE && Attachment.InitialState != RESOURCE_STATE_RESOLVE_DEST && - Attachment.InitialState != RESOURCE_STATE_RESOLVE_SOURCE) + Attachment.InitialState != RESOURCE_STATE_RESOLVE_SOURCE && + Attachment.InitialState != RESOURCE_STATE_COPY_SOURCE && + Attachment.InitialState != RESOURCE_STATE_PRESENT) { LOG_RENDER_PASS_ERROR_AND_THROW("the initial state of color attachment ", i, " (", GetResourceStateString(Attachment.InitialState), ") is invalid."); } @@ -117,7 +123,9 @@ void ValidateRenderPassDesc(const RenderPassDesc& Desc) Attachment.FinalState != RESOURCE_STATE_UNORDERED_ACCESS && Attachment.FinalState != RESOURCE_STATE_SHADER_RESOURCE && Attachment.FinalState != RESOURCE_STATE_RESOLVE_DEST && - Attachment.FinalState != RESOURCE_STATE_RESOLVE_SOURCE) + Attachment.FinalState != RESOURCE_STATE_RESOLVE_SOURCE && + Attachment.FinalState != RESOURCE_STATE_COPY_SOURCE && + Attachment.FinalState != RESOURCE_STATE_PRESENT) { LOG_RENDER_PASS_ERROR_AND_THROW("the final state of color attachment ", i, " (", GetResourceStateString(Attachment.FinalState), ") is invalid."); } |
