Skip to content

Commit

Permalink
Simplified code
Browse files Browse the repository at this point in the history
  • Loading branch information
robertosfield committed Jul 19, 2023
1 parent 3ba3955 commit 4199833
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions src/vsg/utils/GraphicsPipelineConfigurator.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -157,16 +157,14 @@ bool DescriptorConfigurator::assignDescriptor(uint32_t set, uint32_t binding, Vk
descriptorSets.resize(set + 1);
for (auto i = currentSize; i <= set; i++)
{
if (!descriptorSets[i])
{
descriptorSets[i] = vsg::DescriptorSet::create();
descriptorSets[i]->setLayout = DescriptorSetLayout::create();
}
descriptorSets[i] = vsg::DescriptorSet::create();
descriptorSets[i]->setLayout = DescriptorSetLayout::create();
}
}

auto& ds = descriptorSets[set];
ds->descriptors.push_back(descriptor);

auto& descriptorBindings = ds->setLayout->bindings;
descriptorBindings.push_back(VkDescriptorSetLayoutBinding{binding, descriptorType, descriptorCount, stageFlags, nullptr});

Expand Down

0 comments on commit 4199833

Please sign in to comment.