From eec8b57ce89236456ce9d79c760e6abc5d0c27a3 Mon Sep 17 00:00:00 2001 From: Alexander Bondarenko <486682+dpwiz@users.noreply.github.com> Date: Mon, 4 Sep 2023 13:10:10 +0300 Subject: [PATCH] Use FIFO for vulkan demo (#188) --- examples/vulkan/Backend.hs | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/examples/vulkan/Backend.hs b/examples/vulkan/Backend.hs index d9dbbed..3562426 100644 --- a/examples/vulkan/Backend.hs +++ b/examples/vulkan/Backend.hs @@ -408,11 +408,9 @@ createSwapchain physicalDevice device surface surfaceFormat imageUsage imageCoun let presentMode :: Vulkan.PresentModeKHR - presentMode - | Vulkan.PRESENT_MODE_MAILBOX_KHR `elem` presentModes - = Vulkan.PRESENT_MODE_MAILBOX_KHR - | otherwise - = Vulkan.PRESENT_MODE_FIFO_KHR + presentMode = + Vulkan.PRESENT_MODE_FIFO_KHR -- run at presentation rate + -- Vulkan.PRESENT_MODE_MAILBOX_KHR -- max-FPS alternative for benchmarks, input lag debugging, etc. Vulkan.SurfaceCapabilitiesKHR{currentExtent, currentTransform} = surfaceCapabilities Vulkan.SurfaceFormatKHR{format=fmt, colorSpace=csp} = surfaceFormat