EasyManua.ls Logo

Xerox Alto I - Page 30

Xerox Alto I
82 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
Alto
Hardware Manual
Section
3:
Emulator
24
BLOCK
OPERATIONS
The basic block operations operate by storing some bits into a "destination block."
The
source
of
these bits varies; often
it
is another block, the "source block." There are various functions
that
BITBLT
can perform.
The
FUNCTION
word
of
the
BBTabie
contains a number
of
fields:
FUNCTION[O-9]
FUNCTION[lO]
FUNCTION[ll]
FUNCTION[12-13]
FUNCTION[14-15]
Must be zero
Source block is in the alternate
bank
Destination block is in
the
alternate
bank
SourceType
Operation
The
operation
field specifies the operation to
be
performed
on
the
source
and
destination blocks:
Operation Name Action
0
Replace Destination Block
+-
Source
1 Paint Destination
Block
+-
Source
OR
Destination
2 Invert Destination Block
+-
Source
XOR
Destination
3
Erase Destination
Block
+-
(NOT
Source)
AND
Destination
The SourceType specifies how the
Source
as
used in the above 4 operations is to
be
computed.
The
encodings are:
SourceType Meaning
o
1
2
3
Source is a block
of
a bit map
Source is the complement
of
a block
of
'a
bit
map
Source is the logical "and"
of
a source block
and
the
"gray block" (see
below).
Source is the "gray block.".
The
"gray block"
is
conceptually a block
of
infinite extent in which a pattern
of
dots is repeated.
The
pattern is specified by four words
(GrayO
through Gray3). These give
the
patterns to write
into the destination. block where called for, one gray word
per
scan line.
The
words will align
with destination block word boundaries,
but
BITBLT
will use GrayO through Gray3 in the order
in
which
BITBLT
processes scanlines (either top to bottom
(DTY(STY)
or
bottom to top (DTY>
STY».
The
most common use
of
these gray values is
to
generate a
uniform
pattern. While the
BITBLT
instruction takes care
of
going through these values appropriately, the table must
be
phased
properly to eliminate
seams.
Specifically,
if
ABC
D are the desired 16-bit word-aligned values
of
gray for scan-lines 0 1 2 3 (mod 4), then two adjustments must
be
made:
Let
Q =
DTY
+
l.
If
DTY
(
STY,
then exchange
Band
D
and
let Q =
-(DTY
+
DR
+ 2).
Rotate the pattern left
(Le.,
A+-
B,
B
+-
C,
etc) a total
of
(Q
AND
3) times.
Set
GrayO+-A,
Grayl+-B, Gray2+-c, Gray3+-D
When the source
is
a block
of
bit map, the width and height parameters
of
the block are
not
needed: the width and height.
of
the destination block are· also
used
as the width
and
height
of
the source block.
It
is permissible for the source
and
destination blocks to overlap, such
as
when
sliding
an
existing block around within a bit map;
BITBLT
will
move
words
in
the order required
for the correct results. However,
if
the source
and
destination blocks
do
overlap, they
must
belong to the same
bit
map
(Le.,
DBCA=SBCA
and
DBMR=SBMR).

Related product manuals