diff options
author | Mattias Andrée <maandree@operamail.com> | 2014-04-04 21:53:23 +0200 |
---|---|---|
committer | Mattias Andrée <maandree@operamail.com> | 2014-04-04 21:53:23 +0200 |
commit | 7382112caf773c61202481f83e81ab013fb0b56c (patch) | |
tree | 6900e115b3a5da8367e4c535c081845b7615a224 | |
parent | update todo (diff) | |
download | blueshift-7382112caf773c61202481f83e81ab013fb0b56c.tar.gz blueshift-7382112caf773c61202481f83e81ab013fb0b56c.tar.bz2 blueshift-7382112caf773c61202481f83e81ab013fb0b56c.tar.xz |
document interpolation and halo elimination1.15
Signed-off-by: Mattias Andrée <maandree@operamail.com>
-rw-r--r-- | info/blueshift.texinfo | 43 | ||||
-rw-r--r-- | src/aux.py | 6 |
2 files changed, 46 insertions, 3 deletions
diff --git a/info/blueshift.texinfo b/info/blueshift.texinfo index 0ba27ac..8433a6b 100644 --- a/info/blueshift.texinfo +++ b/info/blueshift.texinfo @@ -324,6 +324,7 @@ Disables or enables Blueshift. * Weather:: Making weather dependent settings. * Running without X:: Configuration options for running without X. * Optimising:: Functions that can be used to optimise performance. +* Interpolation:: Interpolation functionised curves. @end menu @@ -1532,6 +1533,48 @@ might be heavier than applying the adjustments by invoking them. +@node Interpolation +@section Interpolation + +ICC profiles and curves that have beens turned +into functions with @code{functionise} have lower +input resolution that the input they receive; +to compensate for this, nearest-neighbour +interpolation is used. If you want to better +interpolation there are a few functions that +can be used to scale up the lookup table using +interpolation. + +@table @code +@item linearly_interpolate_ramp +Scale up using linear interpolation. + +@item cubicly_interpolate_ramp +Scale up using cubic Hermite interpolation. + +@end table + +These functions thats three arguments: +the red, the green and the blue colour +curves to scale up. The functions return +a tuple of these scaled up. All functions +are will using linear interpolation if +an interpolation segments is non-monotonic. +This is done, automatically by the +functions, by using the function +@code{eliminate_halos} that takes six +arguments and does not return anything. +@code{eliminate_halos}'s arguments are +the original three colour curves, followed +by the scaled up colour curves. The latter +argument trio will be modified by the +function. It does not matter which order +there curves are in as long as the order +is the same for the original curves and the +scaled up curves. It is recommended to +use the order: red, green and blue. + + @node Configuration examples @chapter Configuration examples @@ -49,7 +49,7 @@ def ramps_to_function(r, g, b): return functionise((fp(r), fp(g), fp(b))) -def linearly_interpolate_ramp(r, g, b): # TODO demo and document this +def linearly_interpolate_ramp(r, g, b): # TODO demo this ''' Linearly interpolate ramps to the size of the output axes @@ -75,7 +75,7 @@ def linearly_interpolate_ramp(r, g, b): # TODO demo and document this return (R, G, B) -def cubicly_interpolate_ramp(r, g, b): # TODO demo and document this +def cubicly_interpolate_ramp(r, g, b): # TODO demo this ''' Interpolate ramps to the size of the output axes using cubic Hermite spline @@ -173,7 +173,7 @@ def polynomially_interpolate_ramp(r, g, b): # TODO Speedup, demo and document th return (R, G, B) -def eliminate_halos(r, g, b, R, G, B): # TODO demo and document this +def eliminate_halos(r, g, b, R, G, B): # TODO demo this ''' Eliminate haloing effects in interpolations |