public class ByteLookupTable extends LookupTable
| Constructor and Description |
|---|
ByteLookupTable(int offset,
byte[] data)
Creates a new
ByteLookupTable instance. |
ByteLookupTable(int offset,
byte[][] data)
Creates a new
ByteLookupTable instance. |
| Modifier and Type | Method and Description |
|---|---|
byte[][] |
getTable()
Return the lookup tables.
|
byte[] |
lookupPixel(byte[] src,
byte[] dst)
Return translated values for a pixel.
|
int[] |
lookupPixel(int[] src,
int[] dst)
Return translated values for a pixel.
|
getNumComponents, getOffsetpublic ByteLookupTable(int offset, byte[][] data) throws IllegalArgumentException
ByteLookupTable instance.
Offset is subtracted from pixel values when looking up in the translation
tables. If data.length is one, the same table is applied to all pixel
components.offset - Offset to be subtracted.data - Array of lookup tables (null not permitted).IllegalArgumentException - if offset < 0 or data.length < 1.public ByteLookupTable(int offset, byte[] data) throws IllegalArgumentException
ByteLookupTable instance.
Offset is subtracted from pixel values when looking up in the translation
table. The same table is applied to all pixel components.offset - Offset to be subtracted.data - Lookup table for all components (null not
permitted).IllegalArgumentException - if offset < 0.public final byte[][] getTable()
public int[] lookupPixel(int[] src, int[] dst) throws ArrayIndexOutOfBoundsException
lookupPixel in class LookupTablesrc - Component values of a pixel.dst - Destination array for values, or null.ArrayIndexOutOfBoundsExceptionpublic byte[] lookupPixel(byte[] src, byte[] dst) throws ArrayIndexOutOfBoundsException
src - Component values of a pixel.dst - Destination array for values, or null.ArrayIndexOutOfBoundsException