<s>
Color	B-General_Concept
Television	I-General_Concept
Interface	I-General_Concept
Adaptor	I-General_Concept
(	O
CTIA	O
)	O
and	O
its	O
successor	O
Graphic	B-General_Concept
Television	I-General_Concept
Interface	I-General_Concept
Adaptor	I-General_Concept
(	O
GTIA	B-General_Concept
)	O
are	O
custom	O
chips	O
used	O
in	O
the	O
Atari	B-Device
8-bit	I-Device
family	I-Device
of	O
computers	O
and	O
in	O
the	O
Atari	B-General_Concept
5200	I-General_Concept
home	B-Device
video	I-Device
game	I-Device
console	I-Device
.	O
</s>
<s>
In	O
these	O
systems	O
,	O
a	O
CTIA	O
or	O
GTIA	B-General_Concept
chip	O
works	O
together	O
with	O
ANTIC	B-General_Concept
to	O
produce	O
the	O
video	O
display	O
.	O
</s>
<s>
ANTIC	B-General_Concept
generates	O
the	O
playfield	O
graphics	O
(	O
text	O
and	O
bitmap	O
)	O
while	O
CTIA/GTIA	B-General_Concept
provides	O
the	O
color	O
for	O
the	O
playfield	O
and	O
adds	O
overlay	O
objects	O
known	O
as	O
player/missile	O
graphics	O
(	O
sprites	O
)	O
.	O
</s>
<s>
Under	O
the	O
direction	O
of	O
Jay	O
Miner	O
,	O
the	O
CTIA/GTIA	B-General_Concept
chips	O
were	O
designed	O
by	O
George	O
McLeod	O
with	O
technical	O
assistance	O
of	O
Steve	O
Smith	O
.	O
</s>
<s>
Color	B-General_Concept
Television	I-General_Concept
Interface	I-General_Concept
Adaptor	I-General_Concept
and	O
Graphic	B-General_Concept
Television	I-General_Concept
Interface	I-General_Concept
Adaptor	I-General_Concept
are	O
names	O
of	O
the	O
chips	O
as	O
stated	O
in	O
the	O
Atari	O
field	O
service	O
manual	O
.	O
</s>
<s>
Various	O
publications	O
named	O
the	O
chips	O
differently	O
,	O
sometimes	O
using	O
the	O
alternative	O
spelling	O
Adapter	O
or	O
Graphics	O
,	O
or	O
claiming	O
that	O
the	O
"	O
C	O
"	O
in	O
"	O
CTIA	O
"	O
stands	O
for	O
Colleen/Candy	O
and	O
"	O
G	O
"	O
in	O
"	O
GTIA	B-General_Concept
"	O
is	O
for	O
George	O
.	O
</s>
<s>
Atari	O
had	O
built	O
their	O
first	O
display	O
driver	O
chip	O
,	O
the	O
Television	B-General_Concept
Interface	I-General_Concept
Adaptor	I-General_Concept
but	O
universally	O
referred	O
to	O
as	O
the	O
TIA	B-General_Concept
,	O
as	O
part	O
of	O
the	O
Atari	B-General_Concept
2600	I-General_Concept
console	O
.	O
</s>
<s>
The	O
TIA	B-General_Concept
display	O
logically	O
consisted	O
of	O
two	O
primary	O
sets	O
of	O
objects	O
,	O
the	O
"	O
players	O
"	O
and	O
"	O
missiles	O
"	O
that	O
represented	O
moving	O
objects	O
,	O
and	O
the	O
"	O
playfield	O
"	O
which	O
represented	O
the	O
static	O
background	O
image	O
on	O
which	O
the	O
action	O
took	O
place	O
.	O
</s>
<s>
The	O
chip	O
used	O
data	O
in	O
memory	B-General_Concept
registers	I-General_Concept
to	O
produce	O
digital	O
signals	O
that	O
were	O
converted	O
in	O
realtime	O
via	O
a	O
digital-to-analog	O
converter	O
and	O
RF	O
modulator	O
to	O
produce	O
a	O
television	O
display	O
.	O
</s>
<s>
The	O
conventional	O
way	O
to	O
draw	O
the	O
playfield	O
is	O
to	O
use	O
a	O
bitmap	O
held	O
in	O
a	O
frame	B-Algorithm
buffer	I-Algorithm
,	O
in	O
which	O
each	O
memory	O
location	O
in	O
the	O
frame	B-Algorithm
buffer	I-Algorithm
represents	O
one	O
or	O
more	O
locations	O
on	O
the	O
screen	O
.	O
</s>
<s>
In	O
the	O
case	O
of	O
the	O
2600	O
,	O
which	O
normally	O
used	O
a	O
resolution	O
of	O
160x192	O
pixels	O
,	O
a	O
frame	B-Algorithm
buffer	I-Algorithm
would	O
need	O
to	O
have	O
at	O
least	O
160x192/8	O
=	O
3840	O
bytes	O
of	O
memory	O
.	O
</s>
<s>
Built	O
in	O
an	O
era	O
where	O
RAM	B-Architecture
was	O
very	O
expensive	O
,	O
the	O
TIA	B-General_Concept
could	O
not	O
afford	O
this	O
solution	O
.	O
</s>
<s>
Instead	O
,	O
the	O
system	O
implemented	O
a	O
display	O
system	O
that	O
used	O
a	O
single	O
20-bit	O
memory	B-General_Concept
register	I-General_Concept
that	O
could	O
be	O
copied	O
or	O
mirrored	O
on	O
the	O
right	O
half	O
of	O
the	O
screen	O
to	O
make	O
what	O
was	O
effectively	O
a	O
40-bit	O
display	O
.	O
</s>
<s>
The	O
TIA	B-General_Concept
also	O
included	O
several	O
other	O
display	O
objects	O
,	O
the	O
"	O
players	O
"	O
and	O
"	O
missiles	O
"	O
.	O
</s>
<s>
The	O
key	O
to	O
the	O
TIA	B-General_Concept
system	O
,	O
and	O
the	O
2600	O
's	O
low	O
price	O
,	O
was	O
that	O
the	O
system	O
implemented	O
only	O
enough	O
memory	O
to	O
draw	O
a	O
single	O
line	O
of	O
the	O
display	O
,	O
all	O
of	O
which	O
held	O
in	O
registers	O
.	O
</s>
<s>
This	O
scheme	O
drew	O
the	O
screen	O
line-by-line	O
from	O
program	O
code	O
on	O
the	O
ROM	B-Protocol
cartridge	I-Protocol
,	O
a	O
technique	O
known	O
as	O
"	O
racing	O
the	O
beam	O
"	O
.	O
</s>
<s>
Instead	O
of	O
the	O
user	O
's	O
programming	O
updating	O
the	O
CTIA	O
's	O
registers	O
based	O
on	O
its	O
interrupt	O
timing	O
,	O
the	O
new	O
ANTIC	B-General_Concept
would	O
handle	O
this	O
chore	O
,	O
reading	O
data	O
from	O
a	O
framebuffer	B-Algorithm
and	O
feeding	O
that	O
to	O
the	O
CTIA	O
on	O
the	O
fly	O
.	O
</s>
<s>
As	O
a	O
result	O
of	O
these	O
changes	O
,	O
the	O
new	O
chips	O
provide	O
greatly	O
improved	O
number	O
and	O
selection	O
of	O
graphics	O
modes	O
over	O
the	O
TIA	B-General_Concept
.	O
</s>
<s>
Instead	O
of	O
a	O
single	O
playfield	O
mode	O
with	O
20	O
or	O
40	O
bits	O
of	O
resolution	O
,	O
the	O
CTIA/ANTIC	O
pair	O
can	O
display	O
six	O
text	O
modes	O
and	O
eight	O
graphics	O
modes	O
with	O
various	O
resolutions	O
and	O
color	O
depths	O
,	O
allowing	O
the	O
programmer	O
to	O
choose	O
a	O
balance	O
between	O
resolution	O
,	O
colours	O
,	O
and	O
memory	O
use	O
for	O
their	O
display	O
.	O
</s>
<s>
This	O
feature	O
provides	O
alternate	O
expressions	O
of	O
ANTIC	B-General_Concept
's	O
high-resolution	O
graphics	O
modes	O
presenting	O
1	O
bit	O
per	O
pixel	O
,	O
2	O
colors	O
with	O
one-half	O
color	O
clock	O
wide	O
pixels	O
as	O
4	O
bits	O
per	O
pixel	O
,	O
up	O
to	O
16	O
colors	O
,	O
two-color	O
clock	O
wide	O
pixels	O
.	O
</s>
<s>
From	O
this	O
point	O
,	O
all	O
new	O
Atari	O
units	O
were	O
equipped	O
with	O
the	O
new	O
chip	O
,	O
now	O
called	O
GTIA	B-General_Concept
,	O
that	O
supported	O
the	O
new	O
color	O
interpretation	O
modes	O
.	O
</s>
<s>
The	O
original	O
Atari	O
800/400	O
operating	O
system	O
supported	O
the	O
GTIA	B-General_Concept
alternate	O
color	O
interpretation	O
modes	O
from	O
the	O
start	O
,	O
which	O
allowed	O
for	O
easy	O
replacement	O
of	O
the	O
CTIA	O
with	O
the	O
GTIA	B-General_Concept
once	O
it	O
was	O
ready	O
.	O
</s>
<s>
Atari	O
authorized	O
service	O
centers	O
would	O
install	O
a	O
GTIA	B-General_Concept
chip	O
in	O
CTIA-equipped	O
computers	O
free	O
of	O
charge	O
if	O
the	O
computer	O
was	O
under	O
warranty	O
;	O
otherwise	O
the	O
replacement	O
would	O
cost	O
$62.52	O
.	O
</s>
<s>
GTIA	B-General_Concept
was	O
also	O
mounted	O
in	O
all	O
later	O
Atari	B-Device
XL	I-Device
and	O
XE	O
computers	O
and	O
Atari	B-General_Concept
5200	I-General_Concept
consoles	O
.	O
</s>
<s>
The	O
list	O
below	O
describes	O
CTIA/GTIA	B-General_Concept
'	O
s	O
inherent	O
hardware	O
capabilities	O
meaning	O
the	O
intended	O
functionality	O
of	O
the	O
hardware	O
itself	O
,	O
not	O
including	O
results	O
achieved	O
by	O
CPU-serviced	O
interrupts	O
or	O
display	O
kernels	O
driving	O
frequent	O
register	O
changes	O
.	O
</s>
<s>
CTIA/GTIA	B-General_Concept
is	O
a	O
television	O
interface	O
device	O
with	O
the	O
following	O
features	O
:	O
</s>
<s>
Interprets	O
the	O
Playfield	O
graphics	O
data	O
stream	O
from	O
ANTIC	B-General_Concept
to	O
apply	O
color	O
to	O
the	O
display	O
.	O
</s>
<s>
Merges	O
four	O
Player	O
and	O
four	O
Missile	O
overlay	O
objects	O
(	O
aka	O
sprites	O
)	O
with	O
ANTIC	B-General_Concept
's	O
Playfield	O
graphics	O
.	O
</s>
<s>
Player/Missile	O
objects	O
function	O
normally	O
without	O
an	O
ANTIC	B-General_Concept
Playfield	O
.	O
</s>
<s>
A	O
GTIA	B-General_Concept
color	O
interpretation	O
mode	O
can	O
generate	O
16	O
luminances	O
per	O
color	O
providing	O
a	O
256	O
color	O
palette	O
.	O
</s>
<s>
The	O
GTIA	B-General_Concept
version	O
of	O
the	O
chip	O
adds	O
three	O
alternate	O
color	O
interpretation	O
modes	O
for	O
the	O
Playfield	O
graphics	O
.	O
</s>
<s>
Reads	O
the	O
state	O
of	O
the	O
joystick	B-Device
triggers	O
(	O
bottom	O
buttons	O
only	O
for	O
the	O
Atari	B-General_Concept
5200	I-General_Concept
controllers	O
)	O
.	O
</s>
<s>
In	O
Atari	B-Device
8-bit	I-Device
computers	I-Device
,	O
three	O
of	O
the	O
pins	O
are	O
used	O
to	O
read	O
state	O
of	O
the	O
console	O
keys	O
(	O
Start/Select/Option	O
)	O
.	O
</s>
<s>
On	O
later	O
models	O
there	O
is	O
no	O
speaker	O
,	O
but	O
the	O
key	O
click	O
is	O
still	O
generated	O
by	O
GTIA	B-General_Concept
and	O
mixed	O
with	O
the	O
regular	O
audio	O
output	O
.	O
</s>
<s>
In	O
the	O
Atari	B-General_Concept
5200	I-General_Concept
,	O
the	O
pins	O
are	O
used	O
as	O
part	O
of	O
the	O
process	O
to	O
read	O
the	O
controller	O
keyboards	O
.	O
</s>
<s>
Atari	O
,	O
Inc	O
.	O
intended	O
to	O
combine	O
functions	O
of	O
the	O
ANTIC	B-General_Concept
and	O
GTIA	B-General_Concept
chips	O
in	O
one	O
integrated	O
circuit	O
to	O
reduce	O
production	O
costs	O
of	O
Atari	O
computers	O
and	O
5200	O
consoles	O
.	O
</s>
<s>
The	O
Atari	B-Device
8-bit	I-Device
computers	I-Device
map	O
CTIA/GTIA	B-General_Concept
to	O
the	O
$D0xxhex	O
page	O
and	O
the	O
Atari	B-General_Concept
5200	I-General_Concept
console	O
maps	O
it	O
to	O
the	O
$C0xxhex	O
page	O
.	O
</s>
<s>
CTIA/GTIA	B-General_Concept
provides	O
54	O
Read/Write	O
registers	O
controlling	O
Player/Missile	O
graphics	O
,	O
Playfield	O
colors	O
,	O
joystick	B-Device
triggers	O
,	O
and	O
console	O
keys	O
.	O
</s>
<s>
Many	O
CTIA/GTIA	B-General_Concept
register	O
addresses	O
have	O
dual	O
purposes	O
performing	O
different	O
functions	O
as	O
a	O
Read	O
vs	O
a	O
Write	O
register	O
.	O
</s>
<s>
This	O
problem	O
is	O
solved	O
for	O
many	O
write	O
registers	O
by	O
Operating	O
System	O
Shadow	O
registers	O
implemented	O
in	O
regular	O
RAM	B-Architecture
as	O
places	O
to	O
store	O
the	O
last	O
value	O
written	O
to	O
registers	O
.	O
</s>
<s>
Operating	O
System	O
Shadow	O
registers	O
are	O
copied	O
from	O
RAM	B-Architecture
to	O
the	O
hardware	O
registers	O
during	O
the	O
Vertical	O
Blank	O
.	O
</s>
<s>
Name	O
Description	O
Read/Write	O
Hex	O
Addr	O
Dec	O
Addr	O
Shadow	O
Name	O
Shadow	O
Hex	O
Addr	O
Shadow	O
Dec	O
Addr	O
HPOSP0	O
Horizontal	O
Position	O
of	O
Player	O
0	O
Write	O
$D000	O
53248	O
M0PF	O
Missile	O
0	O
to	O
Playfield	O
collisions	O
Read	O
$D000	O
53248	O
HPOSP1	O
Horizontal	O
Position	O
of	O
Player	O
1	O
Write	O
$D001	O
53249	O
M1PF	O
Missile	O
1	O
to	O
Playfield	O
collisions	O
Read	O
$D001	O
53249	O
HPOSP2	O
Horizontal	O
Position	O
of	O
Player	O
2	O
Write	O
$D002	O
53250	O
M2PF	O
Missile	O
2	O
to	O
Playfield	O
collisions	O
Read	O
$D002	O
53250	O
HPOSP3	O
Horizontal	O
Position	O
of	O
Player	O
3	O
Write	O
$D003	O
53251	O
M3PF	O
Missile	O
3	O
to	O
Playfield	O
collisions	O
Read	O
$D003	O
53251	O
HPOSM0	O
Horizontal	O
Position	O
of	O
Missile	O
0	O
Write	O
$D004	O
53252	O
P0PF	O
Player	O
0	O
to	O
Playfield	O
collisions	O
Read	O
$D004	O
53252	O
HPOSM1	O
Horizontal	O
Position	O
of	O
Missile	O
1	O
Write	O
$D005	O
53253	O
P1PF	O
Player	O
1	O
to	O
Playfield	O
collisions	O
Read	O
$D005	O
53253	O
HPOSM2	O
Horizontal	O
Position	O
of	O
Missile	O
2	O
Write	O
$D006	O
53254	O
P2PF	O
Player	O
2	O
to	O
Playfield	O
collisions	O
Read	O
$D006	O
53254	O
HPOSM3	O
Horizontal	O
Position	O
of	O
Missile	O
3	O
Write	O
$D007	O
53255	O
P3PF	O
Player	O
3	O
to	O
Playfield	O
collisions	O
Read	O
$D007	O
53255	O
SIZEP0	O
Size	O
of	O
Player	O
0	O
Write	O
$D008	O
53256	O
M0PL	O
Missile	O
0	O
to	O
Player	O
collisions	O
Read	O
$D008	O
53256	O
SIZEP1	O
Size	O
of	O
Player	O
1	O
Write	O
$D009	O
53257	O
M1PL	O
Missile	O
1	O
to	O
Player	O
collisions	O
Read	O
$D009	O
53257	O
SIZEP2	O
Size	O
of	O
Player	O
2	O
Write	O
$D00A	O
53258	O
M2PL	O
Missile	O
2	O
to	O
Player	O
collisions	O
Read	O
$D00A	O
53258	O
SIZEP3	O
Size	O
of	O
Player	O
3	O
Write	O
$D00B	O
53259	O
M3PL	O
Missile	O
3	O
to	O
Player	O
collisions	O
Read	O
$D00B	O
53259	O
SIZEM	O
Size	O
of	O
all	O
Missiles	O
Write	O
$D00C	O
53260	O
P0PL	O
Player	O
0	O
to	O
Player	O
collisions	O
Read	O
$D00C	O
53260	O
GRAFP0	O
Graphics	O
pattern	O
for	O
Player	O
0	O
Write	O
$D00D	O
53261	O
P1PL	O
Player	O
1	O
to	O
Player	O
collisions	O
Read	O
$D00D	O
53261	O
GRAFP1	O
Graphics	O
pattern	O
for	O
Player	O
1	O
Write	O
$D00E	O
53262	O
P2PL	O
Player	O
2	O
to	O
Player	O
collisions	O
Read	O
$D00E	O
53262	O
GRAFP2	O
Graphics	O
pattern	O
for	O
Player	O
2	O
Write	O
$D00F	O
53263	O
P3PL	O
Player	O
3	O
to	O
Player	O
collisions	O
Read	O
$D00F	O
53263	O
GRAFP3	O
Graphics	O
pattern	O
for	O
Player	O
3	O
Write	O
$D010	O
53264	O
TRIG0	O
Joystick	B-Device
0	O
trigger	O
.	O
</s>
<s>
Read	O
$D010	O
53264	O
STRIG0	O
$0284	O
644	O
GRAFM	O
Graphics	O
pattern	O
for	O
all	O
Missiles	O
Write	O
$D011	O
53265	O
TRIG1	O
Joystick	B-Device
1	O
trigger	O
.	O
</s>
<s>
Write	O
$D012	O
53266	O
PCOLOR0	O
$02C0	O
704	O
TRIG2	O
Joystick	B-Device
2	O
trigger	O
.	O
</s>
<s>
Write	O
$D013	O
53267	O
PCOLOR1	O
$02C1	O
705	O
TRIG3	O
Joystick	B-Device
3	O
trigger	O
.	O
</s>
<s>
Write	O
$D014	O
53268	O
PCOLOR2	O
$02C2	O
706	O
PAL	B-Language
PAL	B-Language
flags	O
.	O
</s>
<s>
Write	O
$D01A	O
53274	O
COLOR4	O
$02C8	O
712	O
PRIOR	O
Priority	O
selection	O
,	O
fifth	O
player	O
,	O
and	O
GTIA	B-General_Concept
modes	O
Write	O
$D01B	O
53275	O
GPRIOR	O
$026F	O
623	O
VDELAY	O
Vertical	O
Delay	O
P/M	O
Graphics	O
Write	O
$D01C	O
53276	O
GRACTL	O
Graphics	O
Control	O
.	O
</s>
<s>
Player/Missile	O
pixels	O
are	O
only	O
rendered	O
within	O
the	O
visible	O
portions	O
of	O
the	O
GTIA	B-General_Concept
's	O
pixel	O
engine	O
.	O
</s>
<s>
Note	O
that	O
in	O
Quad	O
size	O
a	O
single	O
Player/Missile	O
pixel	O
is	O
the	O
same	O
width	O
as	O
an	O
Antic	B-General_Concept
Mode	O
2	O
text	O
character	O
.	O
</s>
<s>
With	O
no	O
other	O
intervention	O
by	O
CPU	O
or	O
ANTIC	B-General_Concept
DMA	O
to	O
update	O
the	O
values	O
the	O
result	O
is	O
vertical	O
stripe	O
patterns	O
the	O
height	O
of	O
the	O
screen	O
including	O
overscan	O
areas	O
.	O
</s>
<s>
CTIA/GTIA	B-General_Concept
has	O
60	O
bits	O
providing	O
automatic	O
detection	O
of	O
collisions	O
when	O
Player	O
,	O
Missile	O
,	O
and	O
Playfield	O
pixels	O
intersect	O
.	O
</s>
<s>
Checking	O
an	O
object	O
's	O
collision	O
bits	O
before	O
the	O
object	O
has	O
been	O
rendered	O
by	O
CTIA/GTIA	B-General_Concept
will	O
show	O
no	O
collision	O
.	O
</s>
<s>
High-resolution	O
,	O
1/2	O
color	O
clock	O
pixel	O
modes	O
(	O
ANTIC	B-General_Concept
Modes	O
2	O
,	O
3	O
,	O
and	O
F	O
)	O
are	O
treated	O
differently	O
.	O
</s>
<s>
GTIA	B-General_Concept
modes	O
9	O
and	O
11	O
do	O
not	O
process	O
playfield	O
collisions	O
.	O
</s>
<s>
All	O
Player/Missile	O
objects	O
 '	O
