Conversions and data for color spaces. Demo.
var space = ;//convert lab to lchvar result = spacelab;
You can require a separate space to reduce size significantly:
var rgb = ;var hsl = ;//convert rgb to hslrgb;
<fromSpace><toSpace>array;<space>name //space name<space>min //channel minimums<space>max //channel maximums<space>channel //channel names<space>alias //alias space names
Please fork, add color space with basic conversions to/from XYZ or RGB and tests. The goal of project is to provide the most complete set of color spaces with maximally minimal uniform API.
Thanks to all the color scientists, who devoted their lives to color research and delivered their knowledge to us, for now we can trust them and use their formulas and their code.