From f10e8d1114e3f2efe8d968b84b2537518e73edd2 Mon Sep 17 00:00:00 2001 From: Brandon Wright Date: Wed, 13 Jun 2018 17:25:08 -0500 Subject: [PATCH] When image is below 1x scale, don't use integer scaling. --- win32/win32_display.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/win32/win32_display.cpp b/win32/win32_display.cpp index 3a1c3056..c716f840 100644 --- a/win32/win32_display.cpp +++ b/win32/win32_display.cpp @@ -304,7 +304,7 @@ RECT CalculateDisplayRect(unsigned int sourceWidth,unsigned int sourceHeight, if(GUI.Stretch) { if(GUI.AspectRatio) { - if (GUI.IntegerScaling && sourceHeight > 0) { + if (GUI.IntegerScaling && sourceHeight > 0 && sourceHeight <= displayHeight && (int)(sourceHeight * snesAspect) <= displayWidth) { int h; for (h = sourceHeight * 2; h <= displayHeight && (int)(h * snesAspect) <= displayWidth; h += sourceHeight) {} h -= sourceHeight;