From 4b85f0949a09e122522b8620d700996821493f27 Mon Sep 17 00:00:00 2001 From: Anthony Miles Date: Sun, 7 Jun 2020 20:56:54 +1200 Subject: [PATCH] Scale viewport X and Y as well as height. Fixes cases where X and Y are nonzero e.g. DoA3 character select --- src/core/hle/D3D8/Direct3D9/Direct3D9.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/core/hle/D3D8/Direct3D9/Direct3D9.cpp b/src/core/hle/D3D8/Direct3D9/Direct3D9.cpp index be83b7384..c52f78e6e 100644 --- a/src/core/hle/D3D8/Direct3D9/Direct3D9.cpp +++ b/src/core/hle/D3D8/Direct3D9/Direct3D9.cpp @@ -4117,6 +4117,8 @@ xbox::void_xt WINAPI xbox::EMUPATCH(D3DDevice_SetViewport) // Apply MSAA scale and offset HostViewPort.Width = static_cast(HostViewPort.Width * g_Xbox_MultiSampleXScale); HostViewPort.Height = static_cast(HostViewPort.Height * g_Xbox_MultiSampleYScale); + HostViewPort.X = static_cast(HostViewPort.X * g_Xbox_MultiSampleXScale); + HostViewPort.Y = static_cast(HostViewPort.Y * g_Xbox_MultiSampleYScale); // Since Width and Height are DWORD, adding GetMultiSampleOffset 0.0f or 0.5f makes no sense HRESULT hRet = g_pD3DDevice->SetViewport(&HostViewPort);