pixels	O
and	O
all	O
Playfield	O
pixels	O
in	O
the	O
default	O
CTIA/GTIA	B-General_Concept
color	O
interpretation	O
mode	O
use	O
indirection	O
to	O
specify	O
color	O
.	O
</s>
<s>
CTIA/GTIA	B-General_Concept
contain	O
hardware	O
registers	O
that	O
set	O
the	O
values	O
used	O
for	O
colors	O
,	O
and	O
the	O
pixels	O
 '	O
information	O
refer	O
to	O
these	O
registers	O
.	O
</s>
<s>
When	O
GTIA	B-General_Concept
9-color	O
mode	O
is	O
enabled	O
(	O
PRIOR/GPRIOR	O
value	O
$80	O
)	O
this	O
register	O
is	O
used	O
for	O
the	O
border	O
and	O
background	O
(	O
Playfield	O
pixel	O
value	O
0	O
)	O
,	O
rather	O
than	O
COLBK	O
.	O
</s>
<s>
This	O
register	O
is	O
used	O
for	O
the	O
set	O
pixels	O
(	O
value	O
1	O
)	O
in	O
ANTIC	B-General_Concept
text	O
modes	O
2	O
and	O
3	O
,	O
and	O
map	O
mode	O
F	O
.	O
Only	O
the	O
luminance	O
portion	O
is	O
used	O
and	O
is	O
OR	O
'd	O
with	O
the	O
color	O
value	O
of	O
COLPF2	O
.	O
</s>
<s>
This	O
register	O
is	O
used	O
for	O
Playfield	O
background	O
color	O
of	O
ANTIC	B-General_Concept
text	O
modes	O
2	O
and	O
3	O
,	O
and	O
map	O
mode	O
F	O
.	O
That	O
is	O
,	O
where	O
pixel	O
value	O
0	O
is	O
used	O
.	O
</s>
<s>
Inverse	O
video	O
characters	O
(	O
high	O
bit	O
$80	O
set	O
)	O
cause	O
CTIA/GTIA	B-General_Concept
to	O
substitute	O
COLPF3	O
value	O
for	O
COLPF2	O
pixels	O
in	O
the	O
character	O
matrix	O
.	O
</s>
<s>
This	O
register	O
is	O
also	O
available	O
in	O
GTIA	B-General_Concept
's	O
special	O
9	O
color	O
,	O
pixel	O
indirection	O
color	O
mode	O
.	O
</s>
<s>
In	O
ANTIC	B-General_Concept
text	O
modes	O
2	O
and	O
3	O
,	O
and	O
map	O
mode	O
F	O
the	O
background	O
of	O
the	O
playfield	O
area	O
where	O
pixels	O
may	O
be	O
rendered	O
is	O
from	O
COLPF2	O
and	O
the	O
COLBK	O
color	O
appears	O
as	O
a	O
border	O
around	O
the	O
playfield	O
.	O
</s>
<s>
In	O
GTIA	B-General_Concept
color	O
interpretation	O
mode	O
$8	O
(	O
9	O
color	O
indirection	O
)	O
the	O
display	O
background	O
color	O
is	O
provided	O
by	O
color	O
register	O
COLPM0	O
while	O
COLBAK	O
is	O
used	O
for	O
Playfield	O
pixel	O
value	O
$8	O
.	O
</s>
<s>
In	O
GTIA	B-General_Concept
color	O
interpretation	O
mode	O
$C	O
(	O
15	O
colors	O
in	O
one	O
luminance	O
level	O
,	O
plus	O
background	O
)	O
uses	O
COLBK	O
to	O
set	O
the	O
luminance	O
level	O
of	O
all	O
other	O
pixels	O
(	O
pixel	O
value	O
$1	O
through	O
$F	O
)	O
.	O
</s>
<s>
In	O
GTIA	B-General_Concept
color	O
interpretation	O
mode	O
$4	O
(	O
luminance-only	O
mode	O
)	O
the	O
full	O
16	O
bits	O
of	O
luminance	O
values	O
are	O
available	O
for	O
Playfield	O
pixels	O
providing	O
a	O
palette	O
of	O
256	O
colors	O
.	O
</s>
<s>
See	O
ANTIC	B-General_Concept
's	O
graphics	O
modes	O
for	O
more	O
information	O
.	O
</s>
<s>
ANTIC	B-General_Concept
Text	O
modes	O
2	O
and	O
3	O
,	O
and	O
Map	O
mode	O
F	O
:	O
</s>
<s>
ANTIC	B-General_Concept
Text	O
modes	O
2	O
and	O
3	O
,	O
and	O
Map	O
mode	O
F	O
behave	O
differently	O
with	O
Player/Missile	O
graphics	O
from	O
the	O
other	O
modes	O
.	O
</s>
<s>
In	O
summary	O
,	O
the	O
color	O
CTIA/GTIA	B-General_Concept
finally	O
determines	O
to	O
use	O
"	O
behind	O
"	O
the	O
high-res	O
pixel	O
is	O
then	O
used	O
to	O
"	O
tint	O
"	O
the	O
COLPF1	O
foreground	O
glyph/graphics	O
pixels	O
.	O
</s>
<s>
GTIA	B-General_Concept
color	O
interpretation	O
mode	O
$8	O
(	O
9	O
color	O
indirection	O
)	O
uses	O
color	O
register	O
COLPM0	O
for	O
the	O
display	O
background	O
and	O
border	O
color	O
while	O
COLBAK	O
is	O
used	O
for	O
Playfield	O
pixel	O
value	O
$8	O
.	O
</s>
<s>
GTIA	B-General_Concept
color	O
interpretation	O
mode	O
$C	O
(	O
15	O
colors	O
in	O
one	O
luminance	O
level	O
,	O
plus	O
background	O
)	O
uses	O
COLBK	O
to	O
set	O
the	O
luminance	O
level	O
of	O
all	O
other	O
pixels	O
(	O
pixel	O
value	O
$1	O
through	O
$F	O
)	O
.	O
</s>
<s>
Color	O
Registers	O
 '	O
