diff --git a/renderdoc/driver/vulkan/vk_resources.h b/renderdoc/driver/vulkan/vk_resources.h index 40a818850..c4fd994fa 100644 --- a/renderdoc/driver/vulkan/vk_resources.h +++ b/renderdoc/driver/vulkan/vk_resources.h @@ -806,7 +806,7 @@ struct VkResourceRecord : public ResourceRecord VkResourceRecord *bakedCommands; - static const int MaxImageAttachments = 8; + static const int MaxImageAttachments = 9; // 8 Colour and 1 Depth // pointer to either the pool this item is allocated from, or the children allocated // from this pool. Protected by the chunk lock diff --git a/renderdoc/driver/vulkan/wrappers/vk_misc_funcs.cpp b/renderdoc/driver/vulkan/wrappers/vk_misc_funcs.cpp index 638f4edf2..3c33116f5 100644 --- a/renderdoc/driver/vulkan/wrappers/vk_misc_funcs.cpp +++ b/renderdoc/driver/vulkan/wrappers/vk_misc_funcs.cpp @@ -495,7 +495,7 @@ VkResult WrappedVulkan::vkCreateFramebuffer( record->AddChunk(chunk); record->imageAttachments = new VkResourceRecord*[VkResourceRecord::MaxImageAttachments]; - RDCASSERT(pCreateInfo->attachmentCount < VkResourceRecord::MaxImageAttachments); + RDCASSERT(pCreateInfo->attachmentCount <= VkResourceRecord::MaxImageAttachments); RDCEraseMem(record->imageAttachments, sizeof(ResourceId)*VkResourceRecord::MaxImageAttachments);