From 95ff8e3a98e2895a96ecb55e8eb6d654c481a7a8 Mon Sep 17 00:00:00 2001 From: "Jake.Stine" Date: Sat, 6 Jun 2009 11:00:30 +0000 Subject: [PATCH] GSdx: Applied normalization of UV in the DX9 texture repeat shader, allowing it to be re-enabled. Fixes massive slowdown in the Xenosaga 2 opening menu (Issue 262 / DX9 only) [note: collective fix uncovered by sudonim, feal87, and drk||raziel -- I'm just the patching boy] git-svn-id: http://pcsx2.googlecode.com/svn/trunk@1340 96395faa-99c1-11dd-bbfe-3dabce05a288 --- plugins/GSdx/GSRendererHW9.cpp | 2 +- plugins/GSdx/res/tfx9.fx | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/plugins/GSdx/GSRendererHW9.cpp b/plugins/GSdx/GSRendererHW9.cpp index 851a02b50d..27be32f1d2 100644 --- a/plugins/GSdx/GSRendererHW9.cpp +++ b/plugins/GSdx/GSRendererHW9.cpp @@ -25,7 +25,7 @@ #include "resource.h" GSRendererHW9::GSRendererHW9(uint8* base, bool mt, void (*irq)()) - : GSRendererHW(base, mt, irq, new GSDevice9(), new GSTextureCache9(this), false) + : GSRendererHW(base, mt, irq, new GSDevice9(), new GSTextureCache9(this), true) { m_fba.enabled = !!theApp.GetConfig("fba", 1); m_logz = !!theApp.GetConfig("logz", 0); diff --git a/plugins/GSdx/res/tfx9.fx b/plugins/GSdx/res/tfx9.fx index 384b85780d..b17a07f822 100644 --- a/plugins/GSdx/res/tfx9.fx +++ b/plugins/GSdx/res/tfx9.fx @@ -116,12 +116,12 @@ sampler1D VMSKFIX : register(s3); float repeatu(float tc) { - return WMS == 3 ? tex1D(UMSKFIX, tc) : tc; + return WMS == 3 ? tex1D(UMSKFIX, tc*rWrH.x)* WH.x : tc; } float repeatv(float tc) { - return WMT == 3 ? tex1D(VMSKFIX, tc) : tc; + return WMT == 3 ? tex1D(VMSKFIX, tc*rWrH.y)* WH.y : tc; } float4 sample(float2 tc)