This gist shows how to create a GIF screencast using only free OS X tools: QuickTime and ffmpeg.
Forked from https://gist.github.com/baumandm/1dba6a055356d183bbf7. Updated to facility the usage.
Add the following function in your .bash_profile :
function movtogif () {
tempfile=.mov-to-gif-$(date +"%s").png
ffmpeg -v quiet -stats -y -i $1 -vf fps=10,palettegen $tempfile
ffmpeg -v quiet -stats -i $1 -i $tempfile -filter_complex "fps=10,paletteuse" "${1%.mov}.gif"
rm $tempfile
}
$ movtogif filename.mov
The conversion process requires the following command-line tools:
- ffmpeg to process the video file
If you use homebrew and homebrew-cask software packages, just type this in:
$ brew install ffmpeg
- https://gist.github.com/baumandm/1dba6a055356d183bbf7
- http://superuser.com/questions/556029/how-do-i-convert-a-video-to-gif-using-ffmpeg-with-reasonable-quality/556031#556031
- http://schneems.com/post/41104255619/use-gifs-in-your-pull-request-for-good-not-evil (primary source!)
- http://www.reddit.com/r/programming/comments/16zu7d/use_gifs_in_your_pull_requests_for_good_not_evil/
- http://superuser.com/questions/436056/how-can-i-get-ffmpeg-to-convert-a-mov-to-a-gif#_=_
- http://gnuski.blogspot.ca/2012/06/creating-animate-gif-with-free-software.html