changeset 11:3415afff1d1a

Merge /mnt/Users/sam/git/vulkan
author Sam <sam@basx.dev>
date Sat, 24 Dec 2022 22:38:09 +0700
parents 227e53d1a853 (diff) 0660ba9d1930 (current diff)
children 9e5fe647ff91
files src/engine.nim
diffstat 1 files changed, 1 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/src/engine.nim	Sat Dec 24 22:32:46 2022 +0700
+++ b/src/engine.nim	Sat Dec 24 22:38:09 2022 +0700
@@ -557,7 +557,6 @@
   if nextImageResult == VK_ERROR_OUT_OF_DATE_KHR:
     vulkan.frameDimension = window.getFrameDimension(vulkan.device.physicalDevice.device, vulkan.surface)
     (vulkan.swapchain, vulkan.framebuffers) = vulkan.recreateSwapchain()
-    return
   elif not (nextImageResult in [VK_SUCCESS, VK_SUBOPTIMAL_KHR]):
     raise newException(Exception, "Vulkan error: vkAcquireNextImageKHR returned " & $nextImageResult)
   checkVkResult vulkan.device.device.vkResetFences(1, addr(vulkan.inFlightFences[currentFrame]))
@@ -642,5 +641,5 @@
   when DEBUG_LOG:
     engine.vulkan.instance.vkDestroyDebugUtilsMessengerEXT(engine.vulkan.debugMessenger, nil)
   glslang_finalize_process()
+  engine.window.trash()
   engine.vulkan.instance.vkDestroyInstance(nil)
-  engine.window.trash()