Skip to content

Instantly share code, notes, and snippets.

@rgcoe
Last active April 8, 2025 20:28
Show Gist options
  • Save rgcoe/c83502cf6bf2d8d589fd11689d962781 to your computer and use it in GitHub Desktop.
Save rgcoe/c83502cf6bf2d8d589fd11689d962781 to your computer and use it in GitHub Desktop.
movtogif
movtogif () {
tempfile=.mov-to-gif-$(date +"%s").png
ffmpeg -v quiet -stats -y -i $1 -vf fps=5,palettegen $tempfile
ffmpeg -v quiet -stats -i $1 -i $tempfile -filter_complex "fps=12.5,scale=720:-1,paletteuse" "${1%.mov}.gif"
rm $tempfile
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment