fix swapchain framebuffer leak on exit
parent
74c5ac984c
commit
2b092ca387
|
@ -4556,6 +4556,15 @@ static void VULKAN_DestroyDevice(
|
||||||
|
|
||||||
VULKAN_Wait(device->driverData);
|
VULKAN_Wait(device->driverData);
|
||||||
|
|
||||||
|
for (i = renderer->swapchainDataCount - 1; i >= 0; i -= 1)
|
||||||
|
{
|
||||||
|
VULKAN_INTERNAL_DestroySwapchain(renderer, renderer->swapchainDatas[i]->windowHandle);
|
||||||
|
}
|
||||||
|
|
||||||
|
SDL_free(renderer->swapchainDatas);
|
||||||
|
|
||||||
|
VULKAN_Wait(device->driverData);
|
||||||
|
|
||||||
SDL_free(renderer->submittedCommandBuffers);
|
SDL_free(renderer->submittedCommandBuffers);
|
||||||
|
|
||||||
VULKAN_INTERNAL_DestroyBuffer(renderer, renderer->dummyVertexUniformBuffer->vulkanBuffer);
|
VULKAN_INTERNAL_DestroyBuffer(renderer, renderer->dummyVertexUniformBuffer->vulkanBuffer);
|
||||||
|
@ -4715,13 +4724,6 @@ static void VULKAN_DestroyDevice(
|
||||||
VULKAN_INTERNAL_DestroyUniformBufferPool(renderer, renderer->fragmentUniformBufferPool);
|
VULKAN_INTERNAL_DestroyUniformBufferPool(renderer, renderer->fragmentUniformBufferPool);
|
||||||
VULKAN_INTERNAL_DestroyUniformBufferPool(renderer, renderer->computeUniformBufferPool);
|
VULKAN_INTERNAL_DestroyUniformBufferPool(renderer, renderer->computeUniformBufferPool);
|
||||||
|
|
||||||
for (i = renderer->swapchainDataCount - 1; i >= 0; i -= 1)
|
|
||||||
{
|
|
||||||
VULKAN_INTERNAL_DestroySwapchain(renderer, renderer->swapchainDatas[i]->windowHandle);
|
|
||||||
}
|
|
||||||
|
|
||||||
SDL_free(renderer->swapchainDatas);
|
|
||||||
|
|
||||||
for (i = 0; i < renderer->framebufferHashArray.count; i += 1)
|
for (i = 0; i < renderer->framebufferHashArray.count; i += 1)
|
||||||
{
|
{
|
||||||
VULKAN_INTERNAL_DestroyFramebuffer(
|
VULKAN_INTERNAL_DestroyFramebuffer(
|
||||||
|
|
Loading…
Reference in New Issue