Bitmap representation of an image with helper methods for manipulating the image and enabling IO with other platforms.
More...
|
| Image (SKSurface surface) |
| Create an Image from the snapshot of an existing Surface.
|
|
| Image (string filename) |
| Create an Image from a file on disk.
|
|
| Image (byte[] bytes) |
| Create an Image from a byte array of image data encoded in a common file format.
|
|
| Image (SKBitmap bmp) |
| Create an Image from an existing bitmap.
|
|
| Image (int width, int height) |
| Create a black Image with the given dimensions.
|
|
| Image (PixelSize size) |
| Create a black Image with the given dimensions.
|
|
| Image (int width, int height, Color color) |
| Create an image filled with the given color.
|
|
| Image (byte[,] pixelArray) |
| Create a grayscale Image from a 2D array of bytes. R, G, and B channels will all be set to the given value for each pixel.
|
|
| Image (byte[,,] pixelArray) |
| Create an Image from a 3D array of bytes with axes representing Y position, X position, and Color.
|
|
byte[] | GetImageBytes (ImageFormat format=ImageFormat.Png, int quality=100) |
| Return the image as a platform-agnostic byte array that can be consumed by any common image library.
|
|
SavedImageInfo | SaveJpeg (string path, int quality=85) |
|
SavedImageInfo | SavePng (string path) |
|
SavedImageInfo | SaveBmp (string path) |
|
SavedImageInfo | SaveWebp (string path, int quality=85) |
|
SavedImageInfo | Save (string path, ImageFormat format=ImageFormat.Png, int quality=85) |
|
void | Dispose () |
|
void | Render (SKCanvas canvas, PixelRect target, SKPaint paint, bool antiAlias) |
| Draw the image onto the given canvas.
|
|
byte[,] | GetArrayGrayscale () |
| Return the image as a 2D byte array grayscale image with axes representing X and Y positions. Grayscale values for each pixel are the mean of R, G, and B channels.
|
|
byte[,,] | GetArrayRGB () |
| Return the image as a 3D byte array with axes representing X position, Y position, and Color.
|
|
Image | GetAutoscaledImage () |
| Return a new image with brightness/contrast maximized to fit the range of the data.
|
|
Image | Scaled (double scale, bool antiAlias=true) |
| Return a new image with dimensions scaled by the given scale factor. A scale factor of 2.0 will double the size of the returned image.
|
|
Image | Scaled (double scaleX, double scaleY, bool antiAlias=true) |
| Return a new image with dimensions scaled by the given scale factors. A scale factor of 2.0 will double the size of the returned image.
|
|
Image | Resized (int newWidth, int newHeight, bool antiAlias=true) |
| Return a new image resized to fit the given dimensions.
|
|
Bitmap representation of an image with helper methods for manipulating the image and enabling IO with other platforms.