From ef8fe6639e3712e8719a8d5eb83c451f9563b0f6 Mon Sep 17 00:00:00 2001 From: ramapcsx2 Date: Fri, 19 Feb 2010 19:05:35 +0000 Subject: [PATCH] GSdx: - Found out that the blur detection filter was busted for some time now. It worked by chance, due to the pixel crop hack. Disabled that hack now and made PCSX2's GS frame handle that functionality instead. This is a somewhat nicer method, although users of 4:3 and 16:9 aspect ratios might get flickering pixels on the borders again. I'll see if I can think of something for those cases, should there be demand for it. git-svn-id: http://pcsx2.googlecode.com/svn/trunk@2608 96395faa-99c1-11dd-bbfe-3dabce05a288 --- pcsx2/gui/FrameForGS.cpp | 7 ++++++- plugins/GSdx/GSRenderer.cpp | 8 ++++---- plugins/GSdx/GSVector.cpp | 7 ------- 3 files changed, 10 insertions(+), 12 deletions(-) diff --git a/pcsx2/gui/FrameForGS.cpp b/pcsx2/gui/FrameForGS.cpp index 5bd4dba945..b6814a6c34 100644 --- a/pcsx2/gui/FrameForGS.cpp +++ b/pcsx2/gui/FrameForGS.cpp @@ -116,7 +116,12 @@ void GSPanel::DoResize() switch( g_Conf->GSWindow.AspectRatio ) { case AspectRatio_Stretch: - // just default to matching client size. + // Default to matching client size. + // Add a few pixels here, so the outermost pixels of the GS plugin output are "hidden". + // This avoids issues with flashing pixels on the edges, especially when Anti Aliasing is used. + // Note: Tests in FFX showed we need at least 5 pixels. So using 6 for good measure :p + viewport.x+=6; + viewport.y+=6; break; case AspectRatio_4_3: diff --git a/plugins/GSdx/GSRenderer.cpp b/plugins/GSdx/GSRenderer.cpp index f4a99a8849..6b307f2864 100644 --- a/plugins/GSdx/GSRenderer.cpp +++ b/plugins/GSdx/GSRenderer.cpp @@ -215,12 +215,12 @@ bool GSRenderer::Merge(int field) r.bottom = r.top + y; } - // - - if(blurdetected && i == 1) + // Breaks the blur filter, and actually makes games blurry again. + // This might have to do with earlier changes to device size detection. + /*if(blurdetected && i == 1) { r += GSVector4i(0, 1).xyxy(); - } + }*/ GSVector4 scale = GSVector4(tex[i]->GetScale()).xyxy(); diff --git a/plugins/GSdx/GSVector.cpp b/plugins/GSdx/GSVector.cpp index 83cd89abd0..d7f6e7ec77 100644 --- a/plugins/GSdx/GSVector.cpp +++ b/plugins/GSdx/GSVector.cpp @@ -96,12 +96,5 @@ GSVector4i GSVector4i::fit(int preset) const r = *this; } -#ifdef USE_UPSCALE_HACKS //don't show outermost pixels, they're often buggy - r.x-=2; - r.y-=2; - r.z+=2; - r.w+=2; -#endif - return r; }