diff options
| author | Tobin Ehlis <tobine@google.com> | 2016-06-22 16:12:58 -0600 |
|---|---|---|
| committer | Tobin Ehlis <tobine@google.com> | 2016-06-23 13:49:43 -0600 |
| commit | 7bf94579ca98332a4e1dd13db3ecb54c08cdebbf (patch) | |
| tree | 21b53a0f9265a5329dda83712fa6434eb90e0db6 /layers/core_validation.cpp | |
| parent | f6df420d230f3f0de7f16b084896074015ec10a8 (diff) | |
| download | usermoji-7bf94579ca98332a4e1dd13db3ecb54c08cdebbf.tar.xz | |
layers: Add INVALID_FRAMEBUFFER_CREATE_INFO error
Added new error enum DRAWSTATE_INVALID_FRAMEBUFFER_CREATE_INFO
and added initial check with this enum type that flags and error
if framebuffer attachment has non-1 mip levelCount.
Diffstat (limited to 'layers/core_validation.cpp')
| -rw-r--r-- | layers/core_validation.cpp | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/layers/core_validation.cpp b/layers/core_validation.cpp index 82050326..b8c69161 100644 --- a/layers/core_validation.cpp +++ b/layers/core_validation.cpp @@ -8274,11 +8274,16 @@ static bool ValidateFramebufferCreateInfo(layer_data *dev_data, const VkFramebuf i, string_VkSampleCountFlagBits(ici->samples), string_VkSampleCountFlagBits(rpci->pAttachments[i].samples), reinterpret_cast<const uint64_t &>(pCreateInfo->renderPass)); } -#if 0 // Enabling 1 new check/test at a time // Verify that view only has a single mip level if (ivci->subresourceRange.levelCount != 1) { - // TODO + skip_call |= log_msg( + dev_data->report_data, VK_DEBUG_REPORT_ERROR_BIT_EXT, VK_DEBUG_REPORT_OBJECT_TYPE_RENDER_PASS_EXT, + reinterpret_cast<const uint64_t &>(pCreateInfo->renderPass), __LINE__, DRAWSTATE_INVALID_FRAMEBUFFER_CREATE_INFO, + "DS", "vkCreateFramebuffer(): VkFramebufferCreateInfo attachment #%u has mip levelCount of %u " + "but only a single mip level (levelCount == 1) is allowed when creating a Framebuffer.", + i, ivci->subresourceRange.levelCount); } +#if 0 // Enabling 1 new check/test at a time const uint32_t mip_level = ivci->subresourceRange.baseMipLevel; if ((ivci->subresourceRange.layerCount < pCreateInfo->layers) || ((ici->extent.width >> mip_level) < pCreateInfo->width) || |
