Unix for Artists: Fun with FFMPEG is a workshop hosted by the Echo Park Film Center.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
unix4artists/ffmpeg/filter/grayscale.sh

25 lines
569 B

#!/bin/bash -e
#####################################################
#
# This script will convert a color video to black &
# white by converting to grayscale format.
#
# Usage: bash ffmpeg/filter/grayscale.sh <input video> <output video>
#
#####################################################
INPUT="${1}"
OUTPUT="${2}"
# Check if output file extension is .mov
if [[ "${OUTPUT}" != *".mov" ]]; then
echo "Please use an .mov extension on your output file argument"
exit 1
fi
ffmpeg -i "${INPUT}" \
-vf format=gray \
-c:v prores_ks \
-profile:v 3 \
"${OUTPUT}"