From a1cdf7189adec962de390cf9d134a1cac31e3fbb Mon Sep 17 00:00:00 2001 From: Gregory Hainaut Date: Thu, 18 Aug 2016 08:33:18 +0200 Subject: [PATCH] gsdx tc: don't partially invalidate small target It creates a regression on game that uses a small temporary target to upload textures of various sizes. Inital code was done to handle direct frame write (background, FMV) so big target --- plugins/GSdx/GSTextureCache.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/plugins/GSdx/GSTextureCache.cpp b/plugins/GSdx/GSTextureCache.cpp index f572cde570..0b27bfd994 100644 --- a/plugins/GSdx/GSTextureCache.cpp +++ b/plugins/GSdx/GSTextureCache.cpp @@ -820,7 +820,11 @@ void GSTextureCache::InvalidateVideoMem(GSOffset* off, const GSVector4i& rect, b // FIXME: this code "fixes" black FMV issue with rule of rose. #if 1 // Greg: I'm not sure the 'bw' equality is required but it won't hurt too much - if (t->m_TEX0.TBW == bw && t->Inside(bp, bw, psm, rect) && GSUtil::HasCompatibleBits(psm, t->m_TEX0.PSM)) { + // + // Ben 10 Alien Force : Vilgax Attacks uses a small temporary target for multiple textures (different bw) + // It is too complex to handle, and purpose of the code was to handle FMV (large bw). So let's skip small + // (128 pixels) target + if (bw > 2 && t->m_TEX0.TBW == bw && t->Inside(bp, bw, psm, rect) && GSUtil::HasCompatibleBits(psm, t->m_TEX0.PSM)) { uint32 rowsize = bw * 8192u; uint32 offset = (uint32)((bp - t->m_TEX0.TBP0) * 256);