aboutsummaryrefslogtreecommitdiffstats
path: root/src/libcolour.c
diff options
context:
space:
mode:
authorMattias Andrée <maandree@kth.se>2016-12-20 19:50:24 +0100
committerMattias Andrée <maandree@kth.se>2016-12-20 19:50:24 +0100
commit97b7af4ac979d2450364d10770b83ec94406ce31 (patch)
tree3b23affe6e1c994453c432c9f864571ef99c77e7 /src/libcolour.c
parentCIELChuv: measure hue in degrees, but add parameter to change this (diff)
downloadlibcolour-97b7af4ac979d2450364d10770b83ec94406ce31.tar.gz
libcolour-97b7af4ac979d2450364d10770b83ec94406ce31.tar.bz2
libcolour-97b7af4ac979d2450364d10770b83ec94406ce31.tar.xz
fix errors and add tests
Signed-off-by: Mattias Andrée <maandree@kth.se>
Diffstat (limited to 'src/libcolour.c')
-rw-r--r--src/libcolour.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/libcolour.c b/src/libcolour.c
index 69014d3..867e280 100644
--- a/src/libcolour.c
+++ b/src/libcolour.c
@@ -44,7 +44,7 @@ double libcolour_srgb_decode(double t)
t = -t;
sign = -1;
}
- t = t <= 0.040448236277380506 ? t / 12.92 : pow((t + 0.055) / 1.055, 2.4);
+ t = t <= 0.0031306684425217108 * 12.92 ? t / 12.92 : pow((t + 0.055) / 1.055, 2.4);
return t * sign;
}