SourMesen / Mesen-S

Mesen-S is a cross-platform (Windows & Linux) SNES emulator built in C++ and C#
GNU General Public License v3.0
415 stars 100 forks source link

Mesen-S 0.3.0 - Incorrect 4:3 aspect ratio calculation #83

Closed ghost closed 4 years ago

ghost commented 4 years ago

I have a 1600x900 resolution so to get a 4:3 (NTSC) aspect, the viewable area of any game should stretch to 1200x900 in fullscreen to look correct. Mesen-S does this but with the vertical overscan visible. If I remove the top and bottom overscan, the image scales much larger than 1200 pixels wide. It seems the calculations for 4:3 (maybe all aspects in the settings?) are taking into account the overscan which technically wouldn't be visible on a 4:3 crt screen. This is also true with Mesen, the output is too wide. I took screenshots of Turtles in Time USA version in Snes9x with 4:3 turned on, as well as Mesen-S with this setting turned on, with and without overscan. See below.

turtlesSnes9x43 turtlesMesenS43 turtlesMesenS43overscanremoved I gif'd the first 3 images so that it's a bit easier to see the differences. turtles

The Snes9x image is correct, viewable area is 1200 pixels wide by 900 tall with no overscan. The second image is almost correct, the width is 1200 but with the overscan visible the image is squashed. 3rd image has 7 lines on top removed and 8 on the bottom removed, and stretched horizontally too much. Another odd thing is if I remove 8 lines on top instead of 7, part of the image gets removed, but I think the actual height with overscan is 239 lines and not 240 like popular belief, otherwise maybe that's a bug too.

Other emulators I've used with a 4:3 NTSC aspect to compare are blastem, Kega Fusion (old! but still does it correctly), MAME running Neo Geo arcade games, and Xebra. Even though all of those systems have different resolutions, the aspect ratio is consistent. Always a 1200x900 image. I also tried bsnes and byuu's emulator gets it a little wrong too, but in the other direction (image is a little too narrow).

SourMesen commented 4 years ago

This should be fixed as of the latest commit. Some of this is intentional though - NTSC and PAL aspect ratios are pixel aspect ratios, and the aspect ratio shouldn't changed based on the overscan settings. This is the same as before.

For 4:3 and 16:9 ratios, they're now considered display aspect ratios, since their purpose is just to fill a 4:3 or 16:9 monitor in fullscreen.

FYI, if you want an "accurate" ratio though, you should be using "NTSC (8:7)" not "Standard (4:3)".