diff --git a/src/video_core/renderer_vulkan/vk_scheduler.cpp b/src/video_core/renderer_vulkan/vk_scheduler.cpp index 323ef0e0a2..00a05362cd 100644 --- a/src/video_core/renderer_vulkan/vk_scheduler.cpp +++ b/src/video_core/renderer_vulkan/vk_scheduler.cpp @@ -6,10 +6,8 @@ #include #include -#include #include #include -#include #include @@ -131,32 +129,8 @@ void Scheduler::RequestRenderpass(const Framebuffer* framebuffer) { } if (use_dynamic_rendering) { - const VkRenderingInfo fb_rendering_info = framebuffer->RenderingInfo(); - - std::vector color_infos; - color_infos.reserve(fb_rendering_info.colorAttachmentCount); - for (u32 i = 0; i < fb_rendering_info.colorAttachmentCount; ++i) { - color_infos.push_back(fb_rendering_info.pColorAttachments[i]); - } - - std::optional depth_info; - std::optional stencil_info; - if (fb_rendering_info.pDepthAttachment) { - depth_info = *fb_rendering_info.pDepthAttachment; - } - if (fb_rendering_info.pStencilAttachment) { - stencil_info = *fb_rendering_info.pStencilAttachment; - } - - Record([rendering_info = fb_rendering_info, color_infos = std::move(color_infos), - depth_info = std::move(depth_info), stencil_info = std::move(stencil_info)]( - vk::CommandBuffer cmdbuf) { - VkRenderingInfo info = rendering_info; - info.pColorAttachments = color_infos.empty() ? nullptr : color_infos.data(); - info.pDepthAttachment = depth_info ? &*depth_info : nullptr; - info.pStencilAttachment = stencil_info ? &*stencil_info : nullptr; - cmdbuf.BeginRendering(&info); - }); + const VkRenderingInfo rendering_info = framebuffer->RenderingInfo(); + Record([rendering_info](vk::CommandBuffer cmdbuf) { cmdbuf.BeginRendering(&rendering_info); }); } else { Record([renderpass, framebuffer_handle, render_area](vk::CommandBuffer cmdbuf) { const VkRenderPassBeginInfo renderpass_bi{