Class XYZSet
java.lang.Object
|
+----XYZSet
- public class XYZSet
- extends Object
This class implements conversions between RGB, CIE XYZ and CIELAB color
spaces.
-
aa
-
-
b
-
-
bb
-
-
bf
-
-
g
-
-
gf
-
-
L
-
-
Px
- x color matching function tabulated at 20-nm intervals.
-
Py
- y color matching function tabulated at 20-nm intervals.
-
Pz
- z color matching function tabulated at 20-nm intervals.
-
r
-
-
rf
-
-
X
-
-
Y
-
-
Z
-
-
XYZSet()
- Constructs a converter with no arguments.
-
XYZSet(RGBCoord)
- Constructs a converter with an argument.
-
convertFromRGB(RGBCoord)
- Converts from RGB to XYZ and LAB.
-
LABtoXYZ()
- Converts from LAB to XYZ internally.
-
LABtoXYZ(float, float)
- Converts from LAB to XYZ.
-
RGBtoXYZ(RGBCoord)
- Converts from RGB to XYZ.
-
spectrumToXYZ(float[])
- Computes XYZ coordinates for a spectrum.
-
XYZtoLAB()
- Converts from XYZ to LAB internally.
-
XYZtoRGB()
- Converts from XYZ to RGB internally.
-
XYZtoRGB(RGBCoord)
- Converts from XYZ to RGB.
L
float L
aa
float aa
bb
float bb
X
float X
Y
float Y
Z
float Z
r
int r
g
int g
b
int b
rf
float rf
gf
float gf
bf
float bf
Px
static float Px[]
- x color matching function tabulated at 20-nm intervals.
(10-degree 1964 CIE suppl. std. observer)
Py
static float Py[]
- y color matching function tabulated at 20-nm intervals.
(10-degree 1964 CIE suppl. std. observer)
Pz
static float Pz[]
- z color matching function tabulated at 20-nm intervals.
(10-degree 1964 CIE suppl. std. observer)
XYZSet
public XYZSet()
- Constructs a converter with no arguments.
XYZSet
public XYZSet(RGBCoord rgb)
- Constructs a converter with an argument.
- Parameters:
- rgb - RGB components that are used to
compute initial XYZ and LAB values.
- See Also:
- RGBCoord
convertFromRGB
public void convertFromRGB(RGBCoord rgb)
- Converts from RGB to XYZ and LAB.
- Parameters:
- rgb - RGB components to convert from.
- See Also:
- RGBCoord
spectrumToXYZ
public void spectrumToXYZ(float data[])
- Computes XYZ coordinates for a spectrum.
- Parameters:
- data[] - an array of 16 spectrum data points.
XYZtoRGB
public int XYZtoRGB()
- Converts from XYZ to RGB internally.
- Returns:
- 24-bit RGB color if conversion successful; 0 otherwise
XYZtoRGB
public void XYZtoRGB(RGBCoord rgb)
- Converts from XYZ to RGB.
- Parameters:
- rgb - RGBCoord object to set with converted values.
RGBtoXYZ
public void RGBtoXYZ(RGBCoord rgb)
- Converts from RGB to XYZ.
- Parameters:
- rgb - input RGB values.
LABtoXYZ
public void LABtoXYZ()
- Converts from LAB to XYZ internally.
LABtoXYZ
public void LABtoXYZ(float a,
float b)
- Converts from LAB to XYZ. Uses internal L-value.
- Parameters:
- a - the a-value
- b - the b-value
XYZtoLAB
public void XYZtoLAB()
- Converts from XYZ to LAB internally.