Last active
June 5, 2022 21:55
-
-
Save micahyoung/df0f3b3f810089f153ca376f3e196cc1 to your computer and use it in GitHub Desktop.
iMovie cut frames
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
set -o errexit -o pipefail -o nounset | |
# usage ./cutframes.sh "2000-01-01" "second line" "third line" prefix- | |
line1=$1 | |
line2=$2 | |
line3=$3 | |
prefix=$4 | |
size=1920x1080 | |
for num in 1 2 3 4; do | |
text="${line1}\n${line2}\n${line3}\n${num} of 4" | |
file="${prefix}${num}of4.png" | |
convert -size $size xc:black \ | |
-fill white \ | |
-font Courier \ | |
-pointsize 96 \ | |
-gravity West \ | |
-annotate +400+0 "$text" \ | |
$file | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment