public class IndexedColorSpace extends ColorSpace
Commonly, an image with an indexed color space can be one third the size of the same image with a standard color space, because the indexed image uses a smaller palette of colors.
DEVICE_CMYK, DEVICE_GRAY, DEVICE_RGB, DEVICE_RGBA, LAB, LAB_A| Constructor and Description |
|---|
IndexedColorSpace(ColorSpace base,
int hival,
java.util.List<java.lang.Integer> lookup)
Create a Indexed color space.
|
| Modifier and Type | Method and Description |
|---|---|
void |
delete() |
ColorSpace |
getBase()
The base color space in which the values in the color table are to be interpreted.
|
int |
getHiVal()
an integer that specifies the maximum valid index value.
|
java.util.List<java.lang.Integer> |
getLookup()
A list of integers in the range 0..255.
|
equals, getName, getNumComponents, getPDFObject, toStringpublic IndexedColorSpace(ColorSpace base, int hival, java.util.List<java.lang.Integer> lookup)
base - The base color space in which the values in the color table are to be interpreted. It can be any device or CIE-based color space or (in PDF 1.3) a Separation or DeviceN space, but not a Pattern space or another Indexed space.hival - an integer that specifies the maximum valid index value. In other words, the color table is to be indexed by integers in the range 0 to hival. hival can be no greater than 255.lookup - a list of integers in the range 0..255. There must be m * (hival + 1) values, where m is the number of components of the base color space.public void delete()
delete in class ColorSpacepublic ColorSpace getBase()
public int getHiVal()
public java.util.List<java.lang.Integer> getLookup()