diff options
| author | Tobin Ehlis <tobine@google.com> | 2017-09-06 13:27:52 -0600 |
|---|---|---|
| committer | Tobin Ehlis <tobine@google.com> | 2017-09-07 14:32:12 -0600 |
| commit | 826819e74fce3dc553a141bf9fc05e88713d16c1 (patch) | |
| tree | 8d08a04190f4b19b084097f07dcd94bb4ecd56f9 /layers/core_validation.cpp | |
| parent | 8b765c6e32913177b3582d35135d40496edbdc65 (diff) | |
| download | usermoji-826819e74fce3dc553a141bf9fc05e88713d16c1.tar.xz | |
layers:Migrate render pass compatibility check
Update render pass compatibility check at BeginCommandBuffer time to
use the refactored common function. Phasing out the other compatibility
function.
Diffstat (limited to 'layers/core_validation.cpp')
| -rw-r--r-- | layers/core_validation.cpp | 19 |
1 files changed, 5 insertions, 14 deletions
diff --git a/layers/core_validation.cpp b/layers/core_validation.cpp index 71d8ee02..c2ebffd1 100644 --- a/layers/core_validation.cpp +++ b/layers/core_validation.cpp @@ -5093,21 +5093,12 @@ VKAPI_ATTR VkResult VKAPI_CALL BeginCommandBuffer(VkCommandBuffer commandBuffer, string errorString = ""; auto framebuffer = GetFramebufferState(dev_data, pInfo->framebuffer); if (framebuffer) { - if ((framebuffer->createInfo.renderPass != pInfo->renderPass) && - !verify_renderpass_compatibility(dev_data, framebuffer->rp_state->createInfo.ptr(), - GetRenderPassState(dev_data, pInfo->renderPass)->createInfo.ptr(), - errorString)) { + if (framebuffer->createInfo.renderPass != pInfo->renderPass) { // renderPass that framebuffer was created with must be compatible with local renderPass - skip |= log_msg(dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, - VK_DEBUG_REPORT_OBJECT_TYPE_COMMAND_BUFFER_EXT, HandleToUint64(commandBuffer), __LINE__, - VALIDATION_ERROR_0280006e, "DS", - "vkBeginCommandBuffer(): Secondary Command " - "Buffer (0x%p) renderPass (0x%" PRIxLEAST64 - ") is incompatible w/ framebuffer " - "(0x%" PRIxLEAST64 ") w/ render pass (0x%" PRIxLEAST64 ") due to: %s. %s", - commandBuffer, HandleToUint64(pInfo->renderPass), HandleToUint64(pInfo->framebuffer), - HandleToUint64(framebuffer->createInfo.renderPass), errorString.c_str(), - validation_error_map[VALIDATION_ERROR_0280006e]); + skip |= + validateRenderPassCompatibility(dev_data, "framebuffer", framebuffer->rp_state, "command buffer", + GetRenderPassState(dev_data, pInfo->renderPass), + "vkBeginCommandBuffer()", VALIDATION_ERROR_0280006e); } // Connect this framebuffer and its children to this cmdBuffer AddFramebufferBinding(dev_data, cb_node, framebuffer); |
