HP (Hewlett-Packard) PCL Printer User Manual


 
6-20 Raster Graphics EN
Set Compression Method Command
The Set Compression Method command allows you to encode the
data in a given raster transfer, either by plane or by row. These
methods achieve data compression by exploiting byte-to-byte
redundancies, either within a row or between rows, without regard to
the pixel encoding mode of the data. While these methods reduce the
amount of data transferred from the host to the printer, they do not
reduce the memory requirements within the printer.
While PCL 5 compression methods are based on redundancies at the
byte level, the pixel encoding mode must be considered when
choosing a compression method. The direct by pixel mode transfers
the three bytes which make up a pixel, one after the other. Therefore,
compression formats that depend upon reducing redundancy within a
row will not do well, since the pixel to pixel redundancy is disguised by
the format. This is because, while two adjacent pixels have a fairly
high probability of being identical, the probability that the components
of a pixel are identical is very small. For example, consider a raster
image whose background is all one color. While there are a large
number of pixels that are identical, the only time the bytes within the
pixel will be identical are if the color is a gray somewhere between
white and black: such as (0, 0, 0), (128, 128, 128), (255, 255, 255). If
the pixel represents a non-gray color, the bytes within the pixel will not
be identical. Therefore, the only successful compression mode that
exploits redundancy between the rows is delta row compression.
Since the probability that a pixel is the same in the horizontal direction
is usually equivalent to the probability that it is the same in the vertical
direction, the bytes within a pixel will be redundant and therefore
compressible from row to row.
The remaining pixel encoding modes: index by plane, index by pixel,
and direct by plane, can be redundant within a row and are, therefore,
compressed well by compression methods such as run-length
encoding, and TIFF rev 4.0.