Top Description Fields Constructors Methods
org.apache.pdfbox.pdmodel.graphics.color

public abstract Class PDCIEDictionaryBasedColorSpace

extends PDCIEBasedColorSpace
Class Inheritance
Known Direct Subclasses
org.apache.pdfbox.pdmodel.graphics.color.PDLab, org.apache.pdfbox.pdmodel.graphics.color.PDCalGray, org.apache.pdfbox.pdmodel.graphics.color.PDCalRGB
Imports
java.awt.color.ColorSpace, org.apache.pdfbox.cos.COSArray, .COSDictionary, .COSFloat, .COSName

CIE-based colour spaces that use a dictionary.
Authors
Ben Litchfield, John Hewson

Field Summary

Modifier and TypeField and Description
private static final ColorSpace
protected final COSDictionary
protected float
protected float
protected float

Constructor Summary

AccessConstructor and Description
protected
protected
PDCIEDictionaryBasedColorSpace(COSArray
the cos array which represents this color space
rgb
)

Creates a new CalRGB color space using the given COS array.

Method Summary

Modifier and TypeMethod and Description
protected float[]
convXYZtoRGB(float x, float y, float z)

private void
public final PDTristimulus

Returns:

the blackpoint tristimulus
getBlackPoint
()

This will return the BlackPoint tristimulus.

public final PDTristimulus

Returns:

the whitepoint tristimulus
getWhitepoint
()

This will return the whitepoint tristimulus.

protected boolean

Returns:

true if the current point is the white point.
isWhitePoint
()

Tests if the current point is the white point.

public void
setBlackPoint(PDTristimulus
the BlackPoint tristimulus
blackpoint
)

This will set the BlackPoint tristimulus.

public void
setWhitePoint(PDTristimulus
the whitepoint tristimulus.
whitepoint
)

This will set the whitepoint tristimulus.

Inherited from org.apache.pdfbox.pdmodel.graphics.color.PDCIEBasedColorSpace:
toRawImagetoRGBImagetoString

Field Detail

CIEXYZback to summary
private static final ColorSpace CIEXYZ
dictionaryback to summary
protected final COSDictionary dictionary
wpXback to summary
protected float wpX
wpYback to summary
protected float wpY
wpZback to summary
protected float wpZ

Constructor Detail

PDCIEDictionaryBasedColorSpaceback to summary
protected PDCIEDictionaryBasedColorSpace(COSName cosName)
PDCIEDictionaryBasedColorSpaceback to summary
protected PDCIEDictionaryBasedColorSpace(COSArray rgb)

Creates a new CalRGB color space using the given COS array.

Parameters
rgb:COSArray

the cos array which represents this color space

Method Detail

convXYZtoRGBback to summary
protected float[] convXYZtoRGB(float x, float y, float z)
fillWhitepointCacheback to summary
private void fillWhitepointCache(PDTristimulus whitepoint)
getBlackPointback to summary
public final PDTristimulus getBlackPoint()

This will return the BlackPoint tristimulus. This is an optional field but has defaults so this will never return null. A default of 0,0,0 will be returned if the pdf does not have any values yet.

Returns:PDTristimulus

the blackpoint tristimulus

getWhitepointback to summary
public final PDTristimulus getWhitepoint()

This will return the whitepoint tristimulus. As this is a required field this will never return null. A default of 1,1,1 will be returned if the pdf does not have any values yet.

Returns:PDTristimulus

the whitepoint tristimulus

isWhitePointback to summary
protected boolean isWhitePoint()

Tests if the current point is the white point.

Returns:boolean

true if the current point is the white point.

setBlackPointback to summary
public void setBlackPoint(PDTristimulus blackpoint)

This will set the BlackPoint tristimulus.

Parameters
blackpoint:PDTristimulus

the BlackPoint tristimulus

setWhitePointback to summary
public void setWhitePoint(PDTristimulus whitepoint)

This will set the whitepoint tristimulus. As this is a required field, null should not be passed into this function.

Parameters
whitepoint:PDTristimulus

the whitepoint tristimulus.

Exceptions
IllegalArgumentException:
if null is passed as argument.