Resource cleanup

This commit is contained in:
Sascha Willems 2020-06-06 11:21:55 +02:00
parent 9e96aeaa5f
commit ffc3068c9d

View file

@ -51,6 +51,10 @@ VulkanglTFModel::~VulkanglTFModel()
vkDestroySampler(vulkanDevice->logicalDevice, image.texture.sampler, nullptr);
vkFreeMemory(vulkanDevice->logicalDevice, image.texture.deviceMemory, nullptr);
}
for (Skin skin : skins)
{
skin.ssbo.destroy();
}
}
/*
@ -668,6 +672,7 @@ VulkanExample::~VulkanExample()
vkDestroyPipelineLayout(device, pipelineLayout, nullptr);
vkDestroyDescriptorSetLayout(device, descriptorSetLayouts.matrices, nullptr);
vkDestroyDescriptorSetLayout(device, descriptorSetLayouts.textures, nullptr);
vkDestroyDescriptorSetLayout(device, descriptorSetLayouts.jointMatrices, nullptr);
shaderData.buffer.destroy();
}