Direct color demo
Posted: Sun May 06, 2012 6:02 pm
I was over at Atari Age the other day and saw a thread on getting more color on the A8 - always a big deal for those early systems. The method was rather interesting: use the 16 luminance mode and change the base color via a display list interrupt on every line, changing from red to green to blue and back to red. It did a pretty good job on the A8, so I wondered how it would look on the Genesis.
Rather than use an interrupt to change the base color on every line, I made the scroll size 128x32; the first 40 entries are set for a palette of red colors, the next 40 for green, and the next 40 for blue. Then I set the hscroll to every line, and set the hscroll table so that the first line uses an hscroll of 0, the next 320, and the next 640. So we have each line set to a different color without any CPU overhead.
I use scroll layer B for the bitmap, and A for text overlay.
Because the Genesis only has 8 luminance levels, I use half of each palette for the different levels. That would leave the other half free for other uses. So you get 512 colors set directly over three lines. For better vertical resolution, I just use the values for the line in question, so the overall luminance is kept for 320x224. The color has a vertical resolution of one third that.
The result is kinda interesting - for such a simple method of displaying a 15-bit image, it looks better than most 16 color quantizer results that I have tried, like sixpack. It works better for some images than others. The slideshow demo linked below has several nature images, a few screenshots from Wolf3D, and one anime image.
http://www.mediafire.com/?lwxdzhfnohtxfwu
Rather than use an interrupt to change the base color on every line, I made the scroll size 128x32; the first 40 entries are set for a palette of red colors, the next 40 for green, and the next 40 for blue. Then I set the hscroll to every line, and set the hscroll table so that the first line uses an hscroll of 0, the next 320, and the next 640. So we have each line set to a different color without any CPU overhead.
I use scroll layer B for the bitmap, and A for text overlay.
Because the Genesis only has 8 luminance levels, I use half of each palette for the different levels. That would leave the other half free for other uses. So you get 512 colors set directly over three lines. For better vertical resolution, I just use the values for the line in question, so the overall luminance is kept for 320x224. The color has a vertical resolution of one third that.
The result is kinda interesting - for such a simple method of displaying a 15-bit image, it looks better than most 16 color quantizer results that I have tried, like sixpack. It works better for some images than others. The slideshow demo linked below has several nature images, a few screenshots from Wolf3D, and one anime image.
http://www.mediafire.com/?lwxdzhfnohtxfwu