|
ForumsSega Master System / Mark III / Game GearSG-1000 / SC-3000 / SF-7000 / OMV |
Home - Forums - Games - Scans - Maps - Cheats - Credits Music - Videos - Development - Hacks - Translations - Homebrew |
Author | Message |
---|---|
|
TMS9918 colors for SMS VDP
Posted: Fri Mar 10, 2006 7:08 am
|
Using a 315-5124 VDP in a US NTSC SMS 1 console, here are the CRAM values that match the TMS9918 palette.
The TMS9918 modes of the SMS use a slightly different palette than a true TMS9918, and (thankfully) there are direct CRAM equivalents for each color. TMS color CRAM value Color (%--BBGGRR) $00 $00 Transparent (Black) $01 $00 Black $02 $08 Green 0 $03 $0C Green 2 $04 $10 Blue 0 $05 $30 Blue 1 $06 $01 Red 0 $07 $3C Cyan $08 $02 Red 1 $09 $03 Red 2 $0A $05 Yellow 0 $0B $0F Yellow 1 $0C $04 Green 1 $0D $33 Pink $0E $15 Gray $0F $3F White So an SMS emulator would want to use these, but not (for example) when emulating the SC-3000H or SG-1000 which have a TMS9918 and different palette. |
|
|
Posted: Fri Mar 10, 2006 9:39 am |
Thank you.
This is greatly useful. Also note that the Game Gear supports legacy TMS9918 modes but using CRAM for palette, so the CRAM has to be filled with those values and you can play SG-1000 games on Game Gear: (this is an old test I made, AFAIK with non correct values) |
|
|
Posted: Fri Mar 10, 2006 11:28 am |
Wow, most games look horrible with that palette though.
Here is a RGB24 version: DCB 0x00,0x00,0x00 DCB 0x00,0x00,0x00 DCB 0x00,0xAA,0x00 DCB 0x00,0xFF,0x00 DCB 0x00,0x00,0x55 DCB 0x00,0x00,0xFF DCB 0x55,0x00,0x00 DCB 0x00,0xFF,0xFF DCB 0xAA,0x00,0x00 DCB 0xFF,0x00,0x00 DCB 0x55,0x55,0x00 DCB 0xFF,0xFF,0x00 DCB 0x00,0x55,0x00 DCB 0xFF,0x00,0xFF DCB 0x55,0x55,0x55 DCB 0xFF,0xFF,0xFF I hope that is the correct conversion. Also, shouldn't the names of Green 0 & Green 1 change names? |
|
|
Posted: Fri Mar 10, 2006 1:31 pm |
I made a quick comparison here:
http://www.smspower.org/maxim/forumstuff/colours.html One thing I would mention is that the SMS colour values are wrong. We've gone into this before, but failed to come up with a reliable way of getting "correct" colours, since consumer video capture hardware does not tend to cope well with artificial images like these, especially coming through a dodgy RF connection (as I was using at that time). However, I would like to add this observation: in Bock's Birthday 2004, I have a huge dark grey "xiao" character in the background, and on the TV, it is a much lighter grey colour than I expected. This would appear to be a "gamma" issue - TVs have a "gamma" of 2.2 which will tend to skew colours from linear distribution (00 55 aa ff) to one bunched at the high end (more like 00 88 cc ff, total guess). Does anyone have a copy of the images from the thread linked above? |
|
|
Posted: Fri Mar 10, 2006 1:44 pm |
For what it's worth, I also made a hacked version of Tototek's SMS-Pro/GG-Pro menu ROM to set up the palette correctly (?) for SG-1000 games.
http://disgruntleddesigner.com/chrisc/segahacking/ChrisBoot.zip |
|
|
Posted: Fri Mar 10, 2006 3:13 pm |
Yes, which is why it's a good distinction to make. I was testing my software under Kega and the colors (being true to the TMS9918) didn't match what I saw on my TV at all.
Probably, we are just talking about filling bits here ;)
Oh, yes. I sort of guessed the names as I went along and as the greens aren't grouped together I must have transposed them. ;) |
|
|
Posted: Fri Mar 10, 2006 3:50 pm |
The "official" names (from the TMS9918 manual, apparently) are: 0 Transparent 1 Black 2 Medium Green 3 Light Green 4 Dark Blue 5 Light Blue 6 Dark Red 7 Cyan 8 Medium Red 9 Light Red A Dark Yellow B Light Yellow C Dark Green D Magenta E Grey F White |
|
|
Posted: Fri Mar 10, 2006 4:27 pm |
Here's the color editing program if anyone wants to test on their console.
I used a hardcoded delay to move the split-screen flicker into the right border so there would be no interruption between the TMS9918 (bottom) and SMS (top) color display areas, not sure how that will work on a PAL machine. |
|
|
Posted: Fri Mar 10, 2006 9:18 pm |
I just tested on a PAL SMS with the same results.
There is a tiny bit of noise in the picture (I circled where it is, although it's not really noticeable in the photo) due to different timing but the demo functions perfectly. I tried a real SG game for comparison - The Castle runs nicely on my RAM cart :) I also used the better camera with a nice long exposure setting to grab that one without black bars. |
|