 |
Notes
 |
For the 1024x768 VGA tile driver:
 |
2 longs are required for each text foreground/background color
combo, arranged as:
 | $ff_bb_ff_bb |
 | $ff_ff_bb_bb |
 | where 'ff' is the foreground color and 'bb' is the background
color |
 | 2 longs needed because characters are in an interleaved pair |
 | The first long is the color for the first character in a pair,
the second long is for the second character in a pair. |
 | Demo routine "print()" only allows for 8 fore/back combinations
(using longs 0 to 15) |
|
 |
1 long required for box colors, arranged as:
 | $tl_br_fi_bb |
 | where 'tl' is top-left edge, 'br' is bottom-right edge, 'fi' is
focus indicators, and 'bb' is background color |
 | The demo "box()" procedure hardwired to add 16 to input color number
to pick box color and adds 5 to input color number to pick text color
for box...
 | So, "box(left,top,clr,str)" uses color number 16+clr for box
colors and 5+clr for text color. You probably want the 'bb'
background colors of these two to match! Note that this limits
you to 4 box colors. |
|
|
 |
1 long used for graphics colors, arranged as
 | $00_11_22_33 |
 | where 00,11,22,33 are the selectable graphics colors 0,1,2,3
|
 | Demo hardwired to use
the 21st long (last one) for the graphics colors
|
|
 |
The Propeller's "tile driver" video uses 32-bit (long) values to define
a four color palette |
 |
The "color_ptr" parameter, given to the tile driver, specifies the
location of the data block of up to 64 different long palette values
|
 |
Each long palette represents 4 different colors, one byte each.
Each color byte uses 2 bits for each primary colors, RGB, arranged as
RGBx. The "x" represents the two least significant bits, which are
ignored. |
 |
Parallax gives this example of a 32-bit long palette, represented as
a 16-digit quaternary (2-bit) number: |
 |
%%3330_0110_0020_3300 or $FC1408F0 |
 |
The first byte, %%3330 (binary %11111100), is the color white |
 |
The second byte, %%0110, is the color dark cyan |
|
|