From 241583774c06aeef14b3d63fa9fc9edcdf656b20 Mon Sep 17 00:00:00 2001 From: Sascha Willems Date: Sun, 17 Oct 2021 10:50:43 +0200 Subject: [PATCH] Destroy fence --- examples/texturesparseresidency/texturesparseresidency.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/examples/texturesparseresidency/texturesparseresidency.cpp b/examples/texturesparseresidency/texturesparseresidency.cpp index 4832a54a..a67c834d 100644 --- a/examples/texturesparseresidency/texturesparseresidency.cpp +++ b/examples/texturesparseresidency/texturesparseresidency.cpp @@ -913,6 +913,7 @@ void VulkanExample::flushRandomPages() VK_CHECK_RESULT(vkCreateFence(device, &fenceInfo, nullptr, &fence)); vkQueueBindSparse(queue, 1, &texture.bindSparseInfo, fence); vkWaitForFences(device, 1, &fence, VK_TRUE, UINT64_MAX); + vkDestroyFence(device, fence, nullptr); for (auto& page : texture.pages) { if (page.del)