rhester72 wrote: ↑Tue Nov 23, 2021 8:41 pm
LamerDeluxe wrote: ↑Sun Jul 11, 2021 7:52 am
You can get integer horizontal scaling with correct aspect ratio by just calculating the correct value for the vscale border. That's what I use with the vertical arcade cores to get perfectly clean vertical scanlines.
Can you expand on this a bit if you don't mind?
Sorry, I read your message late in the evening and then forgot to reply another time. I've written a whole explanation just now, but I see Yim has already done that as well. Here's my explanation anyway:
The idea is to use the full screen mode (vscale_mode = 0) and shrink it down, using the vscale_border setting, to make the horizontal width of the image an integer scale, while still keeping the correct aspect ratio (the vertical scale will usually be non-integer). This is the exact opposite of MiSter's standard vertical integer scaling.
The result will look really sharp, with perfect vertical scanlines (no interference patterns).
The following example is for the Scramble core, using a 1920 x 1080 output resolution. Look up the source resolution at the top left of your screen when starting the core (values at the top) or alternatively take a screenshot.
Scramble source resolution: 224 x 256
The display aspect ratio, if you can't find it and assume square pixels, you can calculate it here:
Go to
https://www.bellevuefineart.com/aspect- ... alculator/ to simplify your aspect ratio:
Enter 224 for W1 and 256 for H1, below it it will say "Your aspect ratio is: 7:8"
Scramble's aspect ratio is 7:8 (224:256)
It will usually be either 3:4 or 7:8, so you can always try both. Or just use the source resolution values instead (224:256).
Output display resolution is 1920 x 1080
At 7:8 aspect full screen scaling (vscale_mode=0), the output image width is:
1080 * 7 / 8 = 945
Shrink the horizontal ratio to an integer multiple:
945 / 224 = 4,21875 (this is our current horizontal scale)
Rounded down this is 4 (which is 4x integer horizontal scale)
4 x 224 = 896 (this is our new integer 4x scale output image width)
At 896 width our new image height, at the correct 7:8 aspect ratio, becomes:
896 * 8 / 7 = 1024 (non-integer scaled output image height)
So our total border size needs to be:
1080 - 1024 = 56 (output display height minus output image height)
Divided by two because we have a border above and below the image:
56 / 2 = 28 (this is the vscale_border size we will use)
In mister.ini this becomes (just add it at the end of the file if you don't have core-specific settings yet):
[scramble]
vscale_mode = 0 (if this isn't your default)
vscale_border = 28
(and video_mode=8 if your default resolution differs)