blind

suckless command-line video editing utility
git clone git://git.suckless.org/blind
Log | Files | Refs | README | LICENSE

commit e65b91e0c208dd0c9e799b43c27c030bebc92aef
parent b221dcb4c68b492d810f249959a0bd3322dbcdeb
Author: Mattias Andrée <maandree@kth.se>
Date:   Sun,  9 Jul 2017 00:59:32 +0200

Document blind-spectrum

Signed-off-by: Mattias Andrée <maandree@kth.se>

Diffstat:
README | 3+++
man/blind-cone-gradient.1 | 1+
man/blind-double-sine-wave.1 | 1+
man/blind-linear-gradient.1 | 1+
man/blind-radial-gradient.1 | 1+
man/blind-round-wave.1 | 1+
man/blind-sawtooth-wave.1 | 1+
man/blind-sinc-wave.1 | 1+
man/blind-sine-wave.1 | 1+
man/blind-spectrum.1 | 85+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
man/blind-spiral-gradient.1 | 1+
man/blind-square-gradient.1 | 1+
man/blind-triangular-wave.1 | 1+
man/blind.7 | 3+++
14 files changed, 102 insertions(+), 0 deletions(-)

diff --git a/README b/README @@ -177,6 +177,9 @@ UTILITIES blind-skip-pattern(1) Skips frames in a video according to pattern + blind-spectrum(1) + Transform a gradient into a spectrum + blind-spiral-gradient(1) Generate a video with a spiral gradient diff --git a/man/blind-cone-gradient.1 b/man/blind-cone-gradient.1 @@ -54,6 +54,7 @@ The height of the video, in pixels. .BR blind-sinc-wave (1), .BR blind-sine-wave (1), .BR blind-triangular-wave (1), +.BR blind-spectrum (1), .BR blind-linear-gradient (1), .BR blind-radial-gradient (1), .BR blind-spiral-gradient (1), diff --git a/man/blind-double-sine-wave.1 b/man/blind-double-sine-wave.1 @@ -24,6 +24,7 @@ are identical. .BR blind-sinc-wave (1), .BR blind-sine-wave (1), .BR blind-triangular-wave (1), +.BR blind-spectrum (1), .BR blind-cone-gradient (1), .BR blind-linear-gradient (1), .BR blind-radial-gradient (1), diff --git a/man/blind-linear-gradient.1 b/man/blind-linear-gradient.1 @@ -50,6 +50,7 @@ The height of the video, in pixels. .BR blind-sinc-wave (1), .BR blind-sine-wave (1), .BR blind-triangular-wave (1), +.BR blind-spectrum (1), .BR blind-cone-gradient (1), .BR blind-radial-gradient (1), .BR blind-spiral-gradient (1), diff --git a/man/blind-radial-gradient.1 b/man/blind-radial-gradient.1 @@ -70,6 +70,7 @@ The height of the video, in pixels. .BR blind-sinc-wave (1), .BR blind-sine-wave (1), .BR blind-triangular-wave (1), +.BR blind-spectrum (1), .BR blind-cone-gradient (1), .BR blind-linear-gradient (1), .BR blind-spiral-gradient (1), diff --git a/man/blind-round-wave.1 b/man/blind-round-wave.1 @@ -24,6 +24,7 @@ are identical. .BR blind-sinc-wave (1), .BR blind-sine-wave (1), .BR blind-triangular-wave (1), +.BR blind-spectrum (1), .BR blind-cone-gradient (1), .BR blind-linear-gradient (1), .BR blind-radial-gradient (1), diff --git a/man/blind-sawtooth-wave.1 b/man/blind-sawtooth-wave.1 @@ -24,6 +24,7 @@ are identical. .BR blind-sinc-wave (1), .BR blind-sine-wave (1), .BR blind-triangular-wave (1), +.BR blind-spectrum (1), .BR blind-cone-gradient (1), .BR blind-linear-gradient (1), .BR blind-radial-gradient (1), diff --git a/man/blind-sinc-wave.1 b/man/blind-sinc-wave.1 @@ -45,6 +45,7 @@ is specified, the values from its second channel .BR blind-sawtooth-wave (1), .BR blind-sine-wave (1), .BR blind-triangular-wave (1), +.BR blind-spectrum (1), .BR blind-cone-gradient (1), .BR blind-linear-gradient (1), .BR blind-radial-gradient (1), diff --git a/man/blind-sine-wave.1 b/man/blind-sine-wave.1 @@ -24,6 +24,7 @@ are identical. .BR blind-sawtooth-wave (1), .BR blind-sinc-wave (1), .BR blind-triangular-wave (1), +.BR blind-spectrum (1), .BR blind-cone-gradient (1), .BR blind-linear-gradient (1), .BR blind-radial-gradient (1), diff --git a/man/blind-spectrum.1 b/man/blind-spectrum.1 @@ -0,0 +1,85 @@ +.TH BLIND-SPECTRUM 1 blind +.SH NAME +blind-spectrum - Transform a gradient into a spectrum +.SH SYNOPSIS +.B blind-spectrum +[-y] +[-z +.IR depth ] +.I spectrum-stream +.SH DESCRIPTION +.B blind-spectrum +reads a video from stdin, transforms it according +to a colour table and prints the resulting video +to stdout. The values of the colours, excluding +the alpha channel, in stdin, are truncated to +fit [0, 1]. The resulting values for each pixel +is used to look up a colour in +.I spectrum-stream +for the same frame, with linear interpolation. +That colour is used as the pixel's colour. The +alpha values of the looked up colour and the +pixel's original colour are multiplied, and the +product is used as the pixel's alpha value. +.P +When looking up colours in +.IR spectrum-stream , +the value of the first channel (the X channel) +is multiplied by the width of the video in +.I spectrum-stream +less 1, +the product is the column in +.I spectrum-stream +that will be used (using interpolation for +none integer products), and the value of the first +channel (the Y channel) is multiplied by the height +of the video in +.I spectrum-stream +less 1, the product is the row in +.I spectrum-stream +that will be used. +.SH OPTIONS +.TP +.B -y +Rather than using the values of the three +colour channels to look up a colour in a +multidimensional table, the luma is used to +look up a value in a singledimensional table. +Which dimension is used does not matter; the +result is unspecified if the colour table +is multidimensional. +.TP +.BR -z \ \fIdepth\fP +For each frame in stdin, +.I depth +frames are read from +.IR spectrum-stream . +When looking up colours in +.IR spectrum-stream , +the value of the third channel (the > channel) +is multiplied by +.I depth +less 1, the product is the frame +in this set of +.I depth +frames from +.I spectrum-stream +that will be used. +.SH SEE ALSO +.BR blind (7), +.BR blind-from-text (1), +.BR blind-arithm (1), +.BR blind-double-spectrum (1), +.BR blind-round-wave (1), +.BR blind-sawtooth-wave (1), +.BR blind-sine-wave (1) +.BR blind-sinc-wave (1), +.BR blind-triangular-wave (1), +.BR blind-cone-gradient (1), +.BR blind-linear-gradient (1), +.BR blind-radial-gradient (1), +.BR blind-spiral-gradient (1), +.BR blind-square-gradient (1) +.SH AUTHORS +Mattias Andrée +.RI < maandree@kth.se > diff --git a/man/blind-spiral-gradient.1 b/man/blind-spiral-gradient.1 @@ -114,6 +114,7 @@ The height of the video, in pixels. .BR blind-sinc-wave (1), .BR blind-sine-wave (1), .BR blind-triangular-wave (1), +.BR blind-spectrum (1), .BR blind-cone-gradient (1), .BR blind-linear-gradient (1), .BR blind-radial-gradient (1), diff --git a/man/blind-square-gradient.1 b/man/blind-square-gradient.1 @@ -54,6 +54,7 @@ The height of the video, in pixels. .BR blind-sinc-wave (1), .BR blind-sine-wave (1), .BR blind-triangular-wave (1), +.BR blind-spectrum (1), .BR blind-cone-gradient (1), .BR blind-linear-gradient (1), .BR blind-radial-gradient (1), diff --git a/man/blind-triangular-wave.1 b/man/blind-triangular-wave.1 @@ -28,6 +28,7 @@ more appropriate for spiral gradient. .BR blind-sawtooth-wave (1), .BR blind-sinc-wave (1), .BR blind-sine-wave (1), +.BR blind-spectrum (1), .BR blind-cone-gradient (1), .BR blind-linear-gradient (1), .BR blind-radial-gradient (1), diff --git a/man/blind.7 b/man/blind.7 @@ -190,6 +190,9 @@ Apply sine-wave repetition to gradient .BR blind-skip-pattern (1) Skips frames in a video according to pattern .TP +.BR blind-spectrum (1) +Transform a gradient into a spectrum +.TP .BR blind-spiral-gradient (1) Generate a video with a spiral gradient .TP