bad-apple/video/convert.sh
2024-04-10 19:04:29 +02:00

18 lines
325 B
Bash
Executable file

#!/bin/bash
# 480x360 base resolution
# 42x32 is close enough
# 40x32 is nicer to work with because divisible by 8
rm frames/*.png
ffmpeg -i *.webm \
-r $1 \
-ss 1 \
-vf scale=40:32 \
-sws_dither none \
frames/frame_%04d.png 2> /dev/null
# -pix_fmt monob \
echo converted with $1 fps
echo $(ls -L1 frames | wc -l) frames