Hi Florian,

You are right. It seems I did a mistake when fixing a previous bug
in the absolute colorimetric intent. I have uploaded to GIT repository 
a fix, but I'm still testing, as I'm not 100% sure this code covers 
properly all the cases. 

Thanks for reporting
Best regards
Marti

Original Message:
-----------------
From: Florian Höch lists+lcms-u...@hoech.org
Date: Sun, 07 Aug 2011 15:53:33 +0200
To: lcms-user@lists.sourceforge.net
Subject: [Lcms-user] LCMS 2.2: Possible bug
incmsvirt.c/cmsCreateRGBProfileTHR, 'chad' converts from PCS to device


Hi,

I think there may be a bug in cmsvirt.c/cmsCreateRGBProfileTHR, in the 
call to _cmsAdaptationMatrix, which causes the 'chad' matrix from 
resulting profiles to convert from PCS to device instead of the other 
way around.

(From the ICC spec)
"This tag, which must be invertible, converts an XYZ colour, measured at 
a device's specific illumination conditions, to an XYZ colour in the PCS 
illumination conditions after complete adaptation."

So, the inverted matrix should do the opposite.

This is not the case with the profile I looked at. When I multiply the 
inverted matrix with D50 XYZ numbers, which should yield the device 
illuminant (CCT around 6460K), I get a far too 'warm' result (CCT around 
4408K). Not inverting the matrix yields the correct values.

I think the FromIll/ToIll arguments to _cmsAdaptationMatrix are simply 
reversed.

_cmsAdaptationMatrix(&CHAD, NULL, cmsD50_XYZ(), &WhitePointXYZ);

should probably be:

_cmsAdaptationMatrix(&CHAD, NULL, &WhitePointXYZ, cmsD50_XYZ());

Regards
-- 
Florian Höch


----------------------------------------------------------------------------
--
BlackBerry® DevCon Americas, Oct. 18-20, San Francisco, CA
The must-attend event for mobile developers. Connect with experts. 
Get tools for creating Super Apps. See the latest technologies.
Sessions, hands-on labs, demos & much more. Register early & save!
http://p.sf.net/sfu/rim-blackberry-1
_______________________________________________
Lcms-user mailing list
Lcms-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/lcms-user


--------------------------------------------------------------------
mail2web LIVE – Free email based on Microsoft® Exchange technology -
http://link.mail2web.com/LIVE



------------------------------------------------------------------------------
BlackBerry® DevCon Americas, Oct. 18-20, San Francisco, CA
The must-attend event for mobile developers. Connect with experts. 
Get tools for creating Super Apps. See the latest technologies.
Sessions, hands-on labs, demos & much more. Register early & save!
http://p.sf.net/sfu/rim-blackberry-1
_______________________________________________
Lcms-user mailing list
Lcms-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/lcms-user

Reply via email to