From: Mikko Rasa Date: Wed, 16 Mar 2022 11:20:59 +0000 (+0200) Subject: Mask out the descriptor set part of bind point when creating layouts X-Git-Url: http://git.tdb.fi/?a=commitdiff_plain;h=542c01f2798ad38279b043011a5bf1d1b975eb07;p=libs%2Fgl.git Mask out the descriptor set part of bind point when creating layouts --- diff --git a/source/backends/vulkan/program_backend.cpp b/source/backends/vulkan/program_backend.cpp index 0c30b99e..2e951810 100644 --- a/source/backends/vulkan/program_backend.cpp +++ b/source/backends/vulkan/program_backend.cpp @@ -125,7 +125,7 @@ void VulkanProgram::finalize_uniforms() { bindings.emplace_back(); VkDescriptorSetLayoutBinding &binding = bindings.back(); - binding.binding = b.bind_point; + binding.binding = b.bind_point&0xFFFFF; binding.descriptorType = VK_DESCRIPTOR_TYPE_UNIFORM_BUFFER; binding.descriptorCount = 1; binding.stageFlags = VK_SHADER_STAGE_ALL; @@ -137,7 +137,7 @@ void VulkanProgram::finalize_uniforms() { bindings.emplace_back(); VkDescriptorSetLayoutBinding &binding = bindings.back(); - binding.binding = u.binding; + binding.binding = u.binding&0xFFFFF; binding.descriptorType = VK_DESCRIPTOR_TYPE_COMBINED_IMAGE_SAMPLER; binding.descriptorCount = 1; binding.stageFlags = VK_SHADER_STAGE_ALL;