D3D: Fix Virtual XFB viewport.

Looks like I was incorrect about swapping the bottom and top members.
This commit is contained in:
Jules Blok 2014-12-28 17:32:04 +01:00
parent 81d1b7f0c2
commit 730a6e5f4b

View File

@ -744,8 +744,8 @@ void Renderer::SwapImpl(u32 xfbAddr, u32 fbWidth, u32 fbStride, u32 fbHeight, co
int xfbWidth = xfbSource->srcWidth;
int hOffset = ((s32)xfbSource->srcAddr - (s32)xfbAddr) / ((s32)fbStride * 2);
drawRc.top = targetRc.bottom - (hOffset + xfbHeight) * targetRc.GetHeight() / fbHeight;
drawRc.bottom = targetRc.bottom - hOffset * targetRc.GetHeight() / fbHeight;
drawRc.top = targetRc.top + hOffset * targetRc.GetHeight() / fbHeight;
drawRc.bottom = targetRc.top + (hOffset + xfbHeight) * targetRc.GetHeight() / fbHeight;
drawRc.left = targetRc.left + (targetRc.GetWidth() - xfbWidth * targetRc.GetWidth() / fbStride) / 2;
drawRc.right = targetRc.left + (targetRc.GetWidth() + xfbWidth * targetRc.GetWidth() / fbStride) / 2;