Closed justinblaber closed 1 month ago
You're right, you need to have an array of vk::DescriptorSetLayout
s to pass into a vk::PipelineLayoutCreateInfo
.
vk::-handles are binary identical to the actual (C-)handles, and thus you can easily pass an array of them into the structure eventually passed into the actual vulkan C-function.
vk::raii::-handles carry additional informations and thus are incompatible with the C-handles. Therefore, that copying is needed.
Introducing some vk::raii::PipelineLayoutCreateInfo would introduce some potential complexities I'd like to avoid.
Assuming, the question has been answered... Please re-open if not.
I've noticed this in a few places, but this is a specific example where it's slightly problematic. If have a
std::vector
ofvk::raii::DescriptorSetLayout
and try to pass it tovk::PipelineLayoutCreateInfo
, it results in an error. To make this work you need to create an array of the non-raii versionvk::DescriptorSetLayout
like:So you need to create a temporary vector which is kind of annoying. The
MultipleSets.cpp
example seems to confirm this.Wondering if having
vk::raii::PipelineLayoutCreateInfo
would be useful to take arrays of raii parameters so there's no need to mixvk::raii
andvk::
.