Skip to content

color-lcms: make blend-to-output transformations like all others

Pekka Paalanen requested to merge pq/weston:mr/curveprofiles into main

Blend-to-output color transformations were hardcoded as 3x1D LUTs. That hardcoding is in the way of making use of better curve types in the future.

This MR removes that special-case hardcoding, and pushes blend-to-output transformation chains through the same mechanisms and optimizations as all other color transformation categories. On the way towards that goal:

  • Start with some cleaning up on rendering intent handling, without changing behavior.
  • Some code comments are fixed up.
  • struct cmlcms_color_profile is re-structured
  • EOTF and VCGT are converted into LittleCMS profiles instead of stored as curves, so that they can be plugged in to chains as is.
  • output_inv_eotf_vcgt curve set is removed, and inverse EOTF profile is added, to be used in chains.
  • The blend-to-output transformation is created with a chain instead of hardcoding.

I think this should be a pre-requisite to @leandrohrb's !1390 (merged).

Merge request reports