IndexedColorSpace Class Documentation
classIndexedColorSpace : ColorSpaceNamespace:com::datalogics::PDFL
- Inherits from:
ColorSpace
Detailed Description
Indexed color spaces are used to reduce the amount of memory used for processing images. Indexed color spaces are used when a limited number of colors are needed.
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.
Uses types
Constructor & Destructor Documentation
IndexedColorSpace
IndexedColorSpace(ColorSpacebase, inthival, java.util.List< Integer >lookup)Parameters
base: ColorSpaceThe 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: intan 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: java.util.List< Integer >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.
Create a Indexed color space.
Member Function Documentation
DLIntern
static ColorSpaceDLIntern(ColorSpacecs)Parameters
cs: ColorSpace
Returns:
ColorSpaceDisposeChildren
voidDisposeChildren()Returns:
void[static initializer]
static void[static initializer]()delete
synchronized voiddelete(Booleandisposing)Parameters
disposing: Boolean
Returns:
synchronized voiddelete
synchronized voiddelete()Returns:
synchronized voidequals
booleanequals(Objectrhs)Parameters
rhs: Object
Returns:
booleanfinalize
voidfinalize()Returns:
voidgetBase
ColorSpacegetBase()Returns:
ColorSpaceThe 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.
getHiVal
intgetHiVal()Returns:
intan 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.
getLookup
java.util.List< Integer >getLookup()Returns:
java.util.List< Integer >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.
getName
StringgetName()Returns:
StringThe name of the color space. A named color space may be named something like DeviceRGB. More complicated color spaces may have a name like Indexed or ICCBased.
getNumComponents
intgetNumComponents()Returns:
intThe number of components in the color space.
getPDFObject
PDFObjectgetPDFObject()Returns:
The PDFObject associated with the color space.Get the PDFObject associated with the color space. This may be a PDFName, PDFDict, PDFStream, or PDFArray.
sameTypeEquals
booleansameTypeEquals(ColorSpaceother)Parameters
other: ColorSpace
Returns:
booleantoString
StringtoString()Returns:
StringConvert a colorSpace to a string.