GraphicsDrawImage Method (Image, Rectangle, Single, Single, Single, Single, GraphicsUnit)

Draws the specified portion of the specified Image at the specified location and with the specified size.

Namespace:  System.Drawing
Assembly:  Aspose.Drawing (in Aspose.Drawing.dll) Version: 20.9.0.0 (20.9.0)
Syntax
C#
public void DrawImage(
	Image image,
	Rectangle destRect,
	float srcX,
	float srcY,
	float srcWidth,
	float srcHeight,
	GraphicsUnit srcUnit
)

Parameters

image
Type: System.DrawingImage
Image to draw.
destRect
Type: System.DrawingRectangle
Rectangle structure that specifies the location and size of the drawn image. The image is scaled to fit the rectangle.
srcX
Type: SystemSingle
The x-coordinate of the upper-left corner of the portion of the source image to draw.
srcY
Type: SystemSingle
The y-coordinate of the upper-left corner of the portion of the source image to draw.
srcWidth
Type: SystemSingle
Width of the portion of the source image to draw.
srcHeight
Type: SystemSingle
Height of the portion of the source image to draw
srcUnit
Type: System.DrawingGraphicsUnit
Member of the GraphicsUnit enumeration that specifies the units of measure used to determine the source rectangle.
See Also