From fd5a6522702c3279c2a968f395983a46374b7fa2 Mon Sep 17 00:00:00 2001 From: TellowKrinkle Date: Wed, 21 Aug 2024 22:22:36 -0500 Subject: [PATCH] Vk: Don't try to transition present source during present --- pcsx2/GS/Renderers/Vulkan/GSDeviceVK.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/pcsx2/GS/Renderers/Vulkan/GSDeviceVK.cpp b/pcsx2/GS/Renderers/Vulkan/GSDeviceVK.cpp index 12f5a8cd0f..4e5617b5e1 100644 --- a/pcsx2/GS/Renderers/Vulkan/GSDeviceVK.cpp +++ b/pcsx2/GS/Renderers/Vulkan/GSDeviceVK.cpp @@ -2344,6 +2344,11 @@ GSDevice::PresentResult GSDeviceVK::BeginPresent(bool frame_skip) swap_chain_texture->OverrideImageLayout(GSTextureVK::Layout::Undefined); swap_chain_texture->TransitionToLayout(cmdbuffer, GSTextureVK::Layout::ColorAttachment); + // Present render pass gets started out here, so we can't transition source textures in DoStretchRect + // Make sure they're ready now + if (!frame_skip && m_current) + static_cast(m_current)->TransitionToLayout(GSTextureVK::Layout::ShaderReadOnly); + const VkFramebuffer fb = swap_chain_texture->GetFramebuffer(false); if (fb == VK_NULL_HANDLE) return GSDevice::PresentResult::FrameSkipped;