Widescreen: Difference between revisions
Vitor Vilela (talk | contribs) m (Vitor Vilela moved page WidescreenRomHacking to Widescreen) |
Vitor Vilela (talk | contribs) No edit summary |
||
Line 1: | Line 1: | ||
== Screen == | |||
We have two screen settings available: | |||
1) 16:9 widescreen. There's an additional 48 columns to the left and right side of the screen. Resolution is 352x224, stretched to simulate the 8:7 pixel aspect ratio. | |||
2) 21:9 widescreen (actually 64:27). There's an additional 96 columns to the left and right side of the screen. Resolution is 448x224, stretched to simulate the 8:7 pixel aspect ratio. | |||
== Objects == | |||
== | Since OAM sprite width is 9-bit wide, allowing values between -256 to +255, the internal range is adjusted in a manner the negative range also wraps positively. You can assume the values to range between -128 and +384, which are mapped that way: if unsigned position is greater than or equal to 384, subtract 512 from it. Else, keep value as is. | ||
https://www.reddit.com/r/emulation/comments/bmc9t9/bsneshd_beta_5_bsnes_1073_formally_hd_mode_7_mod/ | |||
Sprites that already knows how to handle the left screen boundary (position -1 to -16) can be easily adapted to work with the widescreen range. Otherwise, it's recommended to port the relative screen position to use 16-bit values. | |||
In addition, it doesn't break other emulators, since the additional visible area is implicitly invisible on the SNES hardware specification. | |||
== Windowing == | |||
Assume that the windowing internal size is 512 lines long instead of 256 lines long. If you take the windowing calculations based from this perspective, windowing HDMA will work regardless of the aspect ratio being currently used (16:9, 21:9, etc.) | |||
== Emulator == | |||
https://github.com/DerKoun/bsnes-hd | |||
https://www.reddit.com/r/emulation/comments/bmc9t9/bsneshd_beta_5_bsnes_1073_formally_hd_mode_7_mod/ |
Revision as of 05:20, 10 April 2021
Screen
We have two screen settings available:
1) 16:9 widescreen. There's an additional 48 columns to the left and right side of the screen. Resolution is 352x224, stretched to simulate the 8:7 pixel aspect ratio. 2) 21:9 widescreen (actually 64:27). There's an additional 96 columns to the left and right side of the screen. Resolution is 448x224, stretched to simulate the 8:7 pixel aspect ratio.
Objects
Since OAM sprite width is 9-bit wide, allowing values between -256 to +255, the internal range is adjusted in a manner the negative range also wraps positively. You can assume the values to range between -128 and +384, which are mapped that way: if unsigned position is greater than or equal to 384, subtract 512 from it. Else, keep value as is.
Sprites that already knows how to handle the left screen boundary (position -1 to -16) can be easily adapted to work with the widescreen range. Otherwise, it's recommended to port the relative screen position to use 16-bit values.
In addition, it doesn't break other emulators, since the additional visible area is implicitly invisible on the SNES hardware specification.
Windowing
Assume that the windowing internal size is 512 lines long instead of 256 lines long. If you take the windowing calculations based from this perspective, windowing HDMA will work regardless of the aspect ratio being currently used (16:9, 21:9, etc.)
Emulator
https://github.com/DerKoun/bsnes-hd https://www.reddit.com/r/emulation/comments/bmc9t9/bsneshd_beta_5_bsnes_1073_formally_hd_mode_7_mod/