Forums

Sega Master System / Mark III / Game Gear
SG-1000 / SC-3000 / SF-7000 / OMV
Home - Forums - Games - Scans - Maps - Cheats - Credits
Music - Videos - Development - Hacks - Translations - Homebrew

View topic - PAL/NTSC Borders and color

Reply to topic
Author Message
  • Joined: 26 Aug 2008
  • Posts: 292
  • Location: Australia
Reply with quote
PAL/NTSC Borders and color
Post Posted: Wed Jul 29, 2009 5:42 am
Last edited by PoorAussie on Tue Oct 27, 2009 2:26 pm; edited 2 times in total
After watching quite a few videos on youtube of real master systems I realized the aspect ratio of the games is different than I was displaying them in my emulator (and most emulators). I was simply taking the 256x192 image and throwing it to 4:3 aspect ratio. On the real videos I noticed the characters were much wider looking compared to my emulator, so there is an obvious defect in how a lot of us handle it.

I noticed MEKA has a simple black border in it's fullscreen mode, but this could be because its simple doubling up the image to 512x384 and centering it on the 640x480 screen. The only other emulator I have seen which seems to handle borders is the WII SMS emulator. It has the correct colors at least, I'm not sure if the height of them is 100% accurate (unlikely).

In RetroCopy I decided to add border emulation after seeing a few real games utilizing the region for effects. I haven't shown the entire region that is described in Charles documents because it is a bit too much. However adding 16 pixels for the top and bottom extends the height of the screen and makes a few games look better that utilize the region, and also somewhat fixes the aspect ratio. 16 pixels for top and bottom isn't quite "accurate" though, but in RetroCopy there is an option to adjust aspect ratio which will default to something closely approximating the real thing. Emulators could almost show PAL games in a widescreen format if they wanted (without the borders of course), which is interesting.

Anyhow I have thrown up a few pictures illustrating this on my new website/blog. So if you are interested take a look at them.

Emulation Aspect Ratios
  View user's profile Send private message Visit poster's website
  • Joined: 27 Apr 2005
  • Posts: 420
  • Location: Australia
Reply with quote
Post Posted: Wed Jul 29, 2009 6:03 am
Kega Fusion has borders and a good attempt at aspect ratio. The old Massage had borders too.
  View user's profile Send private message
  • Joined: 26 Aug 2008
  • Posts: 292
  • Location: Australia
Reply with quote
Post Posted: Wed Jul 29, 2009 6:14 am
DMEnduro wrote
Kega Fusion has borders and a good attempt at aspect ratio. The old Massage had borders too.


Ah thanks for mentioning Kega, I keep forgetting it emulates SMS also. It does a great job actually at handling aspect ratio. Steve Snake didn't work on the WII emulators did he? :)
  View user's profile Send private message Visit poster's website
  • Site Admin
  • Joined: 19 Oct 1999
  • Posts: 14744
  • Location: London
Reply with quote
Post Posted: Wed Jul 29, 2009 9:13 am
Last edited by Maxim on Wed Mar 29, 2017 3:43 pm; edited 3 times in total
Charles' docs explain it pretty well. At 256x192 on an NTSC screen, the screen is effectively 284 SMS pixels wide and 243 lines tall. That makes the SMS screen 90% of the width and 79% of the height. It therefore comes out with an aspect ratio of 1.5211, which is equivalent to a pixel aspect ratio of 1.1408.

In PAL-land, it's a little confusing - Charles' docs say there's 294 lines vertically but PAL only has 288. If we go with 288, there's 67% vertical coverage and the same 90% horizontally, giving an aspect ratio of 1.803 and a pixel aspect ratio of 1.352.

Alternatively, you can look at line-accurate framegrabs. Here's an old one I made years ago:



The framegrabber may have made some errors in getting the exact position, especially since the signal is not quite standard - just close enough to work on TVs. Anyway, this shows 16/384 pixels gap on both sides (not sure if this is a 256px or 248px shot), 44 lines on the top and 52 on the bottom, giving a frame aspect ratio of 1.833 and a pixel aspect ratio of 1.375.

On the other hand, if you go and look at any game with a squares or circles in it you can see almost all were designed for a 1:1 pixel aspect ratio.
megamania-realsms.jpg (38.86 KB)
megamania-realsms.jpg

  View user's profile Send private message Visit poster's website
  • Joined: 26 Aug 2008
  • Posts: 292
  • Location: Australia
