VOGONS


First post, by clb

User metadata
Rank Newbie
Rank
Newbie

I have been wondering why CGA standard had support for two 320x200 4-color video modes, mode 04h and mode 05h, which seem to behave the same on my VGA cards.

On the Wikipedia page about CGA Adapter: https://en.wikipedia.org/wiki/Color_Graphics_ … _graphics_modes it says that Mode 05h was basically Mode 04h, but with a different color palette compared to the two color palettes available in Mode 04h.

I have a few different VGA ISA and PCI color adapters, and all of those that I tested, Mode 05h behaves identical to Mode 04h. That is, there is no LIGHT RED color displayed, but instead the third color shows as MAGENTA instead, just like in Mode 04h.

I wonder if the light red color was more like a bug/unintended artifact, that was a side result of disabling color bursting, rather than an intended effect? And that is why the newer standards did nor perpetuate that color change? Or do you think the newer VGA color adapters were just a bit sloppy in implementing support for the CGA color modes?

Attachments

Reply 2 of 7, by mkarcher

User metadata
Rank Oldbie
Rank
Oldbie

EGA and VGA do not support the CGA mode 5 palette. IBM could have initialized the EGA palette in mode 5 to match the CGA mode 5 palette, but they chose to not do so. Mode 5 was intended as grayscale mode on the composite output, a feature that was dropped on the EGA.

A lot of clone EGA and VGA card provide a CGA emulation mode that does support the mode 5 palette though.

Reply 3 of 7, by kdr

User metadata
Rank Member
Rank
Member
clb wrote on 2022-09-21, 17:45:

I wonder if the light red color was more like a bug/unintended artifact, that was a side result of disabling color bursting, rather than an intended effect?

It was intentionally designed that way by IBM but left undocumented. (Just like the 16-color 160x100 "graphics" mode.)

My theory is that the designers of the CGA card ended up with a couple of 'spare' logic gates (since the logic gates on 74LS chips come in sets of 2 and 4 gates per chip) and decided to make the BW mode bit do something slightly more useful for users with a colour monitor.

Reply 4 of 7, by clb

User metadata
Rank Newbie
Rank
Newbie

Thanks, that is interesting to know!

Somewhat related I guess, I suppose for the same reason the mode 00h is working identical to mode 01h on VGA cards? I.e. mode 00h is supposed to be a black&white mode, but on a VGA card it works out to be a 16 color mode just the same.

Reply 5 of 7, by Benedikt

User metadata
Rank Oldbie
Rank
Oldbie

AFAIK, the early CGA cards only had a very limited number of different shades of gray on the composite output. Maybe cyan and magenta would have resulted in the same shade?
Incidentally, both effects can be restored on an EGA card using a TSR driver, because EGA conveniently supports four shades of gray.

Reply 6 of 7, by Jo22

User metadata
Rank l33t++
Rank
l33t++

VGA cards (ISA) do support multiple CGA palettes in CGA emulation mode.
To enter it, a mode utility is needed. It was included on the driver diskette.

That being said, we must differentiate between register compatibility and BIOS compatibility.

The CGA routines used to be part of the PC BIOS. It's used if a real CGA is installed.
Programs/games calling BIOS routines to set up a CGA mode or palette will work on VGA cards.
Because, the VGA BIOS does contain similar routines.

Register compatibility is another thing.
The IBM EGA/VGA card did not contain a Motorola CRTC anymore.
It's not fully register compatible, thus. Unsupported register writes will be ignored.
And in order to be fully IBM VGA compatible, all third-party VGA cards behave the same.
That means they don't support CGA features on purpose, except in emulation mode.

"Time, it seems, doesn't flow. For some it's fast, for some it's slow.
In what to one race is no time at all, another race can rise and fall..." - The Minstrel

//My video channel//

Reply 7 of 7, by Jo22

User metadata
Rank l33t++
Rank
l33t++

Here's an older example of mine of such a mode utility..
https://www.youtube.com/watch?v=cu88uKmqlEU

In the video, CGA Compatibility Tester is run, because of a flaw of the OAK card/utility.
After running it, the appropriate registers were set and Popcorn appears in a reddish tone (correct).

http://www.oldskool.org/pc/cgacomp

Re: OAK OTI-037c - 800x600 mode ?

"Time, it seems, doesn't flow. For some it's fast, for some it's slow.
In what to one race is no time at all, another race can rise and fall..." - The Minstrel

//My video channel//