From 442dff8cf4c99d67e7258e376d38ec32b92a2fbf Mon Sep 17 00:00:00 2001 From: Jason Ekstrand Date: Mon, 22 Feb 2016 17:13:46 -0800 Subject: [PATCH] anv/descriptor_set: Stop marking everything as having dynamic offsets --- src/intel/vulkan/anv_descriptor_set.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/intel/vulkan/anv_descriptor_set.c b/src/intel/vulkan/anv_descriptor_set.c index 718bc216f73..b439f2a0c36 100644 --- a/src/intel/vulkan/anv_descriptor_set.c +++ b/src/intel/vulkan/anv_descriptor_set.c @@ -218,8 +218,10 @@ VkResult anv_CreatePipelineLayout( layout->set[set].dynamic_offset_start = dynamic_offset_count; for (uint32_t b = 0; b < set_layout->binding_count; b++) { - if (set_layout->binding[b].dynamic_offset_index >= 0) - dynamic_offset_count += set_layout->binding[b].array_size; + if (set_layout->binding[b].dynamic_offset_index < 0) + continue; + + dynamic_offset_count += set_layout->binding[b].array_size; for (gl_shader_stage s = 0; s < MESA_SHADER_STAGES; s++) { if (set_layout->binding[b].stage[s].surface_index >= 0) layout->stage[s].has_dynamic_offsets = true; -- 2.30.2