Created
April 23, 2015 21:07
-
-
Save gregtatum/d6c2de6e60fea71c8bf5 to your computer and use it in GitHub Desktop.
gif.sh
This file contains hidden or 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
| #Run: gif.sh file.mov 320 | |
| #Outputs a file.gif at 320px wide | |
| OUT=$(echo $1 | sed -e 's/\.[a-zA-Z0-9]*$/.gif/') | |
| ffmpeg -i "$1" -vf scale=${2:-640}:-1 -r 30 -f image2pipe -vcodec ppm - | convert -delay 5 -layers Optimize -loop 0 - "$OUT" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment