mirror of
https://github.com/yuzu-mirror/yuzu.git
synced 2024-09-07 19:19:08 +01:00
Merge pull request #11910 from liamwhite/surface-lost-on-creation
renderer_vulkan: ensure exception on surface loss
This commit is contained in:
commit
1836e62d33
1 changed files with 6 additions and 0 deletions
|
@ -147,6 +147,9 @@ bool Swapchain::AcquireNextImage() {
|
||||||
case VK_ERROR_OUT_OF_DATE_KHR:
|
case VK_ERROR_OUT_OF_DATE_KHR:
|
||||||
is_outdated = true;
|
is_outdated = true;
|
||||||
break;
|
break;
|
||||||
|
case VK_ERROR_SURFACE_LOST_KHR:
|
||||||
|
vk::Check(result);
|
||||||
|
break;
|
||||||
default:
|
default:
|
||||||
LOG_ERROR(Render_Vulkan, "vkAcquireNextImageKHR returned {}", vk::ToString(result));
|
LOG_ERROR(Render_Vulkan, "vkAcquireNextImageKHR returned {}", vk::ToString(result));
|
||||||
break;
|
break;
|
||||||
|
@ -180,6 +183,9 @@ void Swapchain::Present(VkSemaphore render_semaphore) {
|
||||||
case VK_ERROR_OUT_OF_DATE_KHR:
|
case VK_ERROR_OUT_OF_DATE_KHR:
|
||||||
is_outdated = true;
|
is_outdated = true;
|
||||||
break;
|
break;
|
||||||
|
case VK_ERROR_SURFACE_LOST_KHR:
|
||||||
|
vk::Check(result);
|
||||||
|
break;
|
||||||
default:
|
default:
|
||||||
LOG_CRITICAL(Render_Vulkan, "Failed to present with error {}", vk::ToString(result));
|
LOG_CRITICAL(Render_Vulkan, "Failed to present with error {}", vk::ToString(result));
|
||||||
break;
|
break;
|
||||||
|
|
Loading…
Reference in a new issue