Commodore 128 Programmer's Reference Manual page 255

Hide thumbs Also See for 128:
Table of Contents

Advertisement

n
THE POWER BEHIND COMMODORE 128 GRAPHICS
245
n
BITS
COLOR INFORMATION COMES FROM
P
00
Background color #0 (screen color)
j I
01
Upper four bits of video matrix
10
Lower four bits of video matrix
11
Color RAM
/
(
"
; ;
Figure 8-26. Multi-Color Bit Map Pixel Color Assignments
R
THE BIT MAP
Bit patterns determine how color is assigned to the multi-color bit map screen. If the bit
p
pair is equal to 00 (binary), color is taken from background color register 0 (location
| j
53281). If the bit pair is equal to 01 (binary), the color assigned to these two pixels
comes from the upper nybble of video matrix. If the bit pair in the bit map is equal to
^
10 (binary), then the color assigned to those two pixels comes from the lower nybble of
I
video matrix. Finally, if the bit pair in the bit map is equal to 11 (binary), the color is
1
taken from the lower four bits of color RAM. Unlike multi-color character mode, the
screen is either all standard bit map, or all multi-color bit map, unless you develop a
p|
sophisticated interrupt-driven application program that handles the two separate bit
I
maps.
-
COLOR RAM
In multi-color bit map mode, color RAM is used if the bit pair from the bit map equals
11 (binary). Each color RAM location may have one of sixteen color codes, which
means that one 8 by 8 bit map area can have black, red, white and blue colors,
respectively, for the background color register 0, the upper nybble, the lower nybble, and
the color RAM. The 8 by 8 multi-color bit map area next to it can have black, red, white
and green colors, since each color RAM location is independent of any other. The other
three color sources usually remain constant throughout a bit map screen, though you can
change the upper and lower nybbles of the video matrix. The background color register
is almost always the same throughout a bit map screen.
The C128 has powerful and varied graphics display capabilities. Certain applica
tions call for one type of display over another. Experiment with them all and see which
one meets your needs best. Figures 8-28 through 8-32 provide a graphics programming
summary that should be helpful in understanding graphics on the C128.
SPLIT-SCREEN MODES
The Commodore 128 has a split-screen feature that allows you to display the top portion
of the screen in bit map mode and the bottom portion in character mode. This allows you to
enter a BASIC graphics program and RUN it while the BASIC program listing is

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents