Autotel

Bash script to join frames into a video

Assuming that you rendered a video into individual frames contained in a folder, this bash script requires you to input the folder name, and it outputs a webm video of the frame sequence, named the same as the input folder.

#!/bin/sh
die () {
    echo >&2 "$@"
    exit 1
}

if [ "$#" -eq 1 ]; then

    input=$1
    echo "making video from ./$input/*.png into $input.webm"
    read -p "Press enter to continue"
    ffmpeg -framerate 20 -pattern_type glob -i "./$input/*.png" "$input.webm"
else
    echo "please provide the input frames folder";
fi