
Epson Research and Development
Page 91
Vancouver Design Center
Programming Notes and Examples
S1D13A05
Issue Date: 2002/08/21
X40A-G-003-04
4. Program the BitBLT Operation Register to select the Transparent Move BitBLT in
Positive Direction. REG[8008h] bits 3-0 are set to 05h.
5. Program the BitBLT Background Color Register to select blue as the transparent col-
or. REG[8020h] is set to 001Fh (Full intensity blue in 16 bpp is 001Fh).
6. Program the BitBLT Color Format Register to select 16 bpp operations. REG[8000h]
bit 18 is set to 1.
7. Program the BitBLT Memory Offset Register to the ScreenStride in WORDS.
BltMemoryOffset
= ScreenStride
÷ 2
= 320
= 140h
REG[8014h] is set to 0140h.
8. Program the BitBLT Destination/Source Linear Select bits for a rectangular BitBLT
(BitBLT Destination Linear Select = 0, BitBLT Source Linear Select = 0).
Start the BitBLT operation. REG[8000h] bit 0 is set to 1.
Note
The order of register setup is irrelevant as long as all relevant registers are programmed
before the BitBLT is initiated.
9.2.9 Pattern Fill BitBLT with ROP
The Pattern Fill BitBLT with ROP fills a specified area of display memory with a pattern.
The pattern is repeated until the fill area is completely filled. The fill pattern is limited to
an eight by eight pixel array and must be loaded to off-screen video memory before starting
the BitBLT. The pattern can be logically combined with the destination using any of the 16
ROP codes, but typically the copy pattern ROP is used (ROP code 0Ch).
A pattern is defined to be an array of 8x8 pixels and the pattern data must be stored in
consecutive bytes of display memory (64 consecutive bytes for 8 bpp color depths and 128
bytes for 16 bpp color depths). For 8 bpp color depths the pattern must begin on a 64 byte
boundary, for 16 bpp color depths the pattern must begin on a 128 byte boundary.
This operation is self completing. Once the parameters have been entered and the BitBLT
started the BitBLT engine will fill all of the specified memory with the pattern.
To fill an area using the pattern BitBLT, the BitBLT engine requires the location of the
pattern, the destination rectangle position and size, and the ROP code. The BitBLT engine
also needs to know which pixel from the pattern is the first pixel in the destination rectangle
(the pattern start phase). This allows seamless redrawing of any part of the screen using the
pattern fill.