Пример #1
0
        public unsafe void BindDescriptorSets(
            Pipeline pipeline,
            List <DescriptorSet> descriptorSets,
            VkPipelineBindPoint bindPoint = VkPipelineBindPoint.Graphics
            )
        {
            var sets = new NativeList <VkDescriptorSet>();

            if (descriptorSets != null)
            {
                foreach (var set in descriptorSets)
                {
                    sets.Add(set.Handle);
                }
            }

            if (sets.Count > 0)
            {
                VulkanNative.vkCmdBindDescriptorSets(
                    _handle,
                    bindPoint,
                    pipeline.Layout,
                    0,
                    sets.Count,
                    (VkDescriptorSet *)sets.Data.ToPointer(),
                    0,
                    null
                    );
            }
        }