Quick math questions

Whenever I look into changing illuminants or colorspaces of an image my head explodes because the tutorials out there aren’t as straightforward as I hope. In particular, I am interested in how we arrive at these matrices and would like an easy to follow step by step explanation so that I can make more.

From https://github.com/Beep6581/RawTherapee/blob/dev/rtengine/iccmatrices.h; e.g., how do we get to this?

constexpr double xyz_rec2020[3][3] = {
    {0.6734241,  0.1656411,  0.1251286},
    {0.2790177,  0.6753402,  0.0456377},
    { -0.0019300,  0.0299784, 0.7973330}
};

PS Future: once clarified, I or someone could make G’MIC more capable in this area.

1 Like