Use	O
per	O
ANTIC	B-General_Concept
Character	O
Modes	O
:	O
</s>
<s>
Color	O
Registers	O
 '	O
Use	O
per	O
ANTIC	B-General_Concept
Map	O
Modes	O
:	O
</s>
<s>
Color	O
Registers	O
 '	O
Use	O
per	O
GTIA	B-General_Concept
Modes	O
(	O
ANTIC	B-General_Concept
F	O
)	O
:	O
</s>
<s>
Player/Missile	O
colors	O
are	O
always	O
available	O
for	O
Player/Missile	O
objects	O
in	O
all	O
modes	O
,	O
though	O
colors	O
may	O
be	O
modified	O
when	O
the	O
special	O
GTIA	B-General_Concept
modes	O
(	O
16	O
shades/16	O
color	O
)	O
are	O
in	O
effect	O
.	O
</s>
<s>
This	O
register	O
controls	O
several	O
CTIA/GTIA	B-General_Concept
color	O
management	O
features	O
:	O
The	O
GTIA	B-General_Concept
Playfield	O
color	O
interpretation	O
mode	O
,	O
Multi-Color	O
Player	O
objects	O
,	O
the	O
Fifth	O
Player	O
,	O
and	O
Player/Missile/Playfield	O
priority	O
.	O
</s>
<s>
CTIA	O
includes	O
only	O
one	O
default	O
color	O
interpretation	O
mode	O
for	O
the	O
ANTIC	B-General_Concept
Playfield	O
data	O
stream	O
.	O
</s>
<s>
That	O
is	O
the	O
basic	O
functionality	O
assumed	O
in	O
the	O
majority	O
of	O
the	O
ANTIC	B-General_Concept
and	O
CTIA/GTIA	B-General_Concept
discussion	O
unless	O
otherwise	O
noted	O
.	O
</s>
<s>
GTIA	B-General_Concept
includes	O
three	O
alternate	O
color	O
interpretations	O
modes	O
for	O
Playfield	O
data	O
.	O
</s>
<s>
These	O
modes	O
work	O
by	O
pairing	O
adjacent	O
color	O
clocks	O
from	O
ANTIC	B-General_Concept
,	O
thus	O
the	O
pixels	O
output	O
by	O
GTIA	B-General_Concept
are	O
always	O
two	O
color	O
clocks	O
wide	O
.	O
</s>
<s>
Although	O
these	O
modes	O
can	O
be	O
engaged	O
while	O
displaying	O
any	O
ANTIC	B-General_Concept
Playfield	O
Mode	O
,	O
the	O
full	O
color	O
palette	O
possible	O
with	O
these	O
GTIA	B-General_Concept
color	O
processing	O
options	O
are	O
only	O
realized	O
in	O
the	O
ANTIC	B-General_Concept
Modes	O
based	O
on	O
color	O
clock	O
pixels	O
(	O
ANTIC	B-General_Concept
modes	O
2	O
,	O
3	O
,	O
F	O
.	O
)	O
These	O
GTIA	B-General_Concept
options	O
are	O
most	O
often	O
used	O
with	O
a	O
Mode	O
F	O
display	O
.	O
</s>
<s>
The	O
special	O
GTIA	B-General_Concept
color	O
processing	O
modes	O
also	O
alter	O
the	O
display	O
or	O
behavior	O
of	O
Player/Missile	O
graphics	O
in	O
various	O
ways	O
.	O
</s>
<s>
The	O
color	O
interpretation	O
control	O
is	O
a	O
global	O
function	O
of	O
GTIA	B-General_Concept
affecting	O
the	O
entire	O
screen	O
.	O
</s>
<s>
GTIA	B-General_Concept
is	O
not	O
inherently	O
capable	O
of	O
mixing	O
on	O
one	O
display	O
the	O
various	O
GTIA	B-General_Concept
color	O
interpretation	O
modes	O
and	O
the	O
default	O
CTIA	O
mode	O
needed	O
for	O
most	O
ANTIC	B-General_Concept
Playfields	O
.	O
</s>
<s>
GTIA	B-General_Concept
Mode	O
Bits	O
 [ 7:6 ] 	O
