WIP
DirectOutput framework for virtual pinball cabinets WIP
|
Go to: Overview |
Represents a adressable led strip. More...
Public Member Functions | |
override void | Init (Cabinet Cabinet) |
Initializes the toy. More... | |
override void | Reset () |
Resets the toy. Turns all outputs off. More... | |
override void | UpdateOutputs () |
Updates the data of the assigned output controller More... | |
RGBAColor[,] | GetLayer (int LayerNr) |
Gets the 2 dimensional RGBAColor array for the specified layer. More... | |
LedStrip () | |
Initializes a new instance of the LedStrip class. More... | |
Public Member Functions inherited from DirectOutput.Cab.Toys.ToyBase | |
virtual void | Finish () |
Must finish the IToy, do all necessary clean up work and reset to IToy to its default state (off). Method is virtual and can be overwritten. More... | |
Public Member Functions inherited from DirectOutput.Cab.Toys.IMatrixToy< RGBAColor > | |
MatrixElementType[,] | GetLayer (int LayerNr) |
Gets the specified layer of MatrixElementTypes of the toy. More... | |
Properties | |
int | Width [get, set] |
Gets or sets the width resp. number of leds in horizontal direction of the led stripe. More... | |
int | Height [get, set] |
Gets or sets the height resp. the number of leds in vertical direction of the led strip. More... | |
int | NumberOfLeds [get] |
Gets the number of leds of the led stripe. More... | |
int | NumberOfOutputs [get] |
Gets the number of outputs required for the ledstrip. More... | |
LedStripArrangementEnum | LedStripArrangement [get, set] |
Gets or sets the strip arrangement. The following image explains the meaining of the different values. More... | |
RGBOrderEnum | ColorOrder [get, set] |
Gets or sets the order of the colors for the leds of the led strip. Usually colors are represented in RGB (Red - Green - Blue) order, but depending on the type of the used strip the color order might be different (e.g. WS2812 led chips have green - red - blue as their color order). More... | |
int | FirstLedNumber [get, set] |
Gets or sets the number of the first led of the strip. More... | |
string | FadingCurveName [get, set] |
Gets or sets the name of the fading curve as defined in the Curves list of the cabinet object. This curve can be used to adjust the brightness values for the led to the brightness perception of the human eye. More... | |
string | OutputControllerName [get, set] |
Gets or sets the name of the output controller to be used. More... | |
MatrixDictionaryBase< RGBAColor > | Layers [get] |
Gets the layers dictionary of the toy. More... | |
Properties inherited from DirectOutput.General.Generic.NamedItemBase | |
string | Name [get, set] |
Name of the named item. Triggers BeforeNameChange before a new Name is set. Triggers AfterNameChanged after a new name has been set. More... | |
Properties inherited from DirectOutput.General.Generic.INamedItem | |
string | Name [get, set] |
Gets or sets the name of the item. Must fire the BeforeNameChange and AfterNameChange events when the value of the property is changed. More... | |
Properties inherited from DirectOutput.Cab.Toys.IToy | |
new string | Name [get, set] |
Gets or sets the Name of the IToy. More... | |
Properties inherited from DirectOutput.Cab.Toys.IMatrixToy< RGBAColor > | |
int | Height [get] |
Gets the height resp. the y dimension of the toys matrix. More... | |
int | Width [get] |
Gets the width resp. the x dimension of the toys matrix. More... | |
Additional Inherited Members | |
Protected Member Functions inherited from DirectOutput.General.Generic.NamedItemBase | |
virtual void | AfterNameChange (string OldName, string NewName) |
virtual void | BeforeNameChange (string OldName, string NewName) |
virtual void | OnPropertyChanged (string propertyName) |
virtual void | OnPropertyChanging (string propertyName) |
Events inherited from DirectOutput.General.Generic.NamedItemBase | |
EventHandler< NameChangeEventArgs > | AfterNameChanged |
Event is fired after the value of the property Name has changed. More... | |
EventHandler< NameChangeEventArgs > | BeforeNameChanged |
Event is fired before the value of the property Name is changed. More... | |
PropertyChangedEventHandler | PropertyChanged |
PropertyChangingEventHandler | PropertyChanging |
Events inherited from DirectOutput.General.Generic.INamedItem | |
EventHandler< NameChangeEventArgs > | BeforeNameChanged |
Occurs before the name of the item changes. More... | |
EventHandler< NameChangeEventArgs > | AfterNameChanged |
Occurs when after the name of the item has changed. More... | |
Represents a adressable led strip.
The toy supports several layers and supports transparency/alpha channels for every single led.
Definition at line 18 of file LedStrip.cs.
DirectOutput.Cab.Toys.Hardware.LedStrip.LedStrip | ( | ) |
Initializes a new instance of the LedStrip class.
Definition at line 483 of file LedStrip.cs.
RGBAColor [,] DirectOutput.Cab.Toys.Hardware.LedStrip.GetLayer | ( | int | LayerNr | ) |
Gets the 2 dimensional RGBAColor array for the specified layer.
Dimension 0 of the array represents the x resp. horizontal direction. Dimension 1 of the array repersent the y resp. vertical direction. Position 0,0 is the upper left corner of the ledarray.
If the specified layer does not exist, it will be created as a fully transparent layer where all positions are set to transparent black.
LayerNr | The layer nr. |
Definition at line 250 of file LedStrip.cs.
override void DirectOutput.Cab.Toys.Hardware.LedStrip.Init | ( | Cabinet | Cabinet | ) |
Initializes the toy.
Implements DirectOutput.Cab.Toys.IToy.
Definition at line 196 of file LedStrip.cs.
override void DirectOutput.Cab.Toys.Hardware.LedStrip.Reset | ( | ) |
Resets the toy. Turns all outputs off.
Implements DirectOutput.Cab.Toys.IToy.
Definition at line 217 of file LedStrip.cs.
|
virtual |
Updates the data of the assigned output controller
Implements DirectOutput.Cab.Toys.ToyBaseUpdatable.
Definition at line 228 of file LedStrip.cs.
|
getset |
Gets or sets the order of the colors for the leds of the led strip. Usually colors are represented in RGB (Red - Green - Blue) order, but depending on the type of the used strip the color order might be different (e.g. WS2812 led chips have green - red - blue as their color order).
The color order of the leds on the strip.
Definition at line 103 of file LedStrip.cs.
|
getset |
Gets or sets the name of the fading curve as defined in the Curves list of the cabinet object. This curve can be used to adjust the brightness values for the led to the brightness perception of the human eye.
The name of the fading curve.
Definition at line 133 of file LedStrip.cs.
|
getset |
Gets or sets the number of the first led of the strip.
The number of the first led of the strip.
Definition at line 117 of file LedStrip.cs.
|
getset |
Gets or sets the height resp. the number of leds in vertical direction of the led strip.
The height of the led stripe.
Definition at line 44 of file LedStrip.cs.
|
get |
Gets the layers dictionary of the toy.
The layers dictionary of the toy.
Definition at line 186 of file LedStrip.cs.
|
getset |
Gets or sets the strip arrangement. The following image explains the meaining of the different values.
The strip arrangement value as defined in the LedStripArrangementEnum.
Definition at line 86 of file LedStrip.cs.
|
get |
Gets the number of leds of the led stripe.
The number of leds of the led stripe.
Definition at line 57 of file LedStrip.cs.
|
get |
Gets the number of outputs required for the ledstrip.
The number of outputs of the ledstrip.
Definition at line 69 of file LedStrip.cs.
|
getset |
Gets or sets the name of the output controller to be used.
The name of the output controller.
Definition at line 172 of file LedStrip.cs.
|
getset |
Gets or sets the width resp. number of leds in horizontal direction of the led stripe.
The width of the led stripe.
Definition at line 30 of file LedStrip.cs.