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

Validation errors on Subpass example #1037

Closed
pengfei666 opened this issue Apr 29, 2024 · 4 comments
Closed

Validation errors on Subpass example #1037

pengfei666 opened this issue Apr 29, 2024 · 4 comments

Comments

@pengfei666
Copy link

pengfei666 commented Apr 29, 2024

Hi guys.
I see lots of errors when I run the subpass example

[error] -564812795 - VUID-VkDescriptorImageInfo-imageLayout-00344: 
Validation Error: [ VUID-VkDescriptorImageInfo-imageLayout-00344 ] 
Object 0: handle = 0x18a95a61700, type = VK_OBJECT_TYPE_COMMAND_BUFFER; 
Object 1: handle = 0x59f7450000000038, type = VK_OBJECT_TYPE_IMAGE;
 | MessageID = 0xde55a405 | 
vkCmdDraw():  Cannot use VkImage 0x59f7450000000038[] (layer=0 mip=0) with specific layout VK_IMAGE_LAYOUT_SHADER_READ_ONLY_OPTIMAL that doesn't match the previous known layout VK_IMAGE_LAYOUT_COLOR_ATTACHMENT_OPTIMAL. 
The Vulkan spec states: imageLayout must match the actual VkImageLayout of each subresource accessible from imageView at the time this descriptor is accessed as defined by the image layout matching rules (https://vulkan.lunarg.com/doc/view/1.3.280.0/windows/1.3-extensions/vkspec.html#VUID-VkDescriptorImageInfo-imageLayout-00344)

[error] 732146062 - VUID-vkCmdDraw-None-08114: 
Validation Error: [ VUID-vkCmdDraw-None-08114 ] 
Object 0: handle = 0x2bfe4c000000016e, type = VK_OBJECT_TYPE_DESCRIPTOR_SET;
 | MessageID = 0x2ba3a98e | 
vkCmdDraw():  Descriptor set VkDescriptorSet 0x2bfe4c000000016e[] Image layout specified by vkCmdBindDescriptorSets doesn't match actual image layout at time descriptor is used.. See previous error callback for specific details. 
The Vulkan spec states: Descriptors in each bound descriptor set, specified via vkCmdBindDescriptorSets, must be valid as described by descriptor validity if they are statically used by the VkPipeline bound to the pipeline bind point used by this command and the bound VkPipeline was not created with VK_PIPELINE_CREATE_DESCRIPTOR_BUFFER_BIT_EXT (https://vulkan.lunarg.com/doc/view/1.3.280.0/windows/1.3-extensions/vkspec.html#VUID-vkCmdDraw-None-08114)

G-buffer attachments are output in first subpass as VK_IMAGE_LAYOUT_COLOR_ATTACHMENT_OPTIMAL and read in second subpass as VK_IMAGE_LAYOUT_SHADER_READ_ONLY_OPTIMAL. And the image views of the attachments are passed as descriptors with layout VK_IMAGE_LAYOUT_SHADER_READ_ONLY_OPTIMAL in second subpass.

Can you help to identify what happens? do I need to add a image barrier to do the layout transition? @SaschaWillems

@SaschaWillems
Copy link
Collaborator

See #455

And please don't ping me directly on topics like that, the framework was provided by arm so I can't help on this,

@pengfei666
Copy link
Author

I am really sorry for the disturb. who should I reach out to?

@SaschaWillems
Copy link
Collaborator

Creating an issue without pinging people is fine. The samples group takes a look at open issues in regular meetings.

@SaschaWillems
Copy link
Collaborator

Closing this. Fixes will be tracked in #455.

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