Graphics Class |
Namespace: Aspose.PSD
The Graphics type exposes the following members.
Name | Description | |
---|---|---|
![]() | Graphics |
Initializes a new instance of the Graphics class.
|
Name | Description | |
---|---|---|
![]() | Clip |
Gets or sets the clip region.
|
![]() | CompositingQuality |
Gets or sets the compositing quality.
|
![]() | DpiX |
Gets the horizontal resolution of this Aspose.PSD.Graphics.
|
![]() | DpiY |
Gets the vertical resolution of this Aspose.PSD.Graphics.
|
![]() | Image |
Gets the image.
|
![]() | InterpolationMode |
Gets or sets the interpolation mode.
|
![]() | IsInBeginUpdateCall |
Gets a value indicating whether graphics is in BeginUpdate call state.
|
![]() | PageScale |
Gets or sets the scaling between world units and page units for this Aspose.PSD.Graphics.
|
![]() | PageUnit |
Gets or sets the unit of measure used for page coordinates in this Aspose.PSD.Graphics.
|
![]() | SmoothingMode |
Gets or sets the smoothing mode.
|
![]() | TextRenderingHint |
Gets or sets the text rendering hint.
|
![]() | Transform |
Gets or sets a copy of the geometric world transformation for this Graphics.
|
Name | Description | |
---|---|---|
![]() | BeginUpdate |
Starts caching of the following graphics operations. The graphics effects applied afterwards will not be applied immediately instead the EndUpdate will cause applying all the effects at once.
|
![]() | Clear |
Clears the graphics surface using the specified color.
|
![]() | DrawArc(Pen, Rectangle, Single, Single) |
Draws an arc representing a portion of an ellipse specified by a Rectangle structure.
|
![]() | DrawArc(Pen, RectangleF, Single, Single) |
Draws an arc representing a portion of an ellipse specified by a RectangleF structure.
|
![]() | DrawArc(Pen, Int32, Int32, Int32, Int32, Int32, Int32) |
Draws an arc representing a portion of an ellipse specified by a pair of coordinates, a width, and a height.
|
![]() | DrawArc(Pen, Single, Single, Single, Single, Single, Single) |
Draws an arc representing a portion of an ellipse specified by a pair of coordinates, a width, and a height.
|
![]() | DrawBezier(Pen, Point, Point, Point, Point) |
Draws a Bézier spline defined by four Point structures.
|
![]() | DrawBezier(Pen, PointF, PointF, PointF, PointF) |
Draws a Bézier spline defined by four PointF structures.
|
![]() | DrawBezier(Pen, Single, Single, Single, Single, Single, Single, Single, Single) |
Draws a Bézier spline defined by four ordered pairs of coordinates that represent points.
|
![]() | DrawBeziers(Pen, Point) |
Draws a series of Bézier splines from an array of Point structures.
|
![]() | DrawBeziers(Pen, PointF) |
Draws a series of Bézier splines from an array of PointF structures.
|
![]() | DrawClosedCurve(Pen, Point) | |
![]() | DrawClosedCurve(Pen, PointF) | |
![]() | DrawClosedCurve(Pen, Point, Single) | |
![]() | DrawClosedCurve(Pen, PointF, Single) | |
![]() | DrawCurve(Pen, Point) |
Draws a cardinal spline through a specified array of Point structures.
|
![]() | DrawCurve(Pen, PointF) |
Draws a cardinal spline through a specified array of PointF structures. This method uses a default tension of 0.5.
|
![]() | DrawCurve(Pen, Point, Single) |
Draws a cardinal spline through a specified array of Point structures using a specified tension.
|
![]() | DrawCurve(Pen, PointF, Single) |
Draws a cardinal spline through a specified array of PointF structures using a specified tension.
|
![]() | DrawCurve(Pen, PointF, Int32, Int32) |
Draws a cardinal spline through a specified array of PointF structures. The drawing begins offset from the beginning of the array.
This method uses a default tension of 0.5.
|
![]() | DrawCurve(Pen, Point, Int32, Int32, Single) |
Draws a cardinal spline through a specified array of Point structures using a specified tension.
|
![]() | DrawCurve(Pen, PointF, Int32, Int32, Single) |
Draws a cardinal spline through a specified array of PointF structures using a specified tension. The drawing begins offset from the beginning of the array.
|
![]() | DrawEllipse(Pen, Rectangle) |
Draws an ellipse specified by a bounding Rectangle structure.
|
![]() | DrawEllipse(Pen, RectangleF) |
Draws an ellipse defined by a bounding RectangleF.
|
![]() | DrawEllipse(Pen, Int32, Int32, Int32, Int32) |
Draws an ellipse defined by a bounding rectangle specified by a pair of coordinates, a height, and a width.
|
![]() | DrawEllipse(Pen, Single, Single, Single, Single) |
Draws an ellipse defined by a bounding rectangle specified by a pair of coordinates, a height, and a width.
|
![]() | DrawImage(Image, Point) |
Draws the specified Image, using its original physical size, at the specified location.
|
![]() | DrawImage(Image, Point) |
Draws the specified portion of the specified image at the specified location and with the specified size.
|
![]() | DrawImage(Image, PointF) |
Draws the specified Image, using its original physical size, at the specified location.
|
![]() | DrawImage(Image, PointF) |
Draws the specified portion of the specified image at the specified location and with the specified size.
|
![]() | DrawImage(Image, Rectangle) |
Draws the specified Image at the specified location and with the specified size.
|
![]() | DrawImage(Image, RectangleF) |
Draws the specified Image at the specified location and with the specified size.
|
![]() | DrawImage(Image, Point, Rectangle) |
Draws the specified portion of the specified image at the specified location and with the specified size.
|
![]() | DrawImage(Image, PointF, RectangleF) |
Draws the specified portion of the specified image at the specified location and with the specified size.
|
![]() | DrawImage(Image, Rectangle, GraphicsUnit) |
Draws the specified Image at the specified location and with the specified size.
|
![]() | DrawImage(Image, RectangleF, GraphicsUnit) |
Draws the specified Image at the specified location and with the specified size.
|
![]() | DrawImage(Image, Int32, Int32) |
Draws the specified image, using its original physical size, at the location specified by a coordinate pair.
|
![]() | DrawImage(Image, Single, Single) |
Draws the specified Image, using its original physical size, at the specified location.
|
![]() | DrawImage(Image, Point, Rectangle, GraphicsUnit) |
Draws the specified portion of the specified image at the specified location and with the specified size.
|
![]() | DrawImage(Image, PointF, RectangleF, GraphicsUnit) |
Draws the specified portion of the specified image at the specified location and with the specified size.
|
![]() | DrawImage(Image, Rectangle, GraphicsUnit, ImageAttributes) |
Draws the specified Image at the specified location and with the specified size.
|
![]() | DrawImage(Image, Rectangle, Rectangle, GraphicsUnit) |
Draws the specified Image at the specified location and with the specified size.
|
![]() | DrawImage(Image, RectangleF, GraphicsUnit, ImageAttributes) |
Draws the specified Image at the specified location and with the specified size.
|
![]() | DrawImage(Image, RectangleF, RectangleF, GraphicsUnit) |
Draws the specified Image at the specified location and with the specified size.
|
![]() | DrawImage(Image, Point, Rectangle, GraphicsUnit, ImageAttributes) |
Draws the specified portion of the specified image at the specified location and with the specified size.
|
![]() | DrawImage(Image, PointF, RectangleF, GraphicsUnit, ImageAttributes) |
Draws the specified portion of the specified image at the specified location and with the specified size.
|
![]() | DrawImage(Image, Rectangle, Rectangle, GraphicsUnit, ImageAttributes) |
Draws the specified Image at the specified location and with the specified size.
|
![]() | DrawImage(Image, RectangleF, RectangleF, GraphicsUnit, ImageAttributes) |
Draws the specified Image at the specified location and with the specified size.
|
![]() | DrawImage(Image, Int32, Int32, Int32, Int32) |
Draws the specified Image at the specified location and with the specified size.
|
![]() | DrawImage(Image, Single, Single, Single, Single) |
Draws the specified Image at the specified location and with the specified size.
|
![]() | DrawImageUnscaled(Image, Point) |
Draws a specified image using its original physical size at a specified location.
|
![]() | DrawImageUnscaled(Image, Rectangle) |
Draws a specified image using its original physical size at a specified location.
|
![]() | DrawImageUnscaled(Image, Int32, Int32) |
Draws the specified image using its original physical size at the location specified by a coordinate pair.
|
![]() | DrawImageUnscaled(Image, Int32, Int32, Int32, Int32) |
Draws a specified image using its original physical size at a specified location.
|
![]() | DrawImageUnscaledAndClipped |
Draws the specified image without scaling and clips it, if necessary, to fit in the specified rectangle.
|
![]() | DrawLine(Pen, Point, Point) |
Draws a line connecting two Point structures.
|
![]() | DrawLine(Pen, PointF, PointF) |
Draws a line connecting two PointF structures.
|
![]() | DrawLine(Pen, Int32, Int32, Int32, Int32) |
Draws a line connecting the two points specified by the coordinate pairs.
|
![]() | DrawLine(Pen, Single, Single, Single, Single) |
Draws a line connecting the two points specified by the coordinate pairs.
|
![]() | DrawLines(Pen, Point) |
Draws a series of line segments that connect an array of Point structures.
|
![]() | DrawLines(Pen, PointF) |
Draws a series of line segments that connect an array of PointF structures.
|
![]() ![]() | DrawPath |
Draws a GraphicsPath.
|
![]() | DrawPie(Pen, Rectangle, Single, Single) |
Draws a pie shape defined by an ellipse specified by a Rectangle structure and two radial lines.
|
![]() | DrawPie(Pen, RectangleF, Single, Single) |
Draws a pie shape defined by an ellipse specified by a RectangleF structure and two radial lines.
|
![]() | DrawPie(Pen, Int32, Int32, Int32, Int32, Int32, Int32) |
Draws a pie shape defined by an ellipse specified by a coordinate pair, a width, a height, and two radial lines.
|
![]() | DrawPie(Pen, Single, Single, Single, Single, Single, Single) |
Draws a pie shape defined by an ellipse specified by a coordinate pair, a width, a height, and two radial lines.
|
![]() | DrawPolygon(Pen, Point) |
Draws a polygon defined by an array of Point structures.
|
![]() | DrawPolygon(Pen, PointF) |
Draws a polygon defined by an array of PointF structures.
|
![]() | DrawRectangle(Pen, Rectangle) |
Draws a rectangle specified by a Rectangle structure.
|
![]() | DrawRectangle(Pen, RectangleF) |
Draws a rectangle specified by a RectangleF structure.
|
![]() | DrawRectangle(Pen, Int32, Int32, Int32, Int32) |
Draws a rectangle specified by a coordinate pair, a width, and a height.
|
![]() | DrawRectangle(Pen, Single, Single, Single, Single) |
Draws a rectangle specified by a coordinate pair, a width, and a height.
|
![]() ![]() | DrawRectangles(Pen, Rectangle) |
Draws a series of rectangles specified by Rectangle structures.
|
![]() | DrawRectangles(Pen, RectangleF) |
Draws a series of rectangles specified by RectangleF structures.
|
![]() ![]() | DrawString(String, Font, Brush, PointF) | |
![]() | DrawString(String, Font, Brush, RectangleF) | |
![]() | DrawString(String, Font, Brush, PointF, StringFormat) |
Draws the specified text string at the specified location with the specified Brush and Font objects using the formatting attributes of the specified StringFormat.
|
![]() | DrawString(String, Font, Brush, RectangleF, StringFormat) |
Draws the specified text string in the specified rectangle with the specified Brush and Font objects using the formatting attributes of the specified StringFormat.
|
![]() | DrawString(String, Font, Brush, Single, Single) | |
![]() | DrawString(String, Font, Brush, Single, Single, StringFormat) |
Draws the specified text string at the specified location with the specified Brush and Font objects using the formatting attributes of the specified StringFormat.
|
![]() | EndUpdate |
Finishes caching of the graphics operations started after BeginUpdate was called. The preceding graphics operations will be applied at once when calling this method.
|
![]() | Equals | (Inherited from Object.) |
![]() | FillClosedCurve(Brush, Point) | |
![]() | FillClosedCurve(Brush, PointF) | |
![]() | FillClosedCurve(Brush, Point, FillMode) |
Fills the interior of a closed cardinal spline curve defined by an array of Point structures using the specified fill mode. This method uses a default tension of 0.5.
|
![]() | FillClosedCurve(Brush, PointF, FillMode) |
Fills the interior of a closed cardinal spline curve defined by an array of PointF structures using the specified fill mode. This method uses a default tension of 0.5.
|
![]() | FillClosedCurve(Brush, Point, FillMode, Single) |
Fills the interior of a closed cardinal spline curve defined by an array of Point structures using the specified fill mode and tension.
|
![]() | FillClosedCurve(Brush, PointF, FillMode, Single) |
Fills the interior of a closed cardinal spline curve defined by an array of PointF structures using the specified fill mode and tension.
|
![]() | FillEllipse(Brush, Rectangle) |
Fills the interior of an ellipse defined by a bounding rectangle specified by a Rectangle structure.
|
![]() | FillEllipse(Brush, RectangleF) |
Fills the interior of an ellipse defined by a bounding rectangle specified by a RectangleF structure.
|
![]() | FillEllipse(Brush, Int32, Int32, Int32, Int32) |
Fills the interior of an ellipse defined by a bounding rectangle specified by a pair of coordinates, a width, and a height.
|
![]() | FillEllipse(Brush, Single, Single, Single, Single) |
Fills the interior of an ellipse defined by a bounding rectangle specified by a pair of coordinates, a width, and a height.
|
![]() | FillPath |
Fills the interior of a GraphicsPath.
|
![]() | FillPie(Brush, Rectangle, Single, Single) |
Fills the interior of a pie section defined by an ellipse specified by a RectangleF structure and two radial lines.
|
![]() | FillPie(Brush, RectangleF, Single, Single) |
Fills the interior of a pie section defined by an ellipse specified by a RectangleF structure and two radial lines.
|
![]() | FillPie(Brush, Int32, Int32, Int32, Int32, Int32, Int32) |
Fills the interior of a pie section defined by an ellipse specified by a pair of coordinates, a width, a height, and two radial lines.
|
![]() | FillPie(Brush, Single, Single, Single, Single, Single, Single) |
Fills the interior of a pie section defined by an ellipse specified by a pair of coordinates, a width, a height, and two radial lines.
|
![]() | FillPolygon(Brush, Point) | |
![]() | FillPolygon(Brush, PointF) | |
![]() | FillPolygon(Brush, Point, FillMode) |
Fills the interior of a polygon defined by an array of points specified by Point structures using the specified fill mode.
|
![]() | FillPolygon(Brush, PointF, FillMode) |
Fills the interior of a polygon defined by an array of points specified by PointF structures using the specified fill mode.
|
![]() | FillRectangle(Brush, Rectangle) |
Fills the interior of a rectangle specified by a Rectangle structure.
|
![]() | FillRectangle(Brush, RectangleF) |
Fills the interior of a rectangle specified by a RectangleF structure.
|
![]() | FillRectangle(Brush, Int32, Int32, Int32, Int32) |
Fills the interior of a rectangle specified by a pair of coordinates, a width and a height.
|
![]() | FillRectangle(Brush, Single, Single, Single, Single) |
Fills the interior of a rectangle specified by a pair of coordinates, a width and a height.
|
![]() | FillRectangles(Brush, Rectangle) |
Fills the interiors of a series of rectangles specified by Rectangle structures.
|
![]() | FillRectangles(Brush, RectangleF) |
Fills the interiors of a series of rectangles specified by RectangleF structures.
|
![]() | FillRegion |
Fills the interior of a Region.
|
![]() | GetHashCode | (Inherited from Object.) |
![]() | GetType | (Inherited from Object.) |
![]() | MultiplyTransform(Matrix) | |
![]() | MultiplyTransform(Matrix, MatrixOrder) | |
![]() | ResetTransform |
Resets the Transform property to identity.
|
![]() | RotateTransform(Single) |
Rotates the local geometric transform by the specified amount. This method prepends the rotation to the transform.
|
![]() | RotateTransform(Single, MatrixOrder) |
Rotates the local geometric transform by the specified amount in the specified order.
|
![]() | ScaleTransform(Single, Single) |
Scales the local geometric transform by the specified amounts. This method prepends the scaling matrix to the transform.
|
![]() | ScaleTransform(Single, Single, MatrixOrder) |
Scales the local geometric transform by the specified amounts in the specified order.
|
![]() | ToString | (Inherited from Object.) |
![]() | TranslateTransform(Single, Single) |
Translates the local geometric transform by the specified dimensions. This method prepends the translation to the transform.
|
![]() | TranslateTransform(Single, Single, MatrixOrder) |
Translates the local geometric transform by the specified dimensions in the specified order.
|
[C#] //Create an instance of Image using (Aspose.PSD.Image image = new Aspose.PSD.FileFormats.Psd.PsdImage(500, 500)) { //Create and initialize an instance of Graphics class Aspose.PSD.Graphics graphics = new Aspose.PSD.Graphics(image); //Clear Graphics surface graphics.Clear(Color.Wheat); //Draw an Arc by specifying the Pen object having Black color, //a Rectangle surrounding the Arc, Start Angle and Sweep Angle graphics.DrawArc(new Pen(Color.Black, 2), new Rectangle(200, 200, 100, 200), 0, 300); //Draw a Bezier by specifying the Pen object having Blue color and co-ordinate Points. graphics.DrawBezier(new Pen(Color.Blue, 2), new Point(250, 100), new Point(300, 30), new Point(450, 100), new Point(235, 25)); //Draw a Curve by specifying the Pen object having Green color and an array of Points graphics.DrawCurve(new Pen(Color.Green, 2), new[] { new Point(100, 200), new Point(100, 350), new Point(200, 450) }); //Draw an Ellipse using the Pen object and a surrounding Rectangle graphics.DrawEllipse(new Pen(Color.Yellow, 2), new Rectangle(300, 300, 100, 100)); //Draw a Line graphics.DrawLine(new Pen(Color.Violet, 2), new Point(100, 100), new Point(200, 200)); //Draw a Pie segment graphics.DrawPie(new Pen(Color.Silver, 2), new Rectangle(new Point(200, 20), new Size(200, 200)), 0, 45); //Draw a Polygon by specifying the Pen object having Red color and an array of Points graphics.DrawPolygon(new Pen(Color.Red, 2), new[] { new Point(20, 100), new Point(20, 200), new Point(220, 20) }); //Draw a Rectangle graphics.DrawRectangle(new Pen(Color.Orange, 2), new Rectangle(new Point(250, 250), new Size(100, 100))); //Create a SolidBrush object and set its various properties Aspose.PSD.Brushes.SolidBrush brush = new Aspose.PSD.Brushes.SolidBrush(); brush.Color = Color.Purple; brush.Opacity = 100; //Draw a String using the SolidBrush object and Font, at specific Point graphics.DrawString("This image is created by Aspose.PSD API", new Font("Times New Roman", 16), brush, new PointF(50, 400)); //Create an instance of PngOptions and set its various properties Aspose.PSD.ImageOptions.PngOptions pngOptions = new Aspose.PSD.ImageOptions.PngOptions(); // save all changes. image.Save("C:\\temp\\output.png", pngOptions); }