Fixes memory leak due to ImGui context not being destroyed.
This commit is contained in:
parent
cd6882395d
commit
774bb42ceb
1 changed files with 3 additions and 2 deletions
|
|
@ -50,7 +50,9 @@ namespace vks
|
||||||
io.FontGlobalScale = scale;
|
io.FontGlobalScale = scale;
|
||||||
}
|
}
|
||||||
|
|
||||||
UIOverlay::~UIOverlay() { }
|
UIOverlay::~UIOverlay() {
|
||||||
|
ImGui::DestroyContext();
|
||||||
|
}
|
||||||
|
|
||||||
/** Prepare all vulkan resources required to render the UI overlay */
|
/** Prepare all vulkan resources required to render the UI overlay */
|
||||||
void UIOverlay::prepareResources()
|
void UIOverlay::prepareResources()
|
||||||
|
|
@ -397,7 +399,6 @@ namespace vks
|
||||||
|
|
||||||
void UIOverlay::freeResources()
|
void UIOverlay::freeResources()
|
||||||
{
|
{
|
||||||
ImGui::DestroyContext();
|
|
||||||
vertexBuffer.destroy();
|
vertexBuffer.destroy();
|
||||||
indexBuffer.destroy();
|
indexBuffer.destroy();
|
||||||
vkDestroyImageView(device->logicalDevice, fontView, nullptr);
|
vkDestroyImageView(device->logicalDevice, fontView, nullptr);
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue