-
Notifications
You must be signed in to change notification settings - Fork 414
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 Layers modify incorrect configurations resulting in a successful render #8947
Comments
Can I confirm a few things
VkRenderingInfo render_info;
render_info.colorAttachmentCount = 0;
render_info.pColorAttachments = pointer_to_formats;
otherwise you should got en error like
|
This was a mistake on my end due to my variable naming scheme, when I said RenderingInfo I meant VkPipelineRenderingCreateInfo. I am using Dynamic Rendering and specify my color attachments there. VkPipelineRenderingCreateInfo::colorAttachmentCount is zero however the number of attachments to the VkRenderingInfo is NOT zero and has the count correctly set. VkPipelineRenderingCreateInfo::colorAttachmentCount = 0 Enabling certain validation layers and/or settings result in a successful render. |
I tried writing a test and I always get a Validation error. Can you provide an API dump or some way for me to reproduce this where it does not throw a validation error |
Environment:
Describe the Issue
Consider a Vulkan application using dynamic rendering on Vulkan 1.3.29X
The programmer sets the vkRenderInfo struct as the p_next to their pipeline creation info. Within the vkRenderInfo, colorAttachmentCount is set to zero HOWEVER the actual pointer to the color attachments formats is set to point to the format of the color attachment used in dynamic rendering. This happens the programmer forgot to set the color attachment format count.
When validation layers are completely disabled, this results in the expected behavior (i.e. undefined behavior).
HOWEVER, when validation layers are enabled, the pipeline correctly outputs to color attachments despite to no color attachment formats technically being specified,
Expected behavior
Undefined behavior, specifically on my driver, the fragment shader output is NOT written to the color attachment
A validation error SHOULD be raised in this configuration however none is but that is not the scope of this issue.
The text was updated successfully, but these errors were encountered: