Imager
Allows for basic manipulation of images such as cropping and scaling.
Constructors
|
Constructor
|
Initializes a new instance of the Imager class and optionally loads a specified file path into the object.
Arguments:
(void)
(FilePath)
(ThisImage)
|
Methods
|
Constrain
|
Constrains the output image to a specific height and width.
|
|
ConstrainHeight
|
Constrains the output image to a specific height.
|
|
ConstrainWidth
|
Constrains the output image to a specific width.
|
|
Crop
|
Crops the output image with a specified height, width and specified X and Y positions or a specifed string anchor.
Arguments:
(Height, Width, Anchor)
(Height, Width, SourceX, SourceY)
|
|
FixedSize
|
Sets a fixed size to the output image with specified height and width.
|
|
GetCanvas
|
Returns the canvas object of the image being modified in this instance.
|
|
GetHeight
|
Returns the height of the image.
|
|
GetWidth
|
Returns the width of the image.
|
|
Load
|
Loads an image from a specified file path.
|
|
SaveAs
|
Writes the output image to the specified file path.
|
|
SaveHTTP
|
Writes the output image to the browser and optionally uses a specified file name.
|
|
ScaleByPercent
|
Scales the output image with specified integer percent.
|
Properties
|
BackgroundColor
|
Gets and sets the hex color expression used in background color of the output image. |
|
ContentType
|
Gets and sets the content type header that is used when SaveHTTP is executed. |
|
ImageName
|
Gets and sets the output image name. |
|
OutputImage
|
Stores the image manipulated in this instance |
Notes
|