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

Vulkano 0.29: PhysicalDevice::surface_formats failing validation layers #1858

Closed
korteland opened this issue Mar 12, 2022 · 2 comments · Fixed by #1859
Closed

Vulkano 0.29: PhysicalDevice::surface_formats failing validation layers #1858

korteland opened this issue Mar 12, 2022 · 2 comments · Fixed by #1859

Comments

@korteland
Copy link

Issue

It's entirely possible my setup code is wrong, but calling PhysicalDevice::surface_formats() with the most minimal possible supporting code causes this validation layer to trip:

VUID-VkSurfaceFormat2KHR-sType-sType(ERROR / SPEC): msgNum: -888940125 - Validation Error: [ VUID-VkSurfaceFormat2KHR-sType-sType ] Object 0: VK_NULL_HANDLE, type = VK_OBJECT_TYPE_DEVICE; | MessageID = 0xcb03d9a3 | vkGetPhysicalDeviceSurfaceFormats2KHR: parameter pSurfaceFormats[0].sType must be VK_STRUCTURE_TYPE_SURFACE_FORMAT_2_KHR The Vulkan spec states: sType must be VK_STRUCTURE_TYPE_SURFACE_FORMAT_2_KHR (https://www.khronos.org/registry/vulkan/specs/1.2-extensions/html/vkspec.html#VUID-VkSurfaceFormat2KHR-sType-sType)

It should be possible to clone the linked repo, type cargo run and observe it, at least on Linux - haven't tested other platforms. It also happens on an Intel iGPU. I verified it's this call causing the problem by adding a panic before that call (no issues) then moving the panic immediately after the call (fails).

I had a quick browse through the code in src/device/physical.rs, nothing jumped out at me as causing this.

Rua added a commit to Rua/vulkano that referenced this issue Mar 12, 2022
@Rua Rua mentioned this issue Mar 12, 2022
@Rua
Copy link
Contributor

Rua commented Mar 12, 2022

I've reproduced the issue and submitted a fix. Thanks for reporting!

@korteland
Copy link
Author

Wow, thanks for the quick turnaround! Much appreciated.

Eliah-Lakhin pushed a commit that referenced this issue Mar 18, 2022
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

Successfully merging a pull request may close this issue.

2 participants