Graphics::EnumerateMetafile(constMetafile*,constRectF&,constRectF&,Unit,EnumerateMetafileProc,VOID*,constImageAttributes*) method (gdiplusgraphics.h)
The Graphics::EnumerateMetafile method calls an application-defined callback function for each record in a specified metafile. You can use this method to display a metafile by calling PlayRecord in the callback function.
Syntax
Status EnumerateMetafile(
[in] const Metafile *metafile,
[in, ref] const RectF & destRect,
[in, ref] const RectF & srcRect,
[in] Unit srcUnit,
[in] EnumerateMetafileProc callback,
[in] VOID *callbackData,
[in] const ImageAttributes *imageAttributes
);
Parameters
[in] metafile
Type: const Metafile*
Pointer to a metafile to be enumerated.
[in, ref] destRect
Type: const RectF
Reference to a RectF object that specifies the rectangle in which the metafile is displayed.
[in, ref] srcRect
Type: const RectF
Reference to a RectF object that specifies the portion of the metafile that is displayed.
[in] srcUnit
Type: Unit
Element of the Unit enumeration that specifies the unit of measure for the source rectangle.
[in] callback
Type: EnumerateMetafileProc
Pointer to an application-defined callback function. The prototype for the callback function is given in Gdiplustypes.h.
[in] callbackData
Type: VOID*
Optional. Pointer to a block of data that is passed to the callback function. The default value is NULL.
[in] imageAttributes
Type: ImageAttributes*
Optional. Pointer to an ImageAttributes object that specifies color adjustments for the displayed metafile. The default value is NULL.
Return value
Type: Status
If the method succeeds, it returns Ok, which is an element of the Status enumeration.
If the method fails, it returns one of the other elements of the Status enumeration.
Requirements
Requirement | Value |
---|---|
Minimum supported client | Windows XP, Windows 2000 Professional [desktop apps only] |
Minimum supported server | Windows 2000 Server [desktop apps only] |
Target Platform | Windows |
Header | gdiplusgraphics.h (include Gdiplus.h) |
Library | Gdiplus.lib |
DLL | Gdiplus.dll |