Herd Software Development
DaVinci Graphics Library
The Enhanced MetaFile (EMF) format is an extension of the Windows metafiles format developed for use with 32 bit Windows applications. It is only available to native 32 bit applications.
Supplementary specifications for metafiles saved as enhanced metafiles are stored in the ENHMETAHEADER structure at the beginning of the metafile. Applications can retrieve this information using the GetEnhMetaFileHeader function. The metric size of the metafile, an important piece of information, is stored in this header in addition to a file description in 0.01 millimeter units.
Enhanced metafiles store device context coordinates relative to a reference DC (device context). The ENHMETAHEADER structure contains the resolution of this reference DC in the szlDevice and szlMillimeters fields and specifies the required number of pixels for display on the output DC for use by PlayEnhMetaFile. In many cases, this information makes it unnecessary to create a virtual coordinate system by calling SetWindowExtEx.
If an application activates the transformation of coordinates known from Windows 3.1 with SetWindowExtEx, the coordinates of the points are stored in the enhanced metafile according to the transformation of coordinates.