From 449d28aab53abf93e97f860f33921d79e517c9a1 Mon Sep 17 00:00:00 2001 From: Tobin Ehlis Date: Tue, 9 May 2017 10:22:14 -0600 Subject: layers:Fix cut-and-paste bug From Mikko at Unity, there was a cut-and-paste bug here where color counts were being used to check input attachments. Use input counts instead. --- layers/core_validation.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'layers/core_validation.cpp') diff --git a/layers/core_validation.cpp b/layers/core_validation.cpp index 7c6beeb8..1fb4b52d 100644 --- a/layers/core_validation.cpp +++ b/layers/core_validation.cpp @@ -1992,9 +1992,9 @@ static bool verify_renderpass_compatibility(const layer_data *dev_data, const Vk uint32_t secondaryInputCount = secondaryRPCI->pSubpasses[spIndex].inputAttachmentCount; uint32_t inputMax = std::max(primaryInputCount, secondaryInputCount); for (uint32_t i = 0; i < inputMax; ++i) { - if (!attachment_references_compatible(i, primaryRPCI->pSubpasses[spIndex].pInputAttachments, primaryColorCount, + if (!attachment_references_compatible(i, primaryRPCI->pSubpasses[spIndex].pInputAttachments, primaryInputCount, primaryRPCI->pAttachments, secondaryRPCI->pSubpasses[spIndex].pInputAttachments, - secondaryColorCount, secondaryRPCI->pAttachments)) { + secondaryInputCount, secondaryRPCI->pAttachments)) { stringstream errorStr; errorStr << "input attachments at index " << i << " of subpass index " << spIndex << " are not compatible."; errorMsg = errorStr.str(); -- cgit v1.2.3