[Lcms-user] How to transform across profiles with different whitepoints?
An ICC-based CMM for color management
Brought to you by:
mm2
|
From: Lukas S. <som...@gm...> - 2025-10-27 12:31:51
|
Hello!
I've a question about correct treatment of profiles with different
whitepoints.
Consider the following code:
///////////////////////////////////////////////////////////////////////////
cmsHPROFILE srgbProfileHandle = cmsCreate_sRGBProfile(); // D65?
cmsHPROFILE cielabProfileHandle = cmsCreateLab4Profile(
// nullptr means: Default white point (D50)
// TODO Does this make sense? sRGB, for example, has
// D65 as whitepoint…
nullptr);
auto m_transform = cmsCreateTransform(
cielabProfileHandle, // input profile handle
TYPE_Lab_DBL, // input buffer format
rgbProfileHandle, // output profile handle
TYPE_RGB_DBL, // output buffer format
INTENT_ABSOLUTE_COLORIMETRIC, // rendering intent
cmsFLAGS_NOCACHE // flags
);
///////////////////////////////////////////////////////////////////////////
Now, I suppose srgbProfileHandle is D65 and cielabProfileHandle is D50?
Is it allowed to create simply the transform like in the example, and to
rely on LCMS to do the conversion? Or do I have to make a white point
adaption before?
Best regards
Lukas
|