java.lang.Object
imagingbook.common.color.adapt.XYZscalingAdaptation
- All Implemented Interfaces:
ChromaticAdaptation
This class represents a linear chromatic adaptation transform, mapping XYZ color coordinates from a source white
(reference) point to a target white point. Both white points are passed to the constructor. The actual color mapping
is done by method applyTo(float[]). See the Section 14.6 of [1] for additional details and examples.
[1] W. Burger, M.J. Burge, Digital Image Processing – An Algorithmic Introduction, 3rd ed, Springer (2022).
- Version:
- 2022/11/14
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptiondouble[]applyTo(double[] XYZ1) Double version ofChromaticAdaptation.applyTo(float[]).float[]applyTo(float[] XYZ1) Transforms the specified XYZ source color coordinates to target coordinates.static XYZscalingAdaptationgetInstance(double[] W1, double[] W2) Returns aXYZscalingAdaptationinstance for the specified white point coordinates.static XYZscalingAdaptationgetInstance(Illuminant illum1, Illuminant illum2) Returns aXYZscalingAdaptationinstance for the specified illuminants (white points).Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface imagingbook.common.color.adapt.ChromaticAdaptation
applyTo
-
Method Details
-
getInstance
Returns aXYZscalingAdaptationinstance for the specified white point coordinates.- Parameters:
W1- source white point (to map from)W2- target white point (to map to)- Returns:
- a
XYZscalingAdaptationinstance
-
getInstance
Returns aXYZscalingAdaptationinstance for the specified illuminants (white points).- Parameters:
illum1- source illuminant (white point to map from)illum2- target illuminant (white point to map to)- Returns:
- a
XYZscalingAdaptationinstance
-
applyTo
Description copied from interface:ChromaticAdaptationTransforms the specified XYZ source color coordinates to target coordinates. The specified color coordinates are interpreted relative to (source) white point (W1). Returns a new color adapted to (target) white point W2.- Specified by:
applyToin interfaceChromaticAdaptation- Parameters:
XYZ1- the original color point w.r.t. the source white point (W1)- Returns:
- the adapted color w.r.t. the target white point (W2).
-
applyTo
Description copied from interface:ChromaticAdaptationDouble version ofChromaticAdaptation.applyTo(float[]).- Specified by:
applyToin interfaceChromaticAdaptation- Parameters:
XYZ1- the original color point w.r.t. the source white point (W1)- Returns:
- the adapted color w.r.t. the target white point (W2).
-