DirectOutput
DirectOutput framework R2 for virtual pinball cabinets.
 All Classes Namespaces Files Functions Variables Enumerations Enumerator Properties Events Macros Pages
DirectOutput.General.BitmapHandling.FastBitmap Class Reference

Public Member Functions

PixelData GetPixel (int X, int Y)
 Gets the PixelData for the specified pixel of the frame.
For positions outside the frame, the method will return PixelData for a fully transparent black pixel. More...
 
FastBitmap GetClip (int ResultWidth, int ResultHeight, int SourceLeft=0, int SourceTop=0, int SourceWidth=-1, int SourceHeight=-1, FastBitmapDataExtractModeEnum DataExtractMode=FastBitmapDataExtractModeEnum.SinglePixelCenter)
 Gets a FastBitmap with a specified size representing a defineable section of the current object. More...
 
void SetFrameSize (int Width, int Height)
 Sets the size (width/height) of the frame.
Setting the framesize will discard all existing pixel data of the frame. More...
 
void Load (Image Image)
 Loads the currently active frame of the specified Image into the FastBitmap object. More...
 
void Load (Bitmap Bitmap)
 Loads the currently active frame of the specified bitmap into the FastBitmap object. More...
 
 FastBitmap ()
 Initializes a new instance of the FastBitmap class. More...
 
 FastBitmap (Bitmap Bitmap)
 Initializes a new instance of the FastBitmap class and loads the currently active frame of the specified bitmap into the FastBitmap object. More...
 
 FastBitmap (Image Image)
 Initializes a new instance of the FastBitmap class and loads the currently active frame of the specified image into the FastBitmap object.. More...
 

Properties

PixelData[,] Pixels [get, set]
 The pixel data array of the frame.
Dimension 0 if the array is the x/horizontal direction. Dimension 1 of the array is the y/vertical direction. More...
 
int Width [get]
 Gets the width of the frame.
More...
 
int Height [get]
 Get the height of the frame.
More...
 

Constructor & Destructor Documentation

DirectOutput.General.BitmapHandling.FastBitmap.FastBitmap ( )

Initializes a new instance of the FastBitmap class.

DirectOutput.General.BitmapHandling.FastBitmap.FastBitmap ( Bitmap  Bitmap)

Initializes a new instance of the FastBitmap class and loads the currently active frame of the specified bitmap into the FastBitmap object.

Parameters
BitmapThe bitmap.
DirectOutput.General.BitmapHandling.FastBitmap.FastBitmap ( Image  Image)

Initializes a new instance of the FastBitmap class and loads the currently active frame of the specified image into the FastBitmap object..

Parameters
ImageThe image.

Member Function Documentation

FastBitmap DirectOutput.General.BitmapHandling.FastBitmap.GetClip ( int  ResultWidth,
int  ResultHeight,
int  SourceLeft = 0,
int  SourceTop = 0,
int  SourceWidth = -1,
int  SourceHeight = -1,
FastBitmapDataExtractModeEnum  DataExtractMode = FastBitmapDataExtractModeEnum.SinglePixelCenter 
)

Gets a FastBitmap with a specified size representing a defineable section of the current object.

Parameters
ResultWidthWidth of the resulting FastBitmap object.
ResultHeightHeight of the resulting FastBitmap object.
SourceLeftThe left boundary for the source area.
SourceTopThe top boundary of the source arrea.
SourceWidthWidth of the source area.
SourceHeightHeight of the source area.
DataExtractModeThe data extract mode enum.
Returns
FastBitmap object with a specified size representing a defineable section of the current object
PixelData DirectOutput.General.BitmapHandling.FastBitmap.GetPixel ( int  X,
int  Y 
)

Gets the PixelData for the specified pixel of the frame.
For positions outside the frame, the method will return PixelData for a fully transparent black pixel.

Parameters
XThe X position of the pixel.
YThe Y position of the pixel.
Returns
PixelData for the specified pixel.
void DirectOutput.General.BitmapHandling.FastBitmap.Load ( Image  Image)

Loads the currently active frame of the specified Image into the FastBitmap object.

Parameters
BitmapThe bitmap.
void DirectOutput.General.BitmapHandling.FastBitmap.Load ( Bitmap  Bitmap)

Loads the currently active frame of the specified bitmap into the FastBitmap object.

Parameters
BitmapThe bitmap.
void DirectOutput.General.BitmapHandling.FastBitmap.SetFrameSize ( int  Width,
int  Height 
)

Sets the size (width/height) of the frame.
Setting the framesize will discard all existing pixel data of the frame.

Parameters
WidthThe width of the frame.
HeightThe height of the frame.

Property Documentation

int DirectOutput.General.BitmapHandling.FastBitmap.Height
get

Get the height of the frame.

The height of the frame.

PixelData [,] DirectOutput.General.BitmapHandling.FastBitmap.Pixels
getset

The pixel data array of the frame.
Dimension 0 if the array is the x/horizontal direction. Dimension 1 of the array is the y/vertical direction.

The pixels array of the frame.

int DirectOutput.General.BitmapHandling.FastBitmap.Width
get

Gets the width of the frame.

The width of the frame.


The documentation for this class was generated from the following file: