Class DeviceCMYKColorSpace
- java.lang.Object
-
- java.awt.color.ColorSpace
-
- org.apache.xmlgraphics.java2d.color.AbstractDeviceSpecificColorSpace
-
- org.apache.xmlgraphics.java2d.color.DeviceCMYKColorSpace
-
- All Implemented Interfaces:
java.io.Serializable
,ColorSpaceOrigin
public class DeviceCMYKColorSpace extends AbstractDeviceSpecificColorSpace implements ColorSpaceOrigin
This class represents an uncalibrated CMYK color space.- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
PSEUDO_PROFILE_NAME
The name for the uncalibrated CMYK pseudo-profileprivate static long
serialVersionUID
-
Fields inherited from class java.awt.color.ColorSpace
CS_CIEXYZ, CS_GRAY, CS_LINEAR_RGB, CS_PYCC, CS_sRGB, TYPE_2CLR, TYPE_3CLR, TYPE_4CLR, TYPE_5CLR, TYPE_6CLR, TYPE_7CLR, TYPE_8CLR, TYPE_9CLR, TYPE_ACLR, TYPE_BCLR, TYPE_CCLR, TYPE_CMY, TYPE_CMYK, TYPE_DCLR, TYPE_ECLR, TYPE_FCLR, TYPE_GRAY, TYPE_HLS, TYPE_HSV, TYPE_Lab, TYPE_Luv, TYPE_RGB, TYPE_XYZ, TYPE_YCbCr, TYPE_Yxy
-
-
Constructor Summary
Constructors Constructor Description DeviceCMYKColorSpace()
Constructs an uncalibrated CMYK ColorSpace object withColorSpace.TYPE_CMYK
and 4 components.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description static java.awt.Color
createCMYKColor(float[] cmykComponents)
Creates a color instance representing a device-specific CMYK color.float[]
fromCIEXYZ(float[] colorvalue)
float[]
fromRGB(float[] rgbvalue)
static DeviceCMYKColorSpace
getInstance()
Deprecated.UseColorSpaces.getDeviceCMYKColorSpace()
instead.java.lang.String
getProfileName()
Returns the name of the profile used to identify the color space in a particular context.java.lang.String
getProfileURI()
Returns the URI identifying the associate color profile.float[]
toCIEXYZ(float[] colorvalue)
float[]
toRGB(float[] colorvalue)
-
-
-
Field Detail
-
serialVersionUID
private static final long serialVersionUID
- See Also:
- Constant Field Values
-
PSEUDO_PROFILE_NAME
public static final java.lang.String PSEUDO_PROFILE_NAME
The name for the uncalibrated CMYK pseudo-profile- See Also:
- Constant Field Values
-
-
Method Detail
-
getInstance
@Deprecated public static DeviceCMYKColorSpace getInstance()
Deprecated.UseColorSpaces.getDeviceCMYKColorSpace()
instead.Returns an instance of an uncalibrated CMYK color space.- Returns:
- CMYKColorSpace the requested color space object
-
toRGB
public float[] toRGB(float[] colorvalue)
- Specified by:
toRGB
in classjava.awt.color.ColorSpace
-
fromRGB
public float[] fromRGB(float[] rgbvalue)
- Specified by:
fromRGB
in classjava.awt.color.ColorSpace
-
toCIEXYZ
public float[] toCIEXYZ(float[] colorvalue)
- Specified by:
toCIEXYZ
in classjava.awt.color.ColorSpace
-
fromCIEXYZ
public float[] fromCIEXYZ(float[] colorvalue)
- Specified by:
fromCIEXYZ
in classjava.awt.color.ColorSpace
-
createCMYKColor
public static java.awt.Color createCMYKColor(float[] cmykComponents)
Creates a color instance representing a device-specific CMYK color. An sRGB value is calculated from the CMYK colors but it may not correctly represent the given CMYK values.- Parameters:
cmykComponents
- the CMYK components- Returns:
- the device-specific color
-
getProfileName
public java.lang.String getProfileName()
Returns the name of the profile used to identify the color space in a particular context.- Specified by:
getProfileName
in interfaceColorSpaceOrigin
- Returns:
- the profile name
-
getProfileURI
public java.lang.String getProfileURI()
Returns the URI identifying the associate color profile.- Specified by:
getProfileURI
in interfaceColorSpaceOrigin
- Returns:
- the profile URI
-
-