summaryrefslogtreecommitdiff
path: root/xicc/bt1886.h
diff options
context:
space:
mode:
authorJörg Frings-Fürst <debian@jff-webhosting.net>2015-05-01 16:24:15 +0200
committerJörg Frings-Fürst <debian@jff-webhosting.net>2015-05-01 16:24:15 +0200
commita30ba67504ffd12c4db499adbb5ce47a7d1f6036 (patch)
tree9ae1a7e3849dda6bbb5c578232f6f2fa5b2e7e7e /xicc/bt1886.h
parent89e99e8a827859729729dfc92d74be4a8f96f1a4 (diff)
parent094535c010320967639e8e86f974d878e80baa72 (diff)
New release 1.7.0
Diffstat (limited to 'xicc/bt1886.h')
-rw-r--r--xicc/bt1886.h94
1 files changed, 94 insertions, 0 deletions
diff --git a/xicc/bt1886.h b/xicc/bt1886.h
new file mode 100644
index 0000000..f14efdc
--- /dev/null
+++ b/xicc/bt1886.h
@@ -0,0 +1,94 @@
+#ifndef BT1886_H
+#define BT1886_H
+
+/*
+ * Author: Graeme W. Gill
+ * Date: 16/8/13
+ * Version: 1.00
+ *
+ * Copyright 2013, 2014 Graeme W. Gill
+ * All rights reserved.
+ *
+ * This material is licenced under the GNU AFFERO GENERAL PUB LICENSE Version 3 :-
+ * see the License.txt file for licencing details.
+ *
+ */
+
+/* BT.1886 stype input offset transfer curve, */
+/* + general gamma + input + output offset curve support. */
+
+
+typedef struct {
+ icmXYZNumber w; /* White point for Lab conversion */
+ double ingo; /* input Y offset for bt1886 */
+ double outsc; /* output Y scale for bt1886 */
+ double outo; /* output Y offset */
+ double outL; /* output black point L value */
+ double tab[2]; /* Target ab offset value at zero input for bt1886 */
+ double gamma; /* bt.1886 technical gamma to apply */
+} bt1886_info;
+
+/* Set the bt1886_info to a default do nothing state */
+void bt1886_setnop(bt1886_info *p);
+
+/* Setup the bt1886_info for the given target */
+void bt1886_setup(
+bt1886_info *p,
+icmXYZNumber *w, /* wp used for L*a*b* conversion */
+double *XYZbp, /* normalised bp used for black offset and black point hue "bend" */
+double outoprop, /* 0..1 proportion of output black point compensation */
+double gamma, /* technical or effective gamma */
+int effg /* nz if effective gamma, z if technical gamma */
+);
+
+/* Apply BT.1886 eotf curve to the device RGB value */
+/* to produce a linear light RGB. We pass xvYCC out of range values through. */
+void bt1886_fwd_curve(bt1886_info *p, double *out, double *in);
+
+/* Apply BT.1886 processing black point hue adjustment to the XYZ value */
+void bt1886_wp_adjust(bt1886_info *p, double *out, double *in);
+
+
+/* Apply inverse BT.1886 eotf curve to the device RGB value */
+/* to produce a linear light RGB. We pass xvYCC out of range values through. */
+void bt1886_bwd_curve(bt1886_info *p, double *out, double *in);
+
+/* Apply inverse BT.1886 processing black point hue adjustment to the XYZ value */
+void bt1886_inv_wp_adjust(bt1886_info *p, double *out, double *in);
+
+#endif /* BT1886_H */
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+