Hunter Lab (1966)
Follows the same theory of CIE’s Lab, but
is calculated from square roots of XYZ.
The main difference between the two is that besides the fact that none
are ideally uniform, Hunter’s Lab contracts the yellow
region of the cube and over-expands the blue region.
XYZ
The XYZ color system, also called “norm
color system”. It is superset of the RGB
color system. It uses tristimulus values
when encoding. X, Y and Z are all
calculated through color-matching functions and are always positive. It was a system created by CIE. The conversion is obtained through a matrix
operation after a simple adjustment of R, G and B:
[r’ g’ b’] = [X Y Z] [M]-1
Implementation:
void XYZtoHunterLab(double x, double y,
double z, double* L, double* a, double* b)
{
*L = 10 * sqrt( y );
*a = 17.5 * ( ( (
1.02 * x ) - y ) / sqrt( y ) );
*b = 7 * ( ( y - (
0.847 * z ) ) / sqrt( y ) );
}