I have followed Vulkan Tutorial up until page 144, right before the "Handling minimization" section.
My program works, except for the fact that when I try to resize the window too much too quickly, my program hangs, and I get this validation error message:
[ERROR] --- [2025-01-29 15:40:22] [5208] VULKAN - VALIDATION: Validation Error: [ VUID-vkAcquireNextImageKHR-semaphore-01286 ] Object 0: handle = 0x9fde6b0000000014, type = VK_OBJECT_TYPE_SEMAPHORE; | MessageID = 0xe9e4b2a9 | vkAcquireNextImageKHR(): Semaphore must not be currently signaled.
The Vulkan spec states: If semaphore is not VK_NULL_HANDLE, it must be unsignaled (https://vulkan.lunarg.com/doc/view/1.3.296.0/linux/1.3-extensions/vkspec.html#VUID-vkAcquireNextImageKHR-semaphore-01286)
I have attached my draw code in a file to this post.
The things I'm doing differently:
- using the .Graphics queue to present, instead of using a .Present queue
- not recreating the swapchain if there's a presentation error. (
res := vk.QueuePresentKHR(gc.queues[.Graphics], &present_info)). But even if I do, the same error still happens.
Does anybody know why I get this error?