Alex Balgavy

Just some stuff about me.

Here's my dotfiles repository.

Check out my blog.

My keys: PGP, SSH

My crypto wallets (BTC, XMR)

how to edit the hue of a video

Written by John Riselvato - original link

The hue filter allows for modification of the hue and saturation of a video. 

Figure 57.0: applying a hue and saturation{width=“436” height=“240”}

In the example below, the hue is set to 45 degrees with an increased saturation, as seen in figure 57.0:

$ ffmpeg -i input.mp4 -vf "hue=h=45:s=2" output.mp4

Figure 57.1: dynamic hues{width=“436” height=“240”}

The hue filter also has framing and time parameters that allow for great effects like animating through hue colors quickly. Expressions can also be programmed, as seen in figure 57.1:

 $ ffmpeg -i input.mp4 -vf "hue=H=2*PI*t:s=cos(2*PI*t)+10" output.mp4
hue
    Indicates the hue filter name

h
    Indicates the hue angle as a number of degrees (default 0)

s
    Indicates the saturation (10 to -10 with default 1)

H
    Indicates hue angle as a number of radians (default 0)

b
    Indicates the brightness (10 to -10 with default 0)


n
    Indicates frame count of the input frame (starts at 0)

t
    Indicates the timestamp (HH:MM:SS)