Browse Source
Merge pull request #12688 from liamwhite/wl-present-fix
renderer_vulkan: recreate swapchain when frame size changes
pull/15/merge
liamwhite
2 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with
1 additions and
1 deletions
-
src/video_core/renderer_vulkan/vk_present_manager.cpp
|
|
|
@ -329,7 +329,7 @@ void PresentManager::CopyToSwapchainImpl(Frame* frame) { |
|
|
|
// to account for that.
|
|
|
|
const bool is_suboptimal = swapchain.NeedsRecreation(); |
|
|
|
const bool size_changed = |
|
|
|
swapchain.GetWidth() < frame->width || swapchain.GetHeight() < frame->height; |
|
|
|
swapchain.GetWidth() != frame->width || swapchain.GetHeight() != frame->height; |
|
|
|
if (is_suboptimal || size_changed) { |
|
|
|
RecreateSwapchain(frame); |
|
|
|
} |
|
|
|
|