Fix handling of unused attachments in dynamic rendering. Closes #2432

This commit is contained in:
baldurk committed 2022-01-10 14:05:51 +00:00
1 parent 27d26834f5
commit cc2d49ad1c
2 files changed
+2 -2

No files matched your search

+1 -1
View File
@@ -1103,7 +1103,7 @@ size_t GetNextPatchSize(const void *pNext)
if(info->pDepthAttachment)
{
memSize += sizeof(*info->pDepthAttachment);
memSize += GetNextPatchSize(info->pStencilAttachment->pNext);
memSize += GetNextPatchSize(info->pDepthAttachment->pNext);
}
if(info->pStencilAttachment)
{
@@ -6920,7 +6920,7 @@ void WrappedVulkan::vkCmdBeginRenderingKHR(VkCommandBuffer commandBuffer,
else if(i == pRenderingInfo->colorAttachmentCount + 1)
att = pRenderingInfo->pStencilAttachment;
if(!att)
if(!att || !att->imageView)
continue;
FrameRefType refType = eFrameRef_ReadBeforeWrite;