java.lang.Object
java.awt.image.LookupTable
cgsuite.plugin.ScaleLookupTable
- class ScaleLookupTable
- extends java.awt.image.LookupTable
A lookup-table implementation that simply scales the input based on
the colour specified in the constructor. You get the same scaled
(r+g+b) but a new colour.
- Version:
- 1.0
|
Method Summary |
int[] |
lookupPixel(int[] src,
int[] dest)
Return translated values for a pixel. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
colour
private java.awt.Color colour
ScaleLookupTable
public ScaleLookupTable(java.awt.Color c)
lookupPixel
public int[] lookupPixel(int[] src,
int[] dest)
- Description copied from class:
java.awt.image.LookupTable
- Return translated values for a pixel.
For each value in the pixel src, use the value minus offset as an index
in the component array and copy the value there to the output for the
component. If dest is null, the output is a new array, otherwise the
translated values are written to dest. Dest can be the same array as
src.
For example, if the pixel src is [2, 4, 3], and offset is 1, the output
is [comp1[1], comp2[3], comp3[2]], where comp1, comp2, and comp3 are the
translation arrays.