From 9cc852a0977da4cf10b4506777b17982191b8e05 Mon Sep 17 00:00:00 2001 From: Connor McLaughlin Date: Tue, 1 Nov 2022 19:16:05 +1000 Subject: [PATCH] GS/Vulkan: Copy entire target when ds == tex Also for DX12. Shadow Hearts 3 does a downsample, and we don't copy enough if we limit to the render area. Really, the texture cache should be handling this. But since we have the target height more correct now, the perf hit shouldn't be much. --- pcsx2/GS/Renderers/DX12/GSDevice12.cpp | 4 ++-- pcsx2/GS/Renderers/Vulkan/GSDeviceVK.cpp | 3 ++- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/pcsx2/GS/Renderers/DX12/GSDevice12.cpp b/pcsx2/GS/Renderers/DX12/GSDevice12.cpp index 59b2a90319..22193e42d8 100644 --- a/pcsx2/GS/Renderers/DX12/GSDevice12.cpp +++ b/pcsx2/GS/Renderers/DX12/GSDevice12.cpp @@ -2565,8 +2565,8 @@ void GSDevice12::RenderHW(GSHWDrawConfig& config) config.drawarea.left, config.drawarea.top, config.drawarea.width(), config.drawarea.height()); - copy_ds->SetState(GSTexture::State::Invalidated); - CopyRect(config.ds, copy_ds, config.drawarea, config.drawarea.left, config.drawarea.top); + pxAssert(copy_ds->GetState() == GSTexture::State::Invalidated); + CopyRect(config.ds, copy_ds, GSVector4i(config.ds->GetSize()).zwxy(), 0, 0); PSSetShaderResource(0, copy_ds, true); } } diff --git a/pcsx2/GS/Renderers/Vulkan/GSDeviceVK.cpp b/pcsx2/GS/Renderers/Vulkan/GSDeviceVK.cpp index 6123f900ca..3363f080e5 100644 --- a/pcsx2/GS/Renderers/Vulkan/GSDeviceVK.cpp +++ b/pcsx2/GS/Renderers/Vulkan/GSDeviceVK.cpp @@ -3009,7 +3009,8 @@ void GSDeviceVK::RenderHW(GSHWDrawConfig& config) config.drawarea.left, config.drawarea.top, config.drawarea.width(), config.drawarea.height()); - CopyRect(config.ds, copy_ds, config.drawarea, config.drawarea.left, config.drawarea.top); + pxAssert(copy_ds->GetState() == GSTexture::State::Invalidated); + CopyRect(config.ds, copy_ds, GSVector4i(config.ds->GetSize()).zwxy(), 0, 0); PSSetShaderResource(0, copy_ds, true); } }