<< Back to contents.

CharPad 2.8 User Manual - Subchrist Software, 2021.

Multi-colour character images.

Multi-colour character images are 4x8 pixels in size and use a bit-depth of 2 bits-per-pixel.

They can therefore use four colours...

• Background colour (0-15), defined in the VIC colour register at memory address $d021 (53281). Pixel = "00".

• Multi-colour 1 (0-15), defined in the VIC colour register at memory address $d022 (53282). Pixel = "01".

• Multi-colour 2 (0-15), defined in the VIC colour register at memory address $d023 (53283). Pixel ="10".

• Foreground colour (0-7), screen-position dependent, defined in the colour-RAM matrix from $d800 (55296). Pixel = "11".

When the VIC chip is operating in multi-colour character mode, it uses a mechanism that allows high-resolution character images to be displayed as well.

The foreground colour value (in the colour-RAM matrix) is reduced to just 3 bits to specify a colour (0-7) and the highest bit (of the nybble) is used to select multi-colour mode for any particular screen cell.

ie. any character image displayed in a screen cell using a colour value between 0-7 will appear in high-resolution mode.

Any character image displayed in a screen cell using a colour value between 8-15 will appear in multi-colour mode.

Notes...

Multi-colour character images are displayed using double-width pixels so their visible size is actually the same as that of high-resolution character images.

In standard character-mode (without using raster tricks), the Commodore 64 can display up to 256 different character images on-screen.

The following formula can be used to determine the memory address for a particular colour-RAM cell...

55296 + (y * 40) + x