Reply with quote
Post Posted: Wed Jul 29, 2009 10:08 am
Maxim wrote
Charles' docs explain it pretty well. At 256x192 on an NTSC screen, the screen is effectively 284 SMS pixels wide and 243 lines tall. That makes the SMS screen 90% of the width and 79% of the height. It therefore comes out with an aspect ratio of 1.5211, which is equivalent to a pixel aspect ratio of 1.1408.

In PAL-land, it's a little confusing - Charles' docs say there's 294 lines vertically but PAL only has 288. If we go with 288, there's 67% vertical coverage and the same 90% horizontally, giving an aspect ratio of 1.803 and a pixel aspect ratio of 1.352.

Alternatively, you can look at line-accurate framegrabs. Here's an old one I made years ago:


Nice framegrab. On my blog I showed another framegrab from California Games (the surfing one), it's horrible quality but has the basic dimensions intact. It's similar to yours. It's certainly helpful in getting an overview of the real aspect ratio.

I basically looked at how the TVs were displaying it though in regards to overscan, and picked a nice balance between them. I think Kega did the same as it's only ~20 pixels or so for its borders, same with the WII emulator.

There are a few things in Charles VDP doc which are a bit misleading or incorrect that I will cover in my doc if he doesn't get around to it. I need to get my hands on two master systems (VDP1/2) and get a dev system up and running for verification whenever I find the extra time!
  View user's profile Send private message Visit poster's website
  • Joined: 06 Feb 2009
  • Posts: 110
  • Location: Toulouse, France
Reply with quote
Post Posted: Fri Jul 31, 2009 8:35 am
Quote
There are a few things in Charles VDP doc which are a bit misleading or incorrect that I will cover in my doc if he doesn't get around to it. I need to get my hands on two master systems (VDP1/2) and get a dev system up and running for verification whenever I find the extra time!


which ones ? tI'm very curious about that too...
ABout this topic, we discussed that some times back on spritesmind

To resume, what determines the aspect ratio is only the number of vertical lines (height) and the pixel clock (width).
Pixel clock is MCLK/10 on the SMS.
VDP timings are described accurately by Charles in his docs:
PAL is 313 lines with 288 active lines which makes approx. 48 'border' lines at bottom/top (probably not so equally repartited however)
NTSC is 262 lines with 243 active lines, which makes 27 'border' lines at the top , 24 at the bottom
Line width s 342 pixel clocks with 284 active pixels which makes 13 'border' pixels on the left and 15 on the right.

So 4:3 means actually 284x243 for NTSC and 284x288 for PAL.

I have emulated both (vertical & horizontal) borders in my SMS Plus port for the Wii (smsplus-gx) but to have the correct aspect ratio , I had to upscale the 284 pixels line to something like 728 pixels (even if the Wii can output up to 720 pixels).This has something to do with the Wii "pixel aspect ratio" in regards to the SMS one.

Also, most TV won't let you see the entire borders because of overscan so, if you are emulating vertical borders on a computer screen (either windowed or fullscreen), you have to reduce that a mount a little to match what you will see on your TV screen with respect to aspect ratio.

By the way, the Wii can also output a true 240 "non interlaced" lines signal so the output result really match my SMS :-)
  View user's profile Send private message
  • Site Admin
  • Joined: 19 Oct 1999
  • Posts: 14744
  • Location: London
Reply with quote
Post Posted: Fri Jul 31, 2009 10:47 am
Eke wrote
the Wii can also output a true 240 "non interlaced" lines signal so the output result really match my SMS :-)

That's how I run it :)
  View user's profile Send private message Visit poster's website
  • Joined: 06 Feb 2009
  • Posts: 110
  • Location: Toulouse, France
Reply with quote
Post Posted: Wed Aug 05, 2009 8:17 pm
hehe... glad you like this feature
any complaints/bug reports so far ?

I'm afraid I have less time for coding than before...and did not put very much work into this one for a looong time :-(
  View user's profile Send private message
  • Site Admin
  • Joined: 19 Oct 1999
  • Posts: 14744
  • Location: London
Reply with quote
Post Posted: Wed Aug 05, 2009 8:56 pm
(Getting OT...)

Emulation-wise it's fine; the only thing I'd like is a better GUI, maybe through libwiigui as seems to be the way these days. Failing that, there's a bunch of UI annoyances that I could list but it'd be more productive to just fix them myself :)
  View user's profile Send private message Visit poster's website
Reply to topic



Back to the top of this page

Back to SMS Power!