Package heronarts.lx.output
Enum Class LXBufferOutput.ByteOrder
- All Implemented Interfaces:
LXBufferOutput.ByteEncoder
,Serializable
,Comparable<LXBufferOutput.ByteOrder>
,Constable
- Enclosing class:
- LXBufferOutput
public static enum LXBufferOutput.ByteOrder
extends Enum<LXBufferOutput.ByteOrder>
implements LXBufferOutput.ByteEncoder
Most common static orderings for RGB buffer data
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
-
Field Summary
-
Method Summary
Modifier and TypeMethodDescriptionint[]
int
Number of bytes per pixel in this encodingstatic LXBufferOutput.ByteOrder
Returns the enum constant of this class with the specified name.static LXBufferOutput.ByteOrder[]
values()
Returns an array containing the constants of this enum class, in the order they are declared.void
writeBytes
(int color, LXOutput.GammaTable.Curve gamma, byte[] output, int offset) Writes the bytes for a color pixel to an output
-
Enum Constant Details
-
RGB
-
RBG
-
GRB
-
GBR
-
BRG
-
BGR
-
RGBW
-
RBGW
-
GRBW
-
GBRW
-
BRGW
-
BGRW
-
WRGB
-
WRBG
-
WGRB
-
WGBR
-
WBRG
-
WBGR
-
W
-
-
Field Details
-
hasWhite
public final boolean hasWhite
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum class has no constant with the specified nameNullPointerException
- if the argument is null
-
getNumBytes
public int getNumBytes()Description copied from interface:LXBufferOutput.ByteEncoder
Number of bytes per pixel in this encoding- Specified by:
getNumBytes
in interfaceLXBufferOutput.ByteEncoder
- Returns:
- Number of bytes per pixel in this encoder
-
getByteOffset
public int[] getByteOffset() -
writeBytes
Description copied from interface:LXBufferOutput.ByteEncoder
Writes the bytes for a color pixel to an output- Specified by:
writeBytes
in interfaceLXBufferOutput.ByteEncoder
- Parameters:
color
- Integer color value, ARGB formatgamma
- Gamma lookup tableoutput
- Output byte arrayoffset
- Offset to write at in output array
-