Chroma Paint

Brush Texture2DExtensions TextureCoordinate

Texture2DExtensions


Description

An extension class which adds a bunch of Image-editor friendly features to Texture2D objects.

Class Methods

FlipHorizontal ()
Flips the texture horizontally.

FlipVertical ()
Flips the texture horizontally.

Rotate ()
Rotates the texture.

ChangeCanvasSize (int width, int height)
Changes the size of the canvas.

ChangeImageSize (int width, int height)
Changes the size of the image.

Trim (float threshold)
Removes transparent pixels away from the texture.

OffsetTexture (int xOffset, int yOffset)
Offsets the texture.

Brighten (float amount)


InvertColors ()


Desaturate ()


Reset (int width, int height, Color color)


ChangeContrast (float amount)


MakeTexturePixelsIdentical (Texture2D source)