Update to latest ZVulkan

This commit is contained in:
Magnus Norddahl 2023-12-26 04:44:35 +01:00
commit a8cf44bcda
6 changed files with 104 additions and 73 deletions

View file

@ -126,9 +126,9 @@ bool VulkanSwapChain::CreateSwapchain(int width, int height, int imageCount, boo
}
else
{
if (supportsMailbox)
/*if (supportsMailbox)
presentMode = VK_PRESENT_MODE_MAILBOX_KHR;
else if (supportsImmediate)
else*/ if (supportsImmediate)
presentMode = VK_PRESENT_MODE_IMMEDIATE_KHR;
}
}
@ -140,6 +140,8 @@ bool VulkanSwapChain::CreateSwapchain(int width, int height, int imageCount, boo
actualExtent.height = std::max(caps.Capabilites.minImageExtent.height, std::min(caps.Capabilites.maxImageExtent.height, actualExtent.height));
if (actualExtent.width == 0 || actualExtent.height == 0)
{
if (swapchain)
vkDestroySwapchainKHR(device->device, swapchain, nullptr);
swapchain = VK_NULL_HANDLE;
lost = true;
return false;