scenic
Class Format

java.lang.Object
  extended by scenic.Format

public class Format
extends java.lang.Object

Contains constants for different pixel formats. All formats are specified from most significant bit (MSB) to least significant bit (LSB). In memory the bytes area stored from LSB to MSB. So the format A8R8G8B8 is stored in memory in the following order: blue, green, red and alpha. It should be noted that the order is exactly the opposite


Nested Class Summary
static class Format.Info
          Contains information about a pixel format.
 
Field Summary
static int A8
          Alpha using 8-bits.
static int A8R8G8B8
          Alpha, red, green and blue channels using 8-bits per channel.
static int ABGR_16F
          Alpha, blue, green and red channels using 16-bit floats per channel.
static int AL_32F
          Alpha and luminance channels using 32-bit floats per channel.
static int AL_64F
          Alpha and luminance channels using 64-bit floats per channel.
static int AL8
          A single alpha-luminance value using 8-bits.
static int L8
          Luminance using 8-bits.
static int R8G8B8
          Red, green and blue channels using 8-bits per channel.
static int R8G8B8A8
          Alpha, red, green and blue channels using 8-bits per channel.
 
Method Summary
static Format.Info getInfo(int format)
          Gets the information for the given format.
static int getPixelSize(int format)
          Gets the number of bytes per pixel for the given format.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

A8R8G8B8

public static final int A8R8G8B8
Alpha, red, green and blue channels using 8-bits per channel.

See Also:
Constant Field Values

R8G8B8A8

public static final int R8G8B8A8
Alpha, red, green and blue channels using 8-bits per channel. Same format as BufferedImage.TYPE_4BYTE_ABGR.

See Also:
Constant Field Values

R8G8B8

public static final int R8G8B8
Red, green and blue channels using 8-bits per channel. The alpha channel is set to 1. Same format as BufferedImage.TYPE_3BYTE_BGR.

See Also:
Constant Field Values

L8

public static final int L8
Luminance using 8-bits. The red, green and blue channels are set to the luminance value. The alpha channel is set to 1.

See Also:
Constant Field Values

A8

public static final int A8
Alpha using 8-bits. The red, green and blue channels are set to 0.

See Also:
Constant Field Values

AL8

public static final int AL8
A single alpha-luminance value using 8-bits. The red, green, blue and alpha channels are set to the alpha-luminance value.

See Also:
Constant Field Values

ABGR_16F

public static final int ABGR_16F
Alpha, blue, green and red channels using 16-bit floats per channel.

See Also:
Constant Field Values

AL_32F

public static final int AL_32F
Alpha and luminance channels using 32-bit floats per channel.

See Also:
Constant Field Values

AL_64F

public static final int AL_64F
Alpha and luminance channels using 64-bit floats per channel.

See Also:
Constant Field Values
Method Detail

getInfo

public static Format.Info getInfo(int format)
Gets the information for the given format.


getPixelSize

public static int getPixelSize(int format)
Gets the number of bytes per pixel for the given format.