Previous Next


                                             355
    SECTION 4.9                                                            Form XObjects



    Example 4.30

       q                                         % Save graphics state
       17 0 0 17 298 388 cm                      % Scale and translate coordinate space
       BI                                        % Begin inline image object
           /W 17                                 % Width in samples
           /H 17                                 % Height in samples
           /CS /RGB                              % Color space
           /BPC 8                                % Bits per component
           /F [ /A85 /LZW ]                      % Filters
       ID                                        % Begin image data
       J1/gKA>.]AN&J?]-<HW]aRVcg*bb.\eKAdVV%/PcZ
       … Omitted data …
       R.s(4KE3&d&7hb*7[%Ct2HCqC~>
       EI                                        % End inline image object
       Q                                         % Restore graphics state


4.9 Form XObjects

    A form XObject is a PDF content stream that is a self-contained description of any
    sequence of graphics objects (including path objects, text objects, and sampled
    images). A form XObject may be painted multiple times—either on several pages
    or at several locations on the same page—and produces the same results each
    time, subject only to the graphics state at the time it is invoked. Not only is this
    shared definition economical to represent in the PDF file, but under suitable cir-
    cumstances the PDF consumer application can optimize execution by caching the
    results of rendering the form XObject for repeated reuse.

    Note: The term form also refers to a completely different kind of object, an inter-
    active form (sometimes called an AcroForm), discussed in Section 8.6, “Interactive
    Forms.” Whereas the form XObjects described in this section correspond to the no-
    tion of forms in the PostScript language, interactive forms are the PDF equivalent of
    the familiar paper instrument. Any unqualified use of the word form is understood
    to refer to an interactive form; the type of form described here is always referred to
    explicitly as a form XObject.

Previous Next