VOGONS


First post, by superfury

User metadata
Rank l33t++
Rank
l33t++

Are the alternative display or VRAM modes ever used in software?

Like:
- CGA memory layout (Mapped to A0000-BFFFF) with high planes used for 16 colors instead of 4 color modes
- Same as above, but with 8-bit pixels (256 colors) enabled to create 256 color 'CGA-compatible' mode
- Planar rendering (1 bit from planes 0-3) with 8-bit pixels (256-colors) enabled
- Any 16/256 color mode with parts masked off in the attribute controller (Attribute Color Plane Enable register not equal to 15).

Author of the UniPCemu emulator.
UniPCemu Git repository
UniPCemu for Android, Windows, PSP, Vita and Switch on itch.io

Reply 1 of 2, by Jepael

User metadata
Rank Oldbie
Rank
Oldbie

Well back then when VGA was designed it was a new standard and had to be mostly backwards compatible with old standards anyway, so what would be the point to create new VGA standard which also creates new CGA features to expand regular CGA?

-EGA was CGA compatible and provided new planar 16-color 320x200 mode instead of 4-color 320x200 mode.
-VGA was CGA/EGA compatible and provides new non-planar 256 color 320x200 mode with linear addressing.
-Planar rendering, well, kind of. VGA just does not have 8 planes but only 4 planes just like EGA. VGA already kind of uses two 4-bit EGA pixels to get one 8-bit color index. Both EGA and VGA fetch a byte from four planes, but the bits just get sequenced differently to support having a 8-bit color index in a plane. May be possible to have a planar 4-bit mode and turn the 256 color mode logic on, but I would not count on compatibility between chipsets.
-Color Plane Enable should mask off all serialized pixel data from video ram, and the masked 4-bit values then go through EGA palette and the 256 color mode logic that combines two 4-bit pixels to one 8-bit pixel. Then you have the VGA DAC with palette and 8-bit pixel mask register. But no idea if ever used in software, 16 color modes maybe, but not useful in 8-bit mode as it would mask two color bits off.

Reply 2 of 2, by superfury

User metadata
Rank l33t++
Rank
l33t++

What I meant was combinations of the display planes, which aren't used by regular software.

At the first point I mentioned, I meant that the higher planes (planes 2&3) are usually unused by CGA software (thus creating video modes 4&5). Is there software that actually uses those higher planes, to get some sort of 'CGA' interleaved 16-color mode?

The second point I mentioned is essentially the same as the above mode, but with the 8-bit pixels enabled (latching two 4-bit(16 color) pixels together) to get a 256-color mode.

With planar rendering I indeed meant using the four planes of the VGA/EGA (keep popping 1 bit of planes 0, 1, 2 and 3 to get 4 bits) and latching the two 4-bits values together to get some kind of 256-color mode 12h-like(except lower resolution) mode.

And I indeed meant any 16/256 color modes possible on the VGA(CGA/EGA/VGA) with toggling the planes off using the Color Plane Enable mask. Anyone knows about software that actually uses them? (Maybe monochrome color modes set it to 1 and 4-color modes set it to 3 to get their respective limits.
Maybe it could be used in 256-color mode to get different color pallettes (re-ordering the DAC 18-bit color pallette to use bits 0&4, 1&5, 2&6 and 3&7 instead of the usual mode 13h CGA-like pallette(bits 0-3=ARGB, but as used for mode 13h(dark to bright pallette etc.)) structure. So effectively re-ordering the pallette to use a 8-bit ARGBARGB format. After that you can simply turn off the color plane enable bits 0, 1, 2 and/or 3 to get different subsets of colors (disabling blue, read, green, bright channels effectively to get a blue, green, red, bright combination screen pallette, so you can switch from a, lets say, yellow(set to 0xE)? So when I think about it, you simply get the color pallette you want by setting the mask to the color 0-15 of the CGA pallette you want? Or am I making a little mistake here?)

Author of the UniPCemu emulator.
UniPCemu Git repository
UniPCemu for Android, Windows, PSP, Vita and Switch on itch.io