Skip to content
Snippets Groups Projects
Verified Commit 06303aaa authored by Tobias Frisch's avatar Tobias Frisch
Browse files

[#90] Fixed destructor of descriptor manager

parent 3990aef7
No related branches found
No related tags found
1 merge request!93Resolve "DescriptorSetLayouts unabhängig von DescriptorSets machen!"
Pipeline #26965 passed
...@@ -32,8 +32,13 @@ namespace vkcv ...@@ -32,8 +32,13 @@ namespace vkcv
for (uint64_t id = 0; id < m_DescriptorSets.size(); id++) { for (uint64_t id = 0; id < m_DescriptorSets.size(); id++) {
destroyDescriptorSetById(id); destroyDescriptorSetById(id);
} }
for (uint64_t id = 0; id < m_DescriptorSetLayouts.size(); id++) {
destroyDescriptorSetLayoutById(id);
}
m_DescriptorSets.clear(); m_DescriptorSets.clear();
m_DescriptorSetLayouts.clear();
for (const auto &pool : m_Pools) { for (const auto &pool : m_Pools) {
if (pool) { if (pool) {
...@@ -285,6 +290,7 @@ namespace vkcv ...@@ -285,6 +290,7 @@ namespace vkcv
auto& set = m_DescriptorSets[id]; auto& set = m_DescriptorSets[id];
if (set.vulkanHandle) { if (set.vulkanHandle) {
m_Device.freeDescriptorSets(m_Pools[set.poolIndex], 1, &(set.vulkanHandle)); m_Device.freeDescriptorSets(m_Pools[set.poolIndex], 1, &(set.vulkanHandle));
set.setLayoutHandle = DescriptorSetLayoutHandle();
set.vulkanHandle = nullptr; set.vulkanHandle = nullptr;
} }
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment