MiSTer-devel / SMS_MiSTer

Sega Master System for MiSTer
45 stars 43 forks source link

PAL SMS border is incorrect over analog video when direct_video=0 #120

Closed birdybro closed 1 year ago

birdybro commented 2 years ago

https://misterfpga.org/viewtopic.php?p=48093#p48093

I confirmed this result as well. For some odd reason direct video being enabled fixes the otherwise broken border. the border for PAL is also incorrect over HDMI which leads to the screen being filled with an incorrect aspect ratio.

https://user-images.githubusercontent.com/16388068/161673189-6819cc81-7688-4c39-ab62-fefee120b3be.mp4

Here's a video of me switching back and forth between two alternate ini's. Both the same, but one has direct_video=1 and shows the correct border. This is using the analog IO board with vga to YPbPr going to a retrotink 5x pro scaler.

birdybro commented 2 years ago

I traced it down, it's a regression linked to this commit --> https://github.com/MiSTer-devel/SMS_MiSTer/commit/cbef92c6e7c7afb2997d807a584f38db2ae46c8a

birdybro commented 2 years ago

Following up on this so I don't lose track and don't forget, the issue is related to the regression I linked, but also paulb-nl mentioned that this is due to the 5x mode being forced. Kitrinx has the workings of a fix here, others and I were testing it for her, but she has yet to submit a PR, shes' probably wanting to finish it up some more. --> https://github.com/Kitrinx/SMS_MiSTer/commit/41c4d1e332e2d9b1eb99c1df83de0e0da9388e8e

Next, after this is all fixed, then the exact resolutions should be validated for every mode. After that a math-derived aspect ratio for the scaler can be done similar to how the Sega Genesis core has a combinational block for that --> https://github.com/MiSTer-devel/Genesis_MiSTer/blob/ad60161e0d298b794b52a5ad84be355a2cbed88c/Genesis.sv#L194-L219

birdybro commented 1 year ago

This is resolved and will be available in the next release, closing.