Use unique indices for each binding in out_of_pool_memory test
authorChris Forbes <chrisforbes@google.com>
Tue, 9 Jan 2018 23:26:34 +0000 (15:26 -0800)
committerAlexander Galazin <Alexander.Galazin@arm.com>
Fri, 12 Jan 2018 12:57:56 +0000 (07:57 -0500)
Previously, all the layout bindings would use binding=0, which is
invalid. Give them their own binding indices.

VK-GL-CTS: 929

Change-Id: I28e62db6c257ed0843dd9b77b2d8cb01d02e3eba
Components: Vulkan
Affects: dEQP-VK.api.descriptor_pool.out_of_pool_memory

external/vulkancts/modules/vulkan/api/vktApiDescriptorPoolTests.cpp

index 64d863f..5e5b596 100644 (file)
@@ -212,7 +212,13 @@ tcu::TestStatus outOfPoolMemoryTest (Context& context)
                                DE_NULL,                                                                                                        // const VkSampler*      pImmutableSamplers;
                        };
 
                                DE_NULL,                                                                                                        // const VkSampler*      pImmutableSamplers;
                        };
 
-                       const vector<VkDescriptorSetLayoutBinding>      descriptorSetLayoutBindings (params.bindingCount, descriptorSetLayoutBinding);
+                       vector<VkDescriptorSetLayoutBinding>    descriptorSetLayoutBindings (params.bindingCount, descriptorSetLayoutBinding);
+
+                       for (deUint32 binding = 0; binding < deUint32(descriptorSetLayoutBindings.size()); ++binding)
+                       {
+                               descriptorSetLayoutBindings[binding].binding = binding;
+                       }
+
                        const VkDescriptorSetLayoutCreateInfo           descriptorSetLayoutInfo =
                        {
                                VK_STRUCTURE_TYPE_DESCRIPTOR_SET_LAYOUT_CREATE_INFO,            // VkStructureType                        sType;
                        const VkDescriptorSetLayoutCreateInfo           descriptorSetLayoutInfo =
                        {
                                VK_STRUCTURE_TYPE_DESCRIPTOR_SET_LAYOUT_CREATE_INFO,            // VkStructureType                        sType;