tests/color_util: add TRANSFER_FN_IDENTITY

This will be useful to make a curve in a color pipeline pass-through
without needing to special-case skipping the curve.

Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.com>
dev
Pekka Paalanen 3 years ago committed by Pekka Paalanen
parent 6fa7ab5d5f
commit fa477d2407
  1. 3
      tests/color_util.c
  2. 1
      tests/color_util.h

@ -167,6 +167,9 @@ apply_tone_curve(enum transfer_fn fn, float r)
float ret = 0;
switch(fn) {
case TRANSFER_FN_IDENTITY:
ret = r;
break;
case TRANSFER_FN_SRGB_EOTF:
ret = sRGB_EOTF(r);
break;

@ -58,6 +58,7 @@ struct lcmsMAT3 {
};
enum transfer_fn {
TRANSFER_FN_IDENTITY,
TRANSFER_FN_SRGB_EOTF,
TRANSFER_FN_SRGB_EOTF_INVERSE,
TRANSFER_FN_ADOBE_RGB_EOTF,

Loading…
Cancel
Save