Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bogus width and height check in vkCmdBeginRenderPass with KHR_imageless_framebuffer #2503

Closed
kvark opened this issue Jan 26, 2021 · 2 comments

Comments

@kvark
Copy link

kvark commented Jan 26, 2021

Describe the Issue
The code is rendering to mipmap levels of an image, using KHR_imageless_framebuffer.

Valid Usage ID

VALIDATION [VUID-VkRenderPassBeginInfo-framebuffer-03212 (-662457290)] : Validation Error: [ VUID-VkRenderPassBeginInfo-framebuffer-03212 ] Object 0: handle = 0x57b9520000000037, type = VK_OBJECT_TYPE_RENDER_PASS; | MessageID = 0xd883b436 | vkCmdBeginRenderPass(): Image view #0 created from an image with height set as 512, but image info #0 used to create the framebuffer had height set as 16 The Vulkan spec states: If framebuffer was created with a VkFramebufferCreateInfo::flags value that included VK_FRAMEBUFFER_CREATE_IMAGELESS_BIT, each element of the pAttachments member of a VkRenderPassAttachmentBeginInfo structure included in the pNext chain must be a VkImageView with a height equal to the height member of the corresponding element of VkFramebufferAttachmentsCreateInfo::pAttachments used to create framebuffer (https://vulkan.lunarg.com/doc/view/1.2.162.1/windows/1.2-extensions/vkspec.html#VUID-VkRenderPassBeginInfo-framebuffer-03212)
object info: (type: RENDER_PASS, hndl: 6321173711944679479)

Environment:

  • OS: Linux
  • GPU: AMD Ryzen 3500U
  • SDK or header version if building from repo: 1.2.162.0
  • Options enabled (synchronization, best practices, etc.): standard validation

Additional context
The validation message itself is incorrect. It says:

Image view #0 created from an image with height set as 512, but ...

The problem here is that the spec doesn't say anything about the image dimensions. The spec only cares about the image view dimensions. I.e. in VkFramebufferAttachmentImageInfo it says:

width is the width of the image view used for rendering.
height is the height of the image view used for rendering.

@TonyBarbour
Copy link
Contributor

I believe this is a duplicate of #2318

@TonyBarbour
Copy link
Contributor

Fixed in #2508

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants