Home |
Informative Texts | Small DAC Colours
Neil Franklin's Small DAC Colours Page
This page shows the Colour combinations for DACs of various smaller
resolutions. It was created as part of designing an simple DAC for an
small video console.
1Bit/Channel, 3bit RGB, 8 Primary Colours
1 bit gives 2 levels: 0/1 (= 0x00 = 0) and 1/1 (= 0xFF = 255).
1Bit/Channel + Intensity, 4bit RGBI, 16 CGA Colours
"1+" bits gives 3 levels: 0/3 (= 0x00 = 0), 2/3 (= 0xAA = 170) and 3/3 (=
0xFF = 255). This here is the original CGA Monitor arrangement. From this
differ many CGA Monitor clones (and EGA and later colour palette settings),
in which intense black became dark gray (giving 4 levels of
black/darkgray/lightgray/white) and non-intense yellow became brown.
Original CGA 3 "gray" levels:
CGA clone and EGA and later colour palette 4 gray levels:
2Bits/Channel, merged all 3 LSBs, 4bit RGBL, 16 Colours
2 bits give full 4 levels: 0/3 (= 0x00 = 0), 1/3 (= 0x55 = 85), 2/3 (= 0xAA
= 170) and 3/3 (= 0xFF = 255). Common L bit for low bit of all 3 channels.
This is not the CGA arrangement. It lacks primary colours, instead
having pastels. But it has an simpler DAC and gives dark gray as well, for
4 level black/darkgray/lightgray/white).
The resulting 4 gray levels:
2Bits/Channel, full 6bit RRGGBB, 64 EGA Colours
2 bits give 4 levels: 0/3 (= 0x00 = 0), 1/3 (= 0x55 = 85), 2/3 (= 0xAA =
170) and 3/3 (= 0xFF = 255). No common L bit for all 3 channels, all have
theor own 2 bits. This is what the EGA was actually capable of, but it was
usually only loaded with values which near-emulated CGA.
The resulting same 4 gray levels:
6Levels/Channel, (4or)6(or8)bit RAMDAC, 216 VGA Colours
Strictly the VGAs 6 bit per Channel allowed 2^(3*6)=2^18=262144 colours,
but the 8bit RAMDAC limited it to using 256 of these. 0..15 were loaded
with the same CGA emulation colours as on EGA. The next 216 places were
set to these 6*6*6=216 6-level values: 0/5 (= 0x00 = 0), 1/5 (= 0x33 = 51),
2/5 (= 0x66 = 102), 3/5 (= 0x99 = 153), 4/5 (= 0xCC = 204) and 5/5 (= 0xFF
= 255), which all already fit into 4 bits per channel (at 0,3,6,9,A,F).
These were once known as the 216 "web safe" colours.
I have already depicted these 216 Colours in 2 older files:
216 arranged in 3x2 Blocks of 6x6
216 arranged in 6x1 Blocks of 6x6
The resulting 6 gray levels:
3|3|2Bits/Channel, reduced blue, 8bit RRRGGGBB, 256 Colours
Red and green 3 bits give 8 levels: 0/70 (= x00 = 0), 1/7 (= 0x24 = 36),
2/7 (= 0x49 = 73), 3/7 (= 0x6D = 109), 4/7 (= 0x92 = 146), 5/7 (= 0xB6 =
182), 6/7 (= 0xDB = 219) and 7/7 (= 0xFF = 255). Blue 2 bits give 4 levels:
0/3 (= 0x00 = 0), 1/3 (= 0x55 = 85), 2/3 (= 0xAA = 170) and 3/3 (= 0xFF =
255). But "gray" levels have missmatch of 1..6/7 to 1..2/3, discoloured.
The resulting 8 R+G driven "gray" levels:
The resulting 4 B driven "gray" levels:
3Bits/Channel, merged G+B LSBs, 8bit RRRGGBBL, 256of512 Colours
3 bits give 8 levels: 0/70 (= x00 = 0), 1/7 (= 0x24 = 36), 2/7 (= 0x49 =
73), 3/7 (= 0x6D = 109), 4/7 (= 0x92 = 146), 5/7 (= 0xB6 = 182), 6/7 (=
0xDB = 219) and 7/7 (= 0xFF = 255). Fills full 256 colours and gives more
levels than 64 colour, but relative to full 3*3=9bit RRRGGGBBB it has blue
or green LSB errors, but these are avoidable by programs, giving worst case
an fallback to 64 colours.
With blue LSB errors:
With green LSB errors:
The resulting 8 gray levels:
Home |
Informative Texts | Small DAC Colours
This page is by Neil Franklin, last modification 2008.11.27