lcms 2.0 writes floating point CLUTs incorrectly
An ICC-based CMM for color management
Brought to you by:
mm2
Type_LUTA2B_Write and Type_LUTB2A_Write call WriteCLUT with a precision of 2 because it only checks the Lut->SaveAs8Bits flag. WriteCLUT should be called with a precession of 4 which would cause an error "Unknow precision of '%d'". Right now it tries to write floats as 16-bits.
Also the error message needs to be fixed to "Unknown" instead of "Unknow".
Should it try to convert the CLUT to 16 or 8 bits based on the precision?
LutA2B and LubBToA only supports 8 and 16 bits, according the ICC spec. Floating point data can only be saved by using multiprofile elements.
But the CLUT code certainly misses a check on floating point data.
Fixed in git. Will be released on 2.1.