summaryrefslogtreecommitdiffstats
path: root/examples/logarithmic
diff options
context:
space:
mode:
authorMattias Andrée <maandree@operamail.com>2014-03-19 05:46:06 +0100
committerMattias Andrée <maandree@operamail.com>2014-03-19 05:46:06 +0100
commit1f289a0b90529346ea88169840a1cf11c7da3842 (patch)
tree91fcf2d5c1fcc3d3aed441521f56a80ed5cf2117 /examples/logarithmic
parentupdate todo (diff)
downloadblueshift-1f289a0b90529346ea88169840a1cf11c7da3842.tar.gz
blueshift-1f289a0b90529346ea88169840a1cf11c7da3842.tar.bz2
blueshift-1f289a0b90529346ea88169840a1cf11c7da3842.tar.xz
doc
Signed-off-by: Mattias Andrée <maandree@operamail.com>
Diffstat (limited to 'examples/logarithmic')
-rw-r--r--examples/logarithmic16
1 files changed, 12 insertions, 4 deletions
diff --git a/examples/logarithmic b/examples/logarithmic
index 731b27d..62271d9 100644
--- a/examples/logarithmic
+++ b/examples/logarithmic
@@ -20,14 +20,22 @@ import math
linearise()
# Make the curves logarithmic. The function applies
-# to all colour curves, but you can change them
-# individually by specifing three functions: red,
-# green and blue.
-manipulate(lambda x : math.log(x + 1, 2))
+# to the red (first argument) and green (second
+# argument) colour curves. `...` is used to use the
+# same value as the argument before it. `None`,
+# which is used for the blue colour curve, means
+# that no adjustment is made, which is the same
+# thing as using `lambda x : x`.
+manipulate(lambda x : math.log(x + 1, 2), ..., None)
# Switch back to sRGB.
standardise()
+# Alternatively you can use `cie_manipulate` instead
+# of `manipulate`. To to the logaritmisation in the
+# CIE xyY colour space. If doing so, do not use
+# `linearise`–`standardise`.
+
# Apply settings, using vidmode.
(drm if ttymode else vidmode)()
#(drm if ttymode else randr)()