New to Telerik UI for ASP.NET AJAX? Start a free 30-day trial

IGraphicsCore

Interface

Specifies methods that change the graphics of an image. The operations should not change the original image, but rather provide an altered version as a result.

Definition

Namespace:Telerik.Web.UI.ImageEditor

Assembly:Telerik.Web.UI.dll

Syntax:

C#
public interface IGraphicsCore

Derived Classes: GDIGraphicsCoreGDIOperationsBasedGraphicsCore

Methods

Adds text to the image on the provided position.

C#
Image AddText(Image original, Point position, ImageText text)
Parameters:originalImage

The original image being the base for the operation

positionPoint

The top/left position relative to the original image.

textImageText

The definition of the test to insert, including the content itself

Returns:

Image

The resultant image of the applied graphics method

Defines the changes of the pixel opacity of the provided Image

C#
Image ChangeOpacity(Image original, double opacity)
Parameters:originalImage

The original image being the base for the operation

opacitydouble

The level of opacity. Should be in the range [0-1].

Returns:

Image

The resultant image of the applied graphics method

Converts the image to the specified format. This change may degrade the quality of the image.

C#
Image ConvertTo(Image original, EditableFormat format)
Parameters:originalImage

The original image being the base for the operation

formatEditableFormat

The format of the resultant image

Returns:

Image

The resultant image of the applied graphics method

Crops the provided image using the specified rectangular box

C#
Image Crop(Image original, Rectangle rectange)
Parameters:originalImage

The original image being the base for the operation

rectangeRectangle

The bounding box specifying the cropping area

Returns:

Image

The resultant image of the applied graphics method

Flips the image content in the specified direction

C#
Image Flip(Image original, FlipDirection direction)
Parameters:originalImage

The original image being the base for the operation

directionFlipDirection

The direction of the flip change.

Returns:

Image

The resultant image of the applied graphics method

Insert another image within the original image at the specified location.

C#
Image InsertImage(Image original, Point position, Image imageToInsert)
Parameters:originalImage

The original image being the base for the operation

positionPoint

The top/left coordinates relative to the original image.

imageToInsertImage

The image that should be inserted in the original image

Returns:

Image

The resultant image of the applied graphics method

Resizes the original image by shrinking or expanding it by the provided dimensions

C#
Image Resize(Image original, Size size)
Parameters:originalImage

The original image being the base for the operation

sizeSize

The new dimensions of the image

Returns:

Image

The resultant image of the applied graphics method

Rotates the image using the enumerated rotation. Currently only rectangular angles' are supported - 90°, 180°, 270°

C#
Image Rotate(Image original, Rotation rotate)
Parameters:originalImage

The original image being the base for the operation

rotateRotation

The rotation direction for the rotation method

Returns:

Image

The resultant image of the applied graphics method