public class CMYKColorSpace
extends 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 and Description |
---|
CMYKColorSpace()
create a new CMYK color space: a ColorSpace with 4 components
|
Modifier and Type | Method and Description |
---|---|
float[] |
fromCIEXYZ(float[] colorvalue)
Convert from CIEXYZ to RGB.
|
float[] |
fromRGB(float[] rgbvalue)
Convert from RGB to CMYK.
|
java.lang.String |
getName(int idx)
the name of this color space
|
int |
getNumComponents()
the number of components
|
int |
getType()
the type of this color space (TYPE_CMYK)
|
float[] |
toCIEXYZ(float[] colorvalue)
Convert from CMYK to CIEXYZ.
|
float[] |
toRGB(float[] colorvalue)
Convert from CMYK to RGB.
|
public CMYKColorSpace()
public float[] fromCIEXYZ(float[] colorvalue)
fromCIEXYZ
in class java.awt.color.ColorSpace
public float[] fromRGB(float[] rgbvalue)
fromRGB
in class java.awt.color.ColorSpace
rgbvalue
- the red, green, and blue values (0-1)public int getNumComponents()
getNumComponents
in class java.awt.color.ColorSpace
public java.lang.String getName(int idx)
getName
in class java.awt.color.ColorSpace
public int getType()
getType
in class java.awt.color.ColorSpace
public float[] toCIEXYZ(float[] colorvalue)
toCIEXYZ
in class java.awt.color.ColorSpace
public float[] toRGB(float[] colorvalue)
toRGB
in class java.awt.color.ColorSpace
colorvalue
- the CMYK values (0-1)