Skip to content
Snippets Groups Projects
Commit 774bb42c authored by Rajnesh Kanwal's avatar Rajnesh Kanwal
Browse files

Fixes memory leak due to ImGui context not being destroyed.

parent cd688239
No related branches found
No related tags found
No related merge requests found
......@@ -50,7 +50,9 @@ namespace vks
io.FontGlobalScale = scale;
}
UIOverlay::~UIOverlay() { }
UIOverlay::~UIOverlay() {
ImGui::DestroyContext();
}
/** Prepare all vulkan resources required to render the UI overlay */
void UIOverlay::prepareResources()
......@@ -397,7 +399,6 @@ namespace vks
void UIOverlay::freeResources()
{
ImGui::DestroyContext();
vertexBuffer.destroy();
indexBuffer.destroy();
vkDestroyImageView(device->logicalDevice, fontView, nullptr);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment