IndexedColorSpace

IndexedColorSpace

Overview

IndexedColorSpace is a class in Aspose.PDF FOSS for Java. Inherits from: ColorSpaceBase.

Indexed color space (ISO 32000-1:2008, §8.6.6.3).

This class provides 9 methods for working with IndexedColorSpace objects in Java programs. Available methods include: IndexedColorSpace, fromArray, getBase, getHival, getName, getNumberOfComponents, lookupColor, resolve, toRGBInt. All public members are accessible to any Java application after installing the Aspose.PDF FOSS for Java package. Properties: base, hival, name, numberOfComponents.

Properties

NameTypeAccessDescription
nameStringReadGets the name.
numberOfComponentsintReadGets the number of components.
baseColorSpaceBaseReadReturns the base color space.
hivalintReadReturns the maximum valid index.

Methods

SignatureDescription
IndexedColorSpace(base: ColorSpaceBase, hival: int, lookupTable: byte[])Creates an IndexedColorSpace.
fromArray(arr: PdfArray, resources: Resources, parser: PDFParser)IndexedColorSpaceCreates an IndexedColorSpace from a PdfArray: [/Indexed base hival lookup].
getName()StringReturns the name.
getNumberOfComponents()intReturns the number of components.
getBase()ColorSpaceBaseReturns the base color space.
getHival()intReturns the maximum valid index.
lookupColor(index: int)double[]Looks up a palette entry, returning the base color space components.
toRGBInt(comps: double[])intPalette index -> base components -> base space’s RGB.
resolve(csObj: PdfBase, resources: Resources, parser: PDFParser)ColorSpaceBase

See Also

 English