Feature	O
Description	O
0	O
0	O
=	O
$00	O
Default	O
Same	O
as	O
CTIA	O
.	O
</s>
<s>
0	O
1	O
=	O
$40	O
GTIA/16	O
Shades	O
16	O
shades	O
of	O
background	O
color	O
(	O
COLBK	O
)	O
1	O
0	O
=	O
$80	O
GTIA/9	O
color	O
All	O
nine	O
Playfield	O
and	O
Player/Missile	O
color	O
registers	O
are	O
available	O
on	O
the	O
Playfield	O
.	O
</s>
<s>
The	O
background	O
is	O
COLPM0	O
1	O
1	O
=	O
$C0	O
GTIA/16	O
Color	O
15	O
colors	O
at	O
one	O
luminance	O
level	O
set	O
by	O
the	O
background	O
register	O
(	O
COLBK	O
)	O
,	O
plus	O
the	O
background	O
.	O
</s>
<s>
Unlike	O
the	O
other	O
two	O
special	O
GTIA	B-General_Concept
modes	O
,	O
this	O
mode	O
is	O
entirely	O
driven	O
by	O
color	O
indirection	O
.	O
</s>
<s>
The	O
pixels	O
are	O
delayed	O
by	O
one	O
color	O
clock	O
(	O
half	O
a	O
GTIA	B-General_Concept
mode	O
pixel	O
)	O
when	O
output	O
.	O
</s>
<s>
For	O
an	O
example	O
,	O
page	O
flipping	O
rapidly	O
between	O
this	O
mode	O
and	O
a	O
different	O
GTIA	B-General_Concept
mode	O
produces	O
a	O
display	O
with	O
apparent	O
higher	O
resolution	O
and	O
greater	O
number	O
of	O
colors	O
.	O
</s>
<s>
This	O
is	O
implemented	O
by	O
eliminating	O
priority	O
processing	O
between	O
pairs	O
of	O
Player/Missile	O
objects	O
resulting	O
in	O
CTIA/GTIA	B-General_Concept
performing	O
a	O
bitwise	O
OR	O
of	O
the	O
two	O
colored	O
pixels	O
to	O
output	O
a	O
new	O
color	O
.	O
</s>
<s>
The	O
color	O
processing	O
change	O
also	O
causes	O
some	O
exceptions	O
for	O
the	O
Missiles	O
 '	O
