[Lcms-user] First experiments with LCMS2
An ICC-based CMM for color management
Brought to you by:
mm2
From: Maurice L. <mau...@gm...> - 2019-10-02 19:59:51
|
Hi, I'm new to LittleCMS2 and I'm impressed. But my first test did reveal two issues. I used linkicc to create a CMYK input profile as follows: linkicc -o DevLink2PSOcoated_v3.icc -t1 -n17 -x -r2.4 DevLink.icc PSOcoated_v3.icc The DevLink2PSOcoated_v3.icc profile is a CMYK to CMYK ICC version-2 DeviceLink profile (which maps CMYK (0, 0, 0, 0) to CMYK (0, 0, 0, 0)) and the PSOcoated_v3.icc profile is a CMYK to Lab ICC version-2 Printer profile (Fogra-51). When looking at the resulting input profile in ICC Profile Inspector I see that the resulting profile is a version-2.4 profile (as requested) with linear (out = in) input and output channels (consisting of 2 points each, 0 and 65535), which is fine. But the value of the first CLUT entry (for CMYK = (0, 0, 0, 0)) is equal to (65535, 32896, 32896), which is the version-4 encoding for Lab (100, 0, 0). It should have been (65280, 32768, 32768) which is the version-2 encoding for Lab = (100, 0, 0). The reason for this is that FixWhiteMisalignment() in cmsopt.c "fixes" the first value in the CLUT from its correct version-2 encoded Lab value to the version-4 encoded Lab value, which it got from _cmsEndPointsBySpace() for the output Lab color space. This is clearly not the intended behavior. Another issue with the resulting input profile is that the mediaWhitePointTag is set to the D50 white point instead of to the white point of the PSOcoated_v3.icc profile. This is because cmsCreateExtendedTransform() sets the EntryWhitePoint of the transform to the white point of the first profile in the chain of profiles (but since a DeviceLink profile does't have a white point tag, it is set to the D50 white point). Then, since we are creating an input profile, cmsTransform2DeviceLink() sets the mediaWhitePointTag of the profile to the EntryWhitePoint. I understand that, in general, choosing the correct mediaWhitePoint for the resulting input profile is non-trivial. But it would be nice if the simpler cases, like the one presented here, could be handled correctly. With kind regards, Maurice |