GDIGraphicsCore
A straight-forward implementation of the IGraphicsCore using GDI+
Definition
Namespace:Telerik.Web.UI.ImageEditor
Assembly:Telerik.Web.UI.dll
Syntax:
public class GDIGraphicsCore : IGraphicsCore
Inheritance: objectGDIGraphicsCore
Implements:
Inherited Members
Constructors
public GDIGraphicsCore()
Methods
Adds text to the image on the provided position.
public virtual Image AddText(Image original, Point position, ImageText text)
The original image being the base for the operation
positionPointThe top/left position relative to the original image.
textImageTextThe definition of the test to insert, including the content itself
Returns:The resultant image of the applied graphics method
Implements:
Defines the changes of the pixel opacity of the provided Image
Converts the image to the specified format. This change may degrade the quality of the image.
public virtual Image ConvertTo(Image original, EditableFormat format)
The original image being the base for the operation
formatEditableFormatThe format of the resultant image
Returns:The resultant image of the applied graphics method
Implements:
Crops the provided image using the specified rectangular box
Flips the image content in the specified direction
public virtual Image Flip(Image original, FlipDirection direction)
The original image being the base for the operation
directionFlipDirectionThe direction of the flip change.
Returns:The resultant image of the applied graphics method
Implements:
Insert another image within the original image at the specified location.
public virtual Image InsertImage(Image original, Point position, Image imageToInsert)
The original image being the base for the operation
positionPointThe top/left coordinates relative to the original image.
imageToInsertImageThe image that should be inserted in the original image
Returns:The resultant image of the applied graphics method
Implements:
Resize the image using a specific interpolation mode.
public virtual Image Resize(Image originalImg, Size newSize, InterpolationMode intMode)
The original image to resize.
newSizeSizeThe new image size.
intModeInterpolationModeThe interpolation mode to use. All modes except NearestNeighbor will cause a small loss (1-2 px) of image data around the edges of the original image.
Returns:The resized image. If the new size is identical to the original size, then the original image is returned.
Resizes the original image by shrinking or expanding it by the provided dimensions
Rotates the image using the enumerated rotation. Currently only rectangular angles' are supported - 90°, 180°, 270°