C# Class Imager.cImage

Show file Open project: soywiz/cspspemu Class Usage Examples

Public Methods

Method Description
Clone ( ) : object

Creates a new object that is a copy of the current instance.

Fill ( byte red, byte green, byte blue, byte alpha = 255 ) : void

Fills the image with the specified color.

Fill ( sPixel pixel ) : void

Fills the image with the specified pixel.

FromBitmap ( Bitmap bitmap ) : cImage

Initializes a new instance of the cImage class from a Bitmap instance.

ToBitmap ( ) : Bitmap

Converts this image to a Bitmap instance.

ToBitmap ( int sx, int sy, int width, int height ) : Bitmap

Converts this image to a Bitmap instance.

cImage ( cImage sourceImage ) : System.Collections.Concurrent

Initializes a new instance of the cImage class from a given one.

cImage ( cImage sourceImage, byte>.Func colorFilter ) : System.Collections.Concurrent

Initializes a new greyscale instance of the cImage class by filtering a given one.

cImage ( cImage sourceImage, sPixel>.Func filterFunction ) : System.Collections.Concurrent

Initializes a new instance of the cImage class by filtering a given one.

cImage ( int width, int height ) : System.Collections.Concurrent

Initializes a new instance of the cImage class.

this ( int x, int y ) : sPixel

Gets or sets the sPixel with the specified X, Y coordinates.

Method Details

Clone() public method

Creates a new object that is a copy of the current instance.
public Clone ( ) : object
return object

Fill() public method

Fills the image with the specified color.
public Fill ( byte red, byte green, byte blue, byte alpha = 255 ) : void
red byte The red-value.
green byte The green-value.
blue byte The blue-value.
alpha byte The alpha-value.
return void

Fill() public method

Fills the image with the specified pixel.
public Fill ( sPixel pixel ) : void
pixel sPixel The pixel instance.
return void

FromBitmap() public static method

Initializes a new instance of the cImage class from a Bitmap instance.
public static FromBitmap ( Bitmap bitmap ) : cImage
bitmap System.Drawing.Bitmap The bitmap.
return cImage

ToBitmap() public method

Converts this image to a Bitmap instance.
public ToBitmap ( ) : Bitmap
return System.Drawing.Bitmap

ToBitmap() public method

Converts this image to a Bitmap instance.
public ToBitmap ( int sx, int sy, int width, int height ) : Bitmap
sx int The start x.
sy int The start y.
width int The width.
height int The height.
return System.Drawing.Bitmap

cImage() public method

Initializes a new instance of the cImage class from a given one.
public cImage ( cImage sourceImage ) : System.Collections.Concurrent
sourceImage cImage The source image.
return System.Collections.Concurrent

cImage() public method

Initializes a new greyscale instance of the cImage class by filtering a given one.
public cImage ( cImage sourceImage, byte>.Func colorFilter ) : System.Collections.Concurrent
sourceImage cImage The source image.
colorFilter byte>.Func The greyscale filter.
return System.Collections.Concurrent

cImage() public method

Initializes a new instance of the cImage class by filtering a given one.
public cImage ( cImage sourceImage, sPixel>.Func filterFunction ) : System.Collections.Concurrent
sourceImage cImage The source image.
filterFunction sPixel>.Func The filter.
return System.Collections.Concurrent

cImage() public method

Initializes a new instance of the cImage class.
public cImage ( int width, int height ) : System.Collections.Concurrent
width int Width of the image.
height int Height of the image.
return System.Collections.Concurrent

this() public method

Gets or sets the sPixel with the specified X, Y coordinates.
public this ( int x, int y ) : sPixel
x int
y int
return sPixel