From cd869d469d831da2de7b2fdae20b0babc47f11d3 Mon Sep 17 00:00:00 2001 From: "Unknown W. Brackets" Date: Thu, 21 May 2020 11:37:36 -0700 Subject: [PATCH] GPU: Ignore viewport for scissor of 481. Assume it's still wrong in this case and take 480x272. See #12746. --- GPU/Common/FramebufferCommon.cpp | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/GPU/Common/FramebufferCommon.cpp b/GPU/Common/FramebufferCommon.cpp index 01fb23796e2f..a4ae58d096e1 100644 --- a/GPU/Common/FramebufferCommon.cpp +++ b/GPU/Common/FramebufferCommon.cpp @@ -151,16 +151,17 @@ void FramebufferManagerCommon::EstimateDrawingSize(u32 fb_address, GEBufferForma drawing_width = scissor_width; drawing_height = std::max(drawing_height, scissor_height); } - if (scissor_width == 481 && region_width == 480 && scissor_height == 273 && region_height == 272) { - drawing_width = 480; - drawing_height = 272; - } } else { // If viewport wasn't valid, let's just take the greatest anything regardless of stride. drawing_width = std::min(std::max(region_width, scissor_width), fb_stride); drawing_height = std::max(region_height, scissor_height); } + if (scissor_width == 481 && region_width == 480 && scissor_height == 273 && region_height == 272) { + drawing_width = 480; + drawing_height = 272; + } + // Assume no buffer is > 512 tall, it couldn't be textured or displayed fully if so. if (drawing_height >= MAX_FRAMEBUF_HEIGHT) { if (region_height < MAX_FRAMEBUF_HEIGHT) {