filament
filament copied to clipboard
Vulkan present queue
Valid usage of vkGetDeviceQueue in vulkan spec declare "queueFamilyIndex must be one of the queue family indices specified when device was created, via the VkDeviceQueueCreateInfo structure" . Only graphic queue family index was specified when device was created. If present queue family index is not equal to graphic queue family index, would it be right?
I think you're right, to fix this I think we should add the second queue type into our deviceCreateInfo
struct. Out of curiosity, is this causing a problem with a certain GPU?
This might be non-trivial to fix because the driver API allows clients to do certain things (e.g. upload a vertex buffer) before the swap chain is created. We need the swap chain in order to have a VkSurface, and we need a VkSurface in order to obtain a present queue family index.
Thankfully, this isn't causing issues on any devices that I know about.
@pixelflinger potential starter issue for someone in the Vulkan codebase
For record: we make the assumption that graphics queues can also present so the two QF index should be the same. If this assumption ever fails, we can revisit.