| Modifier and Type | Field and Description |
|---|---|
| private final ByteBuffer | |
| private final int | |
| private static final int | BITS_TO_BYTES
The arithmetic right shift value to convert a bit depth to a byte depth. |
| private final int | |
| private final int | |
| private ByteBuffer | |
| private Buffer | |
| private final PlatformLogger | |
| private final int |
| Access | Constructor and Description |
|---|---|
| pack-priv | FramebufferY8(ByteBuffer
the 32-bit composition buffer bb, int the width of the composition buffer in pixels width, int the height of the composition buffer in pixels height, int the color depth of the target channel or buffer in bits per
pixel depth, boolean true to clear the composition buffer on the first
upload of each frame unless that upload already overwrites the entire
buffer; otherwise falseCreates a new |
| Modifier and Type | Method and Description |
|---|---|
| private void | copyNextPixel(IntBuffer
the source integer buffer in ARGB32 format source, ByteBuffer the target byte buffer in Y8 format target)Copies the next 32-bit ARGB32 pixel to a byte buffer with 8-bit Y8 pixels. |
| private void | copyNextPixel(IntBuffer
the source integer buffer in ARGB32 format source, ShortBuffer the target short buffer in RGB565 format target)Copies the next 32-bit ARGB32 pixel to a short buffer with 16-bit RGB565 pixels. |
| pack-priv void | copyToBuffer(ByteBuffer
the output buffer out)Overrides com. Copies the contents of the composition buffer to the output buffer, converting the pixel format as necessary. |
| public String | |
| pack-priv void | write(WritableByteChannel
the output channel out)Overrides com. Writes the contents of the composition buffer to the output channel, converting the pixel format as necessary. |
| bb | back to summary |
|---|---|
| private final ByteBuffer bb | |
| bitDepth | back to summary |
|---|---|
| private final int bitDepth | |
| BITS_TO_BYTES | back to summary |
|---|---|
| private static final int BITS_TO_BYTES The arithmetic right shift value to convert a bit depth to a byte depth. | |
| byteDepth | back to summary |
|---|---|
| private final int byteDepth | |
| height | back to summary |
|---|---|
| private final int height | |
| lineByteBuffer | back to summary |
|---|---|
| private ByteBuffer lineByteBuffer | |
| linePixelBuffer | back to summary |
|---|---|
| private Buffer linePixelBuffer | |
| logger | back to summary |
|---|---|
| private final PlatformLogger logger | |
| width | back to summary |
|---|---|
| private final int width | |
| FramebufferY8 | back to summary |
|---|---|
| pack-priv FramebufferY8(ByteBuffer bb, int width, int height, int depth, boolean clear) Creates a new
| |
| copyNextPixel | back to summary |
|---|---|
| private void copyNextPixel(IntBuffer source, ByteBuffer target) Copies the next 32-bit ARGB32 pixel to a byte buffer with 8-bit Y8 pixels. Luma Y' can be calculated from gamma-corrected R'G'B' using the following coefficients. This method uses the coefficients from Rec. 709, which defines the same primaries and white point as the sRGB color space.
Implementation Note Java rounds toward zero when converting a
| |
| copyNextPixel | back to summary |
|---|---|
| private void copyNextPixel(IntBuffer source, ShortBuffer target) Copies the next 32-bit ARGB32 pixel to a short buffer with 16-bit RGB565 pixels. This method truncates the low-order bits of each color component.
| |
| copyToBuffer | back to summary |
|---|---|
| pack-priv void copyToBuffer(ByteBuffer out) Overrides com. Copies the contents of the composition buffer to the output buffer, converting the pixel format as necessary.
| |
| toString | back to summary |
|---|---|
| public String toString() Overrides java. Doc from java. Returns a string representation of the object.
Satisfying this method's contract implies a non- | |
| write | back to summary |
|---|---|
| pack-priv void write(WritableByteChannel out) throws IOException Overrides com. Writes the contents of the composition buffer to the output channel, converting the pixel format as necessary.
| |