Change default presentation mode to "FIFO"

Resolves #1.
This commit is contained in:
Stephen Seo 2024-03-14 12:23:44 +09:00
parent 29c8a08720
commit 511a5589db

View file

@ -718,13 +718,15 @@ impl VulkanApp {
fn choose_swap_present_mode(
&self,
available_present_modes: &Vec<ffi::VkPresentModeKHR>,
_available_present_modes: &Vec<ffi::VkPresentModeKHR>,
) -> ffi::VkPresentModeKHR {
for mode in available_present_modes {
if *mode == ffi::VkPresentModeKHR_VK_PRESENT_MODE_MAILBOX_KHR {
return ffi::VkPresentModeKHR_VK_PRESENT_MODE_MAILBOX_KHR;
}
}
// Default to FIFO, don't check for MAILBOX.
//for mode in available_present_modes {
// if *mode == ffi::VkPresentModeKHR_VK_PRESENT_MODE_MAILBOX_KHR {
// return ffi::VkPresentModeKHR_VK_PRESENT_MODE_MAILBOX_KHR;
// }
//}
ffi::VkPresentModeKHR_VK_PRESENT_MODE_FIFO_KHR
}