display	O
in	O
GTIA	B-General_Concept
's	O
alternative	O
color	O
modes	O
:	O
</s>
<s>
GTIA	B-General_Concept
16	O
Shades	O
mode	O
:	O
Where	O
Missile	O
pixels	O
overlap	O
the	O
Playfield	O
the	O
pixels	O
inherit	O
the	O
Playfield	O
pixels	O
 '	O
Luminance	O
value	O
.	O
</s>
<s>
GTIA	B-General_Concept
16	O
Colors	O
mode	O
:	O
Where	O
Missile	O
pixels	O
overlap	O
the	O
Playfield	O
the	O
pixels	O
inherit	O
the	O
Playfield	O
pixels	O
 '	O
Color	O
value	O
.	O
</s>
<s>
The	O
chart	O
is	O
accurate	O
for	O
ANTIC	B-General_Concept
Playfield	O
Character	O
and	O
Map	O
modes	O
using	O
the	O
default	O
(	O
CTIA	O
)	O
color	O
interpretation	O
mode	O
.	O
</s>
<s>
GTIA	B-General_Concept
color	O
interpretation	O
modes	O
,	O
and	O
the	O
ANTIC	B-General_Concept
modes	O
based	O
on	O
high-resolution	O
,	O
color	O
clock	O
pixels	O
behave	O
differently	O
(	O
noted	O
later	O
)	O
.	O
</s>
<s>
If	O
multiple	O
bits	O
are	O
set	O
,	O
then	O
where	O
there	O
is	O
a	O
conflict	O
CTIA/GTIA	B-General_Concept
outputs	O
a	O
black	O
pixel	O
—	O
Note	O
that	O
black	O
means	O
actual	O
black	O
,	O
not	O
simply	O
the	O
background	O
color	O
,	O
COLBK	O
.	O
</s>
<s>
When	O
all	O
color	O
merging	O
possibilities	O
are	O
considered	O
,	O
the	O
CTIA/GTIA	B-General_Concept
hardware	O
can	O
output	O
23	O
colors	O
per	O
scan	O
line	O
.	O
</s>
<s>
The	O
priority	O
result	O
differ	O
for	O
the	O
Character	O
and	O
Map	O
modes	O
using	O
high-resolution	O
,	O
color	O
clock	O
pixels	O
—	O
ANTIC	B-General_Concept
modes	O
2	O
,	O
3	O
,	O
and	O
F	O
.	O
These	O
priority	O
handling	O
differences	O
can	O
be	O
exploited	O
to	O
produce	O
color	O
text	O
or	O
graphics	O
in	O
these	O
modes	O
that	O
are	O
traditionally	O
thought	O
of	O
as	O
"	O
monochrome	O
"	O
.	O
</s>
<s>
In	O
these	O
ANTIC	B-General_Concept
modes	O
COLPF2	O
is	O
output	O
as	O
the	O
"	O
background	O
"	O
of	O
the	O
Playfield	O
and	O
COLBK	O
is	O
output	O
as	O
the	O
border	O
around	O
the	O
Playfield	O
.	O
</s>
<s>
In	O
effect	O
,	O
the	O
color	O
value	O
CTIA/GTIA	B-General_Concept
finally	O
uses	O
for	O
the	O
"	O
background	O
"	O
color	O
"	O
tints	O
"	O
the	O
COLPF1	O
foreground	O
glyph/graphics	O
pixels	O
.	O
</s>
<s>
This	O
register	O
is	O
used	O
to	O
provide	O
single	O
scan	O
line	O
movement	O
when	O
Double	O
Line	O
Player/Missile	O
resolution	O
is	O
enabled	O
in	O
ANTIC	B-General_Concept
's	O
DMACTL	O
register	O
.	O
</s>
<s>
This	O
works	O
by	O
masking	O
ANTIC	B-General_Concept
DMA	O
updates	O
to	O
the	O
GRAF*	O
registers	O
on	O
even	O
scan	O
lines	O
,	O
causing	O
the	O
graphics	O
pattern	O
to	O
shift	O
down	O
one	O
scan	O
line	O
.	O
</s>
<s>
Since	O
Single	O
Line	O
resolution	O
requires	O
ANTIC	B-General_Concept
DMA	O
updates	O
on	O
each	O
scan	O
line	O
and	O
VDELAY	O
masks	O
the	O
updates	O
on	O
even	O
scan	O
lines	O
,	O
then	O
this	O
bit	O
reduces	O
Single	O
line	O
Player/Missile	O
resolution	O
to	O
Double	O
line	O
.	O
</s>
<s>
GRACTL	O
controls	O
CTIA/GTIA	B-General_Concept
'	O
s	O
receipt	O
of	O
Player/Missile	O
DMA	O
data	O
from	O
ANTIC	B-General_Concept
and	O
toggles	O
the	O
mode	O
of	O
Joystick	B-Device
trigger	O
input	O
.	O
</s>
<s>
Receipt	O
of	O
Player/Missile	O
DMA	O
data	O
requires	O
CTIA/GTIA	B-General_Concept
be	O
configured	O
to	O
receive	O
the	O
data	O
.	O
</s>
<s>
This	O
is	O
done	O
with	O
a	O
pair	O
of	O
bits	O
in	O
GRACTL	O
that	O
match	O
a	O
pair	O
of	O
bits	O
in	O
ANTIC	B-General_Concept
's	O
DMACTL	O
register	O
that	O
direct	O
ANTIC	B-General_Concept
to	O
send	O
Player	O
data	O
and	O
Missile	O
data	O
.	O
</s>
<s>
These	O
bits	O
must	O
be	O
set	O
for	O
GTIA	B-General_Concept
to	O
receive	O
Player/Missile	O
data	O
from	O
ANTIC	B-General_Concept
via	O
DMA	O
.	O
</s>
<s>
The	O
joystick	B-Device
trigger	O
registers	O
report	O
the	O
pressed/not	O
pressed	O
state	O
in	O
real-time	O
.	O
</s>
<s>
If	O
a	O
program	O
's	O
input	O
polling	O
may	O
not	O
be	O
frequent	O
enough	O
to	O
catch	O
momentary	O
joystick	B-Device
button	O
presses	O
,	O
then	O
the	O
triggers	O
can	O
be	O
set	O
to	O
lock	O
in	O
the	O
closed/pressed	O
state	O
and	O
remain	O
in	O
that	O
state	O
even	O
after	O
the	O
button	O
is	O
released	O
.	O
</s>
<s>
Joystick	B-Device
1	O
trigger	O
.	O
</s>
<s>
Joystick	B-Device
2	O
trigger	O
.	O
</s>
<s>
Bit	O
0	O
reports	O
the	O
state	O
of	O
the	O
joystick	B-Device
trigger	O
.	O
</s>
<s>
PAL	B-Language
flags	O
.	O
</s>
<s>
When	O
the	O
bits	O
are	O
zero	O
the	O
system	O
is	O
operating	O
in	O
PAL	B-Language
mode	O
.	O
</s>
<s>
A	O
hardware	O
"	O
sprite	O
"	O
system	O
is	O
handled	O
by	O
CTIA/GTIA	B-General_Concept
.	O
</s>
<s>
The	O
official	O
ATARI	O
name	O
for	O
the	O
sprite	O
system	O
is	O
"	O
Player/Missile	O
Graphics	O
"	O
,	O
since	O
it	O
was	O
designed	O
to	O
reduce	O
the	O
need	O
to	O
manipulate	O
display	B-Algorithm
memory	I-Algorithm
for	O
fast-moving	O
objects	O
,	O
such	O
as	O
the	O
"	O
player	O
"	O
and	O
his	O
weapons	O
,	O
"	O
missiles	O
"	O
,	O
in	O
a	O
shoot	O
'	O
em	O
up	O
game	O
.	O
</s>
<s>
CTIA/GTIA	B-General_Concept
combines	O
the	O
Player/Missile	O
objects	O
 '	O
