COSObjectable
public class PDSeparation extends PDSpecialColorSpace
array
Constructor | Description |
---|---|
PDSeparation() |
Creates a new Separation color space.
|
PDSeparation(COSArray separation) |
Creates a new Separation color space from a PDF color space array.
|
Modifier and Type | Method | Description |
---|---|---|
PDColorSpace |
getAlternateColorSpace() |
Returns the colorant name.
|
java.lang.String |
getColorantName() |
Returns the colorant name.
|
float[] |
getDefaultDecode(int bitsPerComponent) |
Returns the default decode array for this color space.
|
PDColor |
getInitialColor() |
Returns the initial color value for this color space.
|
java.lang.String |
getName() |
Returns the name of the color space.
|
int |
getNumberOfComponents() |
Returns the number of components in this color space
|
void |
setAlternateColorSpace(PDColorSpace colorSpace) |
Sets the alternate color space.
|
void |
setColorantName(java.lang.String name) |
Sets the colorant name.
|
void |
setTintTransform(PDFunction tint) |
Sets the tint transform function.
|
protected void |
tintTransform(float[] samples,
int[] alt) |
|
float[] |
toRGB(float[] value) |
Returns the RGB equivalent of the given color value.
|
java.awt.image.BufferedImage |
toRGBImage(java.awt.image.WritableRaster raster) |
Returns the (A)RGB equivalent of the given raster.
|
java.lang.String |
toString() |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
create, create, create, toRGBImageAWT
getCOSObject
public PDSeparation()
public PDSeparation(COSArray separation) throws java.io.IOException
separation
- an array containing all separation information.java.io.IOException
- if the color space or the function could not be created.public java.lang.String getName()
PDColorSpace
getName
in class PDColorSpace
public int getNumberOfComponents()
PDColorSpace
getNumberOfComponents
in class PDColorSpace
public float[] getDefaultDecode(int bitsPerComponent)
PDColorSpace
getDefaultDecode
in class PDColorSpace
bitsPerComponent
- the number of bits per component.public PDColor getInitialColor()
PDColorSpace
getInitialColor
in class PDColorSpace
public float[] toRGB(float[] value) throws java.io.IOException
PDColorSpace
toRGB
in class PDColorSpace
value
- a color value with component values between 0 and 1java.io.IOException
- if the color conversion failspublic java.awt.image.BufferedImage toRGBImage(java.awt.image.WritableRaster raster) throws java.io.IOException
PDColorSpace
toRGBImage
in class PDColorSpace
raster
- the source rasterjava.io.IOException
- if the color conversion failsprotected void tintTransform(float[] samples, int[] alt) throws java.io.IOException
java.io.IOException
public PDColorSpace getAlternateColorSpace()
public java.lang.String getColorantName()
public void setColorantName(java.lang.String name)
name
- the name of the colorantpublic void setAlternateColorSpace(PDColorSpace colorSpace)
colorSpace
- The alternate color space.public void setTintTransform(PDFunction tint)
tint
- the tint transform functionpublic java.lang.String toString()
toString
in class java.lang.Object
Copyright © 2002–2018. All rights reserved.