System.Drawing.Graphics.DrawImage Method

Draws the specified portion of the specified System.Drawing.Image at the specified location.

Syntax

public void DrawImage (Image image, Point[] destPoints, Rectangle srcRect, GraphicsUnit srcUnit, System.Drawing.Imaging.ImageAttributes imageAttr)

Parameters

image
System.Drawing.Image to draw.
destPoints
Array of three System.Drawing.Point structures that define a parallelogram.
srcRect
System.Drawing.Rectangle structure that specifies the portion of the image object to draw.
srcUnit
Member of the System.Drawing.GraphicsUnit enumeration that specifies the units of measure used by the srcRect parameter.
imageAttr
System.Drawing.Imaging.ImageAttributes that specifies recoloring and gamma information for the image object.

Remarks

The destPoints parameter specifies three points of a parallelogram. The three System.Drawing.Point structures represent the upper-left, upper-right, and lower-left corners of the parallelogram. The fourth point is extrapolated from the first three to form a parallelogram.

The srcRect parameter specifies a rectangular portion of the image object to draw. This portion is scaled and sheared to fit inside the parallelogram specified by the destPoints parameter.

Requirements

Namespace: System.Drawing
Assembly: System.Drawing (in System.Drawing.dll)
Assembly Versions: 1.0.5000.0, 2.0.0.0