Set Raster Y-Offset; Set Compression Mode - Brother HL-Series Technical Reference Manual

Hide thumbs Also See for HL-Series:
Table of Contents

Advertisement

Revision C 16/01/96

Set raster y-offset

Esc*b#Y
• This command sets the offset (number of blank rows to be skipped) for the raster image to be printed.
• # is the number of rows that are left blank at the top of the image.
• # must be in the range 0-32767
• This command is only effective in raster graphics mode, that is, after a Start Raster Graphics mode command.

Set compression mode

Esc*b#M
Identifies the method of compression used to encode the raster image that is to be sent to the printer.
# is 0, 1, 2, 3, 5, 9, 1152 or 1024.
# = 0 signifies no compression is to be used.
# = 1 indicates that run-length encoding is to be used. The raster data bytes are transmitted in pairs. The
second byte of each pair specifies the raster output: the first byte specifies the number of times the second byte
is successively repeated. A value of 0 for the first byte indicates a single occurrence of the second byte, a value
of 1 indicates two consecutive occurrences of the second byte and so on.
# = 2 indicates that TIFF (tagged image file format) encoding is to be used. In this format the data is
transmitted in groups of bytes. The first byte of each group is a control byte and defines how the subsequent
data byte or bytes should be interpreted, and how many data bytes there are before the next control byte. If the
two's complement value of the control byte is in the range –1 to –127, the following byte is a repeated data
byte. The number of successive occurrences of the data byte is given by the absolute value of the control byte
plus one - that is if the control byte is -6, the following data byte is repeated 7 times. If the value of the control
byte is in the range 0-127 the bytes which follow are unencoded raster data. The number of data bytes is given
by the absolute value of the control byte plus one - that is if the control byte is 9, the following ten bytes are
unencoded data. If a control byte has the two's complement value –128 it is ignored and the next byte is treated
as a control byte.
# = 3 indicates that delta row compression is to be used. In this method byte sequences identify how each raster
row differs from the last row that was transmitted. The first byte identifies a number of consecutive bytes (the
value of the senior 3 bits plus 1) to be changed and the position in the line at which to start substituting the
replacement bytes (the junior 5 bits plus 1). Hence, if the command byte has a 3 in the top three bits and 10 in
the bottom five bits, the 11th, 12th, 13th and 14th bytes of the last row will be replaced by the four data bytes
that follow.
If the junior 5 bits are all 1, the next byte is treated as a further offset value and its value is added to 32 to
calculate the offset. If this byte in turn is all ones the next byte is also treated as a continuation byte and its
value is added to the offset, and so on until a byte whose value is not 255 is encountered.
This combination of command bytes and replacement bytes is used to specify all the differences between the
last raster row sent (the seed row) and the new row to be transmitted. When the new row has been sent it
becomes the new seed row.
(27)(42)(98)#(89)
(27)(42)(98)#(77)
Chapter 2 "PCL" - 79
<1Bh><2Ah><62h>#<59h>
<1Bh><2Ah><62h>#<4Dh>

Advertisement

Table of Contents
loading

Table of Contents