| Modifier and Type | Field and Description |
|---|---|
| private PDColorSpace | |
| private ICC_ColorSpace | |
| private ICC_Profile | |
| private PDColor | |
| private boolean | |
| private static final Log | |
| private int | |
| private final PDStream | |
| private boolean |
| Access | Constructor and Description |
|---|---|
| public | PDICCBased(PDDocument
the document to store the ICC data doc)Creates a new ICC color space with an empty stream. |
| private | PDICCBased(COSArray
the ICC stream object. iccArray)Creates a new ICC color space using the PDF array. |
| Modifier and Type | Method and Description |
|---|---|
| private static void | |
| private float[] | |
| public static PDICCBased | Returns: an ICC color space.the ICC stream object. iccArray, PDResources resources to use as cache, or null for no caching. resources)Creates a new ICC color space using the PDF array, optionally using a resource cache. |
| private static ICC_Profile | |
| private void | |
| public PDColorSpace | Returns: A list of alternateColorSpace color spaces.Returns a list of alternate color spaces for non-conforming readers. |
| public int | Returns: an ICC color space type. SeeColorSpace#getType() and the static values of
ColorSpace for more details.Returns the type of the color space in the ICC profile. |
| public float[] | getDefaultDecode(int
the number of bits per component. bitsPerComponent)Implements abstract org. Returns the default decode array for this color space. |
| public PDColor | getInitialColor()
Implements abstract org. Returns the initial color value for this color space. |
| public COSStream | Returns: the metadata stream, or null if there is noneReturns the metadata stream for this object, or null if there is no metadata stream. |
| public String | getName()
Implements abstract org. Returns the name of the color space. |
| public int | getNumberOfComponents()
Implements abstract org. Returns the number of components in this color space |
| public PDStream | |
| public PDRange | Returns: the range for this componentthe component number to get the range for n)Returns the range for a certain component number. |
| private static void | |
| private boolean | |
| pack-priv boolean | |
| private void | |
| public void | setAlternateColorSpaces(List<PDColorSpace>
the list of color space objects list)Sets the list of alternateColorSpace color spaces. |
| public void | setMetadata(COSStream
the new metadata stream metadata)Sets the metadata stream that is associated with this color space. |
| public void | setRangeForComponent(PDRange
the new range for the a component range, int the component to set the range for n)Sets the range for this color space. |
| public BufferedImage | toRawImage(WritableRaster
the source raster raster)Overrides org. Returns the image in this colorspace or null. |
| public float[] | toRGB(float[]
a color value with component values between 0 and 1 value)Implements abstract org. Returns the RGB equivalent of the given color value. |
| public BufferedImage | toRGBImage(WritableRaster
the source raster raster)Overrides org. Returns the (A)RGB equivalent of the given raster. |
| public String | toString()
Overrides org. Returns a string representation of the object. |
| alternateColorSpace | back to summary |
|---|---|
| private PDColorSpace alternateColorSpace | |
| awtColorSpace | back to summary |
|---|---|
| private ICC_ColorSpace awtColorSpace | |
| iccProfile | back to summary |
|---|---|
| private ICC_Profile iccProfile | |
| initialColor | back to summary |
|---|---|
| private PDColor initialColor | |
| isRGB | back to summary |
|---|---|
| private boolean isRGB | |
| LOG | back to summary |
|---|---|
| private static final Log LOG | |
| numberOfComponents | back to summary |
|---|---|
| private int numberOfComponents | |
| stream | back to summary |
|---|---|
| private final PDStream stream | |
| useOnlyAlternateColorSpace | back to summary |
|---|---|
| private boolean useOnlyAlternateColorSpace | |
| PDICCBased | back to summary |
|---|---|
| public PDICCBased(PDDocument doc) Creates a new ICC color space with an empty stream.
| |
| PDICCBased | back to summary |
|---|---|
| private PDICCBased(COSArray iccArray) throws IOException Creates a new ICC color space using the PDF array.
| |
| checkArray | back to summary |
|---|---|
| private static void checkArray(COSArray iccArray) throws IOException | |
| clampColors | back to summary |
|---|---|
| private float[] clampColors(ICC_ColorSpace cs, float[] value) | |
| create | back to summary |
|---|---|
| public static PDICCBased create(COSArray iccArray, PDResources resources) throws IOException Creates a new ICC color space using the PDF array, optionally using a resource cache.
| |
| ensureDisplayProfile | back to summary |
|---|---|
| private static ICC_Profile ensureDisplayProfile(ICC_Profile profile) | |
| fallbackToAlternateColorSpace | back to summary |
|---|---|
| private void fallbackToAlternateColorSpace(Exception e) throws IOException | |
| getAlternateColorSpace | back to summary |
|---|---|
| public PDColorSpace getAlternateColorSpace() throws IOException Returns a list of alternate color spaces for non-conforming readers. Warning Do not use the information in a conforming reader.
| |
| getColorSpaceType | back to summary |
|---|---|
| public int getColorSpaceType() Returns the type of the color space in the ICC profile. If the ICC profile is invalid, the
type of the alternate colorspace is returned, which will be one of
| |
| getDefaultDecode | back to summary |
|---|---|
| public float[] getDefaultDecode(int bitsPerComponent) Implements abstract org. Doc from org. Returns the default decode array for this color space.
| |
| getInitialColor | back to summary |
|---|---|
| public PDColor getInitialColor() Implements abstract org. Doc from org. Returns the initial color value for this color space. | |
| getMetadata | back to summary |
|---|---|
| public COSStream getMetadata() Returns the metadata stream for this object, or null if there is no metadata stream.
| |
| getName | back to summary |
|---|---|
| public String getName() Implements abstract org. Doc from org. Returns the name of the color space. | |
| getNumberOfComponents | back to summary |
|---|---|
| public int getNumberOfComponents() Implements abstract org. Doc from org. Returns the number of components in this color space
| |
| getPDStream | back to summary |
|---|---|
| public PDStream getPDStream() Get the underlying ICC profile stream.
| |
| getRangeForComponent | back to summary |
|---|---|
| public PDRange getRangeForComponent(int n) Returns the range for a certain component number. This will never return null. If it is not present then the range 0..1 will be returned.
| |
| intToBigEndian | back to summary |
|---|---|
| private static void intToBigEndian(int value, byte[] array, int index) | |
| is_sRGB | back to summary |
|---|---|
| private boolean is_sRGB(ICC_Profile profile) Returns true if the given profile represents sRGB. (unreliable on the data of ColorSpace.CS_sRGB in openjdk) | |
| isSRGB | back to summary |
|---|---|
| pack-priv boolean isSRGB() Internal accessor to support indexed raw images.
| |
| loadICCProfile | back to summary |
|---|---|
| private void loadICCProfile() throws IOException Load the ICC profile, or init alternateColorSpace color space. | |
| setAlternateColorSpaces | back to summary |
|---|---|
| public void setAlternateColorSpaces(List<PDColorSpace> list) Sets the list of alternateColorSpace color spaces.
| |
| setMetadata | back to summary |
|---|---|
| public void setMetadata(COSStream metadata) Sets the metadata stream that is associated with this color space.
| |
| setRangeForComponent | back to summary |
|---|---|
| public void setRangeForComponent(PDRange range, int n) Sets the range for this color space.
| |
| toRawImage | back to summary |
|---|---|
| public BufferedImage toRawImage(WritableRaster raster) throws IOException Overrides org. Doc from org. Returns the image in this colorspace or null. No conversion is performed.
For special colorspaces like PDSeparation the image is returned in the gray colorspace. For undefined colorspaces
like DeviceCMYK/DeviceRGB and DeviceGray null is returned.
You can always fallback to
| |
| toRGB | back to summary |
|---|---|
| public float[] toRGB(float[] value) throws IOException Implements abstract org. Doc from org. Returns the RGB equivalent of the given color value.
| |
| toRGBImage | back to summary |
|---|---|
| public BufferedImage toRGBImage(WritableRaster raster) throws IOException Overrides org. Doc from org. Returns the (A)RGB equivalent of the given raster.
| |
| toString | back to summary |
|---|---|
| public String toString() Overrides org. Doc from java. Returns a string representation of the object.
Satisfying this method's contract implies a non- | |