Reply 240 of 733, by Ant_222
wrote:wrote:You are correct. The exact PAR of 1.2 would be achieved by a 10x12 scale, but your display is not big enough for that, whereas a scale of 5x6 is considered too small by the algorithm, so it chose a compromise. The resulting aspect ratio is slightly off. Did you perceive this visually or by measuring? Should you prefer a 1600x1200 image with the exact aspect ratio?
I actually perceived this visually, which kinda did "something isn't correct here" itch. Like in the nearest-neighbor algorithm, the aspect ratio is correct, so the thing that you notice more is that the text-fonts are not the right shape.
So you perceived an error of
1 - (8/10) / (10/12) = 4%
I might need to add a setting specifying the relative importance of preserving the aspect ratio over using more of the screen area. This value is currently hard-coded in the patch (ASPECT_IMPORTANCE in pixelscale.cpp). If you increase it sufficiently, you will get a perfect 1600x1200 image, although too small.
So I suppose it would matter more if the source video is text or graphics. Text-mode things have a definitely wrong look to it, but are the least impacted, since we're talking about showing all the pixels, and is far crisper than a CRT could ever be. Remember that CRT's often analog controls and were never perfect, so I think the text-mode could get away with this.
I agree, for I have no discomfort in reading text magnified in a pixel-perfect manner either with or without aspect-ratio correction.
In graphics mode, it comes back to "is a circle a circle" which the test is typically Wing Commander. [...] Of the screenshots, […]
In graphics mode, it comes back to "is a circle a circle" which the test is typically Wing Commander.
[...]
Of the screenshots, ScalePP seems warped just a little. But I think if the game was being played it wouldn't be noticed as much.Scalepp, 104x110
Scalenp, 104x105
SDL2, texturenb 104x106
ykhwong d3d, 103x106
13x11 --[8x10]--> 104x110
which gives a 4% error as shown above. I can't comment on the other two cropped screenshots without knowing their full dimensions. On my system with surfacenp I have:
320 x 200 (1.2) --[4.2 x 5.0]--> 1344 x 1008 (1.2)
where 1344/1008 = 1.333
which is very close to the target 4/3 aspect ratio. Aspect-ratio error is best analysed using full screenshots.
Interestingly, it looks scalenp might be closer to an even shape.
Is scalenp a typo? surfacenb, surfacenp, and the hardware scaling modes of stock DOSBox should preserve the source PAR within tenths of a percent, which is an imperceptible difference.