eq (1) - contrast

Watch on youtube.com
doc

https://ffmpeg.org/ffmpeg-filters.html#eq

contrast=-2.0 … 2.0

The value must be a float value in range -2.0 to 2.0. The default value is “1”.

eq=contrast=-2.0

00:00:00
#! /bin/sh
ifn="Pexels_flowers_fast.mp4"
ifnb="`basename \"${ifn}\" .mp4`"
pref="`basename $0 .sh`"

ffmpeg -y -i "${ifn}" \
  -vf "eq=contrast=-2.0" \
  -an "${pref}_${ifnb}.mp4"

eq=contrast=-1.5

00:00:08
#! /bin/sh
ifn="Pexels_flowers_fast.mp4"
ifnb="`basename \"${ifn}\" .mp4`"
pref="`basename $0 .sh`"

ffmpeg -y -i "${ifn}" \
  -vf "eq=contrast=-1.5" \
  -an "${pref}_${ifnb}.mp4"

eq=contrast=-1.0

00:00:15
#! /bin/sh
ifn="Pexels_flowers_fast.mp4"
ifnb="`basename \"${ifn}\" .mp4`"
pref="`basename $0 .sh`"

ffmpeg -y -i "${ifn}" \
  -vf "eq=contrast=-1.0" \
  -an "${pref}_${ifnb}.mp4"

eq=contrast=0

00:00:23
#! /bin/sh
ifn="Pexels_flowers_fast.mp4"
ifnb="`basename \"${ifn}\" .mp4`"
pref="`basename $0 .sh`"

ffmpeg -y -i "${ifn}" \
  -vf "eq=contrast=0" \
  -an "${pref}_${ifnb}.mp4"

eq=contrast=1.0

00:00:31
#! /bin/sh
ifn="Pexels_flowers_fast.mp4"
ifnb="`basename \"${ifn}\" .mp4`"
pref="`basename $0 .sh`"

ffmpeg -y -i "${ifn}" \
  -vf "eq=contrast=1.0" \
  -an "${pref}_${ifnb}.mp4"

eq=contrast=1.5

00:00:38
#! /bin/sh
ifn="Pexels_flowers_fast.mp4"
ifnb="`basename \"${ifn}\" .mp4`"
pref="`basename $0 .sh`"

ffmpeg -y -i "${ifn}" \
  -vf "eq=contrast=1.5" \
  -an "${pref}_${ifnb}.mp4"

eq=contrast=2.0

00:00:46
#! /bin/sh
ifn="Pexels_flowers_fast.mp4"
ifnb="`basename \"${ifn}\" .mp4`"
pref="`basename $0 .sh`"

ffmpeg -y -i "${ifn}" \
  -vf "eq=contrast=2.0" \
  -an "${pref}_${ifnb}.mp4"

Using expression

eq=contrast=(-2.0+t/30*4.0):eval=frame

In this example, since “${ifn}” is a video of 30 seconds, it instructs to change by 1 / 7.5 per second.

00:00:53
#! /bin/sh
ifn="Pexels_flowers.mp4"
ifnb="`basename \"${ifn}\" .mp4`"
pref="`basename $0 .sh`"

ffmpeg -y -i "${ifn}" \
  -vf "eq=contrast=(-2.0+t/30*4.0):eval=frame" \
  -an "${pref}_${ifnb}.mp4"