pixels	O
with	O
the	O
Playfield	O
pixels	O
according	O
to	O
their	O
priority	O
.	O
</s>
<s>
The	O
Player/Missile	O
implementation	O
by	O
CTIA/GTIA	B-General_Concept
is	O
similar	O
to	O
the	O
TIA	B-General_Concept
's	O
.	O
</s>
<s>
That	O
is	O
,	O
the	O
default	O
implementation	O
of	O
Player/Missile	O
graphics	O
by	O
CTIA/GTIA	B-General_Concept
is	O
a	O
stripe	O
down	O
the	O
screen	O
.	O
</s>
<s>
CTIA/GTIA	B-General_Concept
supports	O
several	O
options	O
controlling	O
Player/Missile	O
color	O
.	O
</s>
<s>
The	O
ANTIC	B-General_Concept
chip	O
includes	O
a	O
feature	O
to	O
perform	O
DMA	O
to	O
automatically	O
feed	O
new	O
pixel	O
patterns	O
to	O
CTIA/GTIA	B-General_Concept
as	O
the	O
display	O
is	O
generated	O
.	O
</s>
<s>
Moving	O
the	O
Player/Missile	O
objects	O
horizontally	O
is	O
as	O
simple	O
as	O
changing	O
a	O
register	O
in	O
the	O
CTIA/GTIA	B-General_Concept
(	O
in	O
Atari	O
BASIC	O
,	O
a	O
single	O
POKE	O
statement	O
moves	O
a	O
player	O
or	O
missile	O
horizontally	O
)	O
.	O
</s>
<s>
The	O
GTIA	B-General_Concept
chip	O
is	O
backward	B-General_Concept
compatible	I-General_Concept
with	O
the	O
CTIA	O
,	O
and	O
adds	O
3	O
color	O
interpretations	O
for	O
the	O
14	O
"	O
normal	O
"	O
ANTIC	B-General_Concept
Playfield	O
graphics	O
modes	O
.	O
</s>
<s>
The	O
three	O
,	O
new	O
color	O
interpretations	O
in	O
GTIA	B-General_Concept
provide	O
a	O
theoretical	O
total	O
of	O
56	O
graphics	O
modes	O
(	O
14	O
ANTIC	B-General_Concept
modes	O
multiplied	O
by	O
four	O
possible	O
color	O
interpretations	O
)	O
.	O
</s>
<s>
However	O
,	O
only	O
the	O
graphics	O
modes	O
based	O
on	O
high-resolution	O
,	O
color	O
clock	O
pixels	O
(	O
that	O
is	O
,	O
Antic	B-General_Concept
text	O
modes	O
2	O
,	O
3	O
,	O
and	O
graphics	O
mode	O
F	O
)	O
are	O
capable	O
of	O
fully	O
expressing	O
the	O
color	O
palettes	O
of	O
these	O
3	O
new	O
color	O
interpretations	O
.	O
</s>
<s>
GTIA	B-General_Concept
color	O
interpretation	O
mode	O
16	O
shades	O
of	O
a	O
single	O
hue	O
(	O
set	O
by	O
the	O
background	O
color	O
,	O
COLBK	O
)	O
from	O
the	O
16	O
possible	O
hues	O
in	O
the	O
Atari	O
palette	O
.	O
</s>
<s>
GTIA	B-General_Concept
color	O
interpretation	O
mode	O
This	O
mode	O
allows	O
9	O
colors	O
of	O
indirection	O
per	O
horizontal	O
line	O
in	O
any	O
hue	O
and	O
luminance	O
from	O
the	O
entire	O
Atari	O
palette	O
of	O
128	O
colors	O
.	O
</s>
<s>
GTIA	B-General_Concept
color	O
interpretation	O
mode	O
15	O
hues	O
in	O
a	O
single	O
shade/luminance	O
value	O
,	O
plus	O
the	O
background	O
.	O
</s>
<s>
The	O
Antic	B-General_Concept
2	O
and	O
3	O
text	O
modes	O
are	O
capable	O
of	O
displaying	O
the	O
same	O
color	O
ranges	O
as	O
mode	O
F	O
graphics	O
when	O
using	O
the	O
GTIA	B-General_Concept
's	O
alternate	O
color	O
interpretations	O
.	O
</s>
<s>
Effective	O
use	O
of	O
the	O
GTIA	B-General_Concept
color	O
interpretation	O
feature	O
with	O
text	O
modes	O
requires	O
a	O
carefully	O
constructed	O
character	O
set	O
treating	O
characters	O
as	O
pixels	O
.	O
</s>
<s>
This	O
method	O
allows	O
display	O
of	O
an	O
apparent	O
GTIA	B-General_Concept
"	O
high	O
resolution	O
"	O
graphics	O
mode	O
that	O
would	O
ordinarily	O
occupy	O
8K	O
of	O
RAM	B-Architecture
to	O
instead	O
use	O
only	O
about	O
2K	O
(	O
1K	O
for	O
the	O
character	O
set	O
,	O
and	O
1K	O
for	O
the	O
screen	O
RAM	B-Architecture
and	O
display	O
list	O
.	O
)	O
</s>
<s>
The	O
GTIA	B-General_Concept
also	O
fixed	O
an	O
error	O
in	O
CTIA	O
that	O
caused	O
graphics	O
to	O
be	O
misaligned	O
by	O
"	O
half	O
a	O
color	O
clock	O
"	O
.	O
</s>
<s>
Atari	O
owners	O
can	O
determine	O
if	O
their	O
machine	O
is	O
equipped	O
with	O
the	O
CTIA	O
or	O
GTIA	B-General_Concept
by	O
executing	O
the	O
BASIC	O
command	O
POKE	O
623	O
,	O
64	O
.	O
</s>
<s>
If	O
the	O
screen	O
blackens	O
after	O
execution	O
,	O
the	O
machine	O
is	O
equipped	O
with	O
the	O
new	O
GTIA	B-General_Concept
chip	O
.	O
</s>
<s>
Many	O
if	O
not	O
all	O
have	O
a	O
buggy	O
PAL	B-Language
GTIA	B-General_Concept
chip	O
.	O
</s>
<s>
Also	O
,	O
there	O
have	O
been	O
attempts	O
to	O
fix	O
faulty	O
GTIA	B-General_Concept
chips	O
with	O
some	O
.	O
</s>
