SECTION 3.3
81
Filters
The JBIG2 compression method can also be used for encoding multiple images
into a single JBIG2 bit stream. Typically, these images are scanned pages of a
multiple-page document. Since a single table of symbol bitmaps is used to match
symbols across multiple pages, this type of encoding can result in higher
compression ratios than if each of the pages had been individually encoded using
JBIG2.
In general, an image may be specified in PDF as either an
image XObject
or an
inline image
(as described in Section 4.8, “Images”); however, the
JBIG2Decode
filter can be applied only to image XObjects.
This filter addresses both single-page and multiple-page JBIG2 bit streams by
representing each JBIG2 page as a PDF image, as follows:
•
The filter uses the embedded file organization of JBIG2. (The details of this and
the other types of file organization are provided in an annex of the ISO specifi-
cation.) The optional 2-byte combination (marker) mentioned in the specifica-
tion is not used in PDF. JBIG2 bit streams in random-access organization
should be converted to the embedded file organization. Bit streams in sequen-
tial organization need no reorganization, except for the mappings described
below.
•
The JBIG2 file header, end-of-page segments, and end-of-file segment are not
used in PDF. These should be removed before the PDF objects described below
are created.
•
The image XObject to which the
JBIG2Decode
filter is applied contains all seg-
ments that are associated with the JBIG2 page represented by that image; that
is, all segments whose segment page association field contains the page number
of the JBIG2 page represented by the image. In the image XObject, however, the
segment’s page number should always be 1; that is, when each such segment is
written to the XObject, the value of its segment page association field should be
set to 1.
•
If the bit stream contains global segments (segments whose segment page asso-
ciation field contains 0), these segments must be placed in a separate PDF
stream, and the filter parameter listed in Table 3.10 should refer to that stream.
The stream can be shared by multiple image XObjects whose JBIG2 encodings
use the same global segments.