When integer scaling, take the internal render resolution into account.

This commit is contained in:
Henrik Rydgård committed 2023-04-05 09:48:28 +02:00
1 parent ff907bd523
commit cf28556d6d
1 file changed
+3
+3
View File
@@ -127,6 +127,9 @@ void CalculateDisplayOutputRect(FRect *rc, float origW, float origH, const FRect
if (rotated) {
wDim = 272.0f;
}
// If integer scaling, limit ourselves to even multiples of the rendered resolution,
// to make sure all the pixels are square.
wDim *= g_Config.iInternalResolution;
outW = std::max(1.0f, floorf(outW / wDim)) * wDim;
outH = outW / origRatio;
}