You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
GPU and driver version: NVIDIA GeForce RTX 3070 Ti 561.9.0.0
SDK or header version if building from repo: 1.3.296.0
Options enabled (synchronization, best practices, etc.): gpu-assisted, synchronization, and best practices
Describe the Issue
When my application draws an image, the validation layer reports a validation error that I believe is incorrect:
Validation Error: [ UNASSIGNED-CoreValidation-DrawState-InvalidImageLayout ] Object 0: handle = 0x2243b06c390, name = GameWindowBuffer0, type = VK_OBJECT_TYPE_COMMAND_BUFFER; Object 1: handle = 0x2e2cd000000002b, name = Bc1Image0, type = VK_OBJECT_TYPE_IMAGE; | MessageID = 0x4dae5635 | vkCmdDraw(): command buffer VkCommandBuffer 0x2243b06c390[GameWindowBuffer0] expects VkImage 0x2e2cd000000002b[Bc1Image0] (subresource: aspectMask VK_IMAGE_ASPECT_COLOR_BIT array layer 0, mip level 0) to be in layout VK_IMAGE_LAYOUT_SHADER_READ_ONLY_OPTIMAL--instead, current layout is VK_IMAGE_LAYOUT_UNDEFINED.
It states that my image Bc1Image0 has the current layout VK_IMAGE_LAYOUT_UNDEFINED, but I believe that it's layout is VK_IMAGE_LAYOUT_SHADER_READ_ONLY_OPTIMAL because the following commands have been executed and completed prior to the draw command submission:
I have executed vkWaitForFences after the submission to await its completion. This happens before the drawing commands are recorded. I have included the full api dump in the attachment. dump.txt
lines 1440 - 1525: allocate render command buffers
lines 2333 - 2700: create the problematic image, performs the copy & barriers, and awaits the fence
lines 2564 - 2645: the layout transitions of the problematic image
lines 3025 - 3340: samples the problematic image during a draw call
lines 3639 - 3680: another problematic draw call for the same image
line 3935: validation error about the first draw call
line 3939: validation error about the second draw call
(Since the validation error is reported asynchronously by vvl, it doesn't appear immediately.)
thanks for reporting, we have a soon TODO to clean up the UNASSIGNED-CoreValidation-DrawState-InvalidImageLayout error as it has many issues and needs clarification in the Vulkan Spec what is actually legal or not on all Hardware that support Vulkan
Environment:
Describe the Issue
When my application draws an image, the validation layer reports a validation error that I believe is incorrect:
It states that my image
Bc1Image0
has the current layoutVK_IMAGE_LAYOUT_UNDEFINED
, but I believe that it's layout isVK_IMAGE_LAYOUT_SHADER_READ_ONLY_OPTIMAL
because the following commands have been executed and completed prior to the draw command submission:the image layout transition commands
I have executed
vkWaitForFences
after the submission to await its completion. This happens before the drawing commands are recorded. I have included the full api dump in the attachment. dump.txtTo reproduce this error, I published the executable at https://github.com/knokko/mardek/releases/tag/vvl-bug1 . Building from source should also be possible, but requires Java.
Expected behavior
No validation error is reported.
Valid Usage ID
If applicable, please include the validation messages encountered leading up to the issue
The text was updated successfully, but these errors were encountered: