summaryrefslogtreecommitdiff
path: root/Source/Core/VideoBackends/Vulkan/Renderer.cpp
diff options
context:
space:
mode:
authoriwubcode <iwubcode@users.noreply.github.com>2017-09-29 00:31:08 -0500
committeriwubcode <iwubcode@users.noreply.github.com>2017-11-17 22:11:32 -0600
commit4964fc87ae15600252cea8a07df5799e91c11875 (patch)
treedfd067d59541079078dae594dcd2476db854a168 /Source/Core/VideoBackends/Vulkan/Renderer.cpp
parenta129a53e56cdff93e2fd092fd56f3e0726408a60 (diff)
Video Backends: Remove the right of the xfb region for games where the
VI stride does not match the VI width
Diffstat (limited to 'Source/Core/VideoBackends/Vulkan/Renderer.cpp')
-rw-r--r--Source/Core/VideoBackends/Vulkan/Renderer.cpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/Source/Core/VideoBackends/Vulkan/Renderer.cpp b/Source/Core/VideoBackends/Vulkan/Renderer.cpp
index af0bfba451..d5d105ff6b 100644
--- a/Source/Core/VideoBackends/Vulkan/Renderer.cpp
+++ b/Source/Core/VideoBackends/Vulkan/Renderer.cpp
@@ -481,7 +481,7 @@ void Renderer::ReinterpretPixelData(unsigned int convtype)
BindEFBToStateTracker();
}
-void Renderer::SwapImpl(AbstractTexture* texture, const EFBRectangle& rc, u64 ticks, float Gamma)
+void Renderer::SwapImpl(AbstractTexture* texture, const EFBRectangle& xfb_region, u64 ticks, float Gamma)
{
// Pending/batched EFB pokes should be included in the final image.
FramebufferManager::GetInstance()->FlushEFBPokes();
@@ -504,7 +504,7 @@ void Renderer::SwapImpl(AbstractTexture* texture, const EFBRectangle& rc, u64 ti
// Draw to the screen if we have a swap chain.
if (m_swap_chain)
{
- DrawScreen(xfb_texture);
+ DrawScreen(xfb_texture, xfb_region);
// Submit the current command buffer, signaling rendering finished semaphore when it's done
// Because this final command buffer is rendering to the swap chain, we need to wait for
@@ -552,7 +552,7 @@ void Renderer::SwapImpl(AbstractTexture* texture, const EFBRectangle& rc, u64 ti
g_shader_cache->RetrieveAsyncShaders();
}
-void Renderer::DrawScreen(VKTexture* xfb_texture)
+void Renderer::DrawScreen(VKTexture* xfb_texture, const EFBRectangle& xfb_region)
{
VkResult res;
if (!g_command_buffer_mgr->CheckLastPresentFail())
@@ -605,7 +605,8 @@ void Renderer::DrawScreen(VKTexture* xfb_texture)
// Draw
TargetRectangle source_rc = xfb_texture->GetConfig().GetRect();
- BlitScreen(m_swap_chain->GetRenderPass(), GetTargetRectangle(), source_rc, xfb_texture->GetRawTexIdentifier());
+ BlitScreen(m_swap_chain->GetRenderPass(), GetTargetRectangle(), xfb_region,
+ xfb_texture->GetRawTexIdentifier());
// Draw OSD
Util::SetViewportAndScissor(g_command_buffer_mgr->GetCurrentCommandBuffer(), 0, 0,