MetafileExtensionsToBitmap Method

KGy SOFT Drawing Libraries Help
Creates a Bitmap of a Metafile instance provided in the metafile parameter.

Namespace:  KGySoft.Drawing
Assembly:  KGySoft.Drawing (in KGySoft.Drawing.dll) Version: 5.1.0

public static Bitmap ToBitmap(
	this Metafile metafile,
	Size requestedSize,
	bool antiAliased = false


Type: System.Drawing.ImagingMetafile
The Metafile to convert.
Type: System.DrawingSize
The requested size of the result Bitmap.
antiAliased (Optional)
Type: SystemBoolean
 to create an anti-aliased result; otherwise, .
Default value: .

Return Value

Type: Bitmap
A Bitmap instance of the requested size.

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type Metafile. When you use instance method syntax to call this method, omit the first parameter. For more information, see Extension Methods (Visual Basic) or Extension Methods (C# Programming Guide).
See Also