1.3.1 Metafile Structure

An EMFSPOOL metafile begins with a header record, which includes the metafile version, its size, the name of the document, and identification of an output device. A metafile is "played back" when its records are parsed and processed, sends the print job to its next destination

EMFSPOOL records contain graphics commands, which specify drawing operations, graphics objects, and properties that define how to render the document, including:

  • The overall structure of the document.

  • The format and content of individual pages.

  • Print device settings, such as paper size.

  • Embedded fonts.

  • Image bitmaps.

  • Injected PostScript commands.

High-level structure of an EMFSPOOL file

Figure 1: High-level structure of an EMFSPOOL file

This figure shows the following about EMFSPOOL files:

  • A header record is always present, specified in section 2.2.2.

  • A page content record actually contains an entire EMF metafile, as specified in [MS-EMF].

  • A font definition can be embedded in an EMF EMR_COMMENT_EMFSPOOL record, which is embedded in an EMF metafile, which is embedded in a page content record. For more information, see [MS-EMF] section 2.3.3.3.

  • No end-of-file record is defined.