Skip to content

Instantly share code, notes, and snippets.

@niittymaa
Created February 24, 2016 21:28
Show Gist options
  • Save niittymaa/84cb54769d7471584efa to your computer and use it in GitHub Desktop.
Save niittymaa/84cb54769d7471584efa to your computer and use it in GitHub Desktop.
Bash: Convert mp4 to ogv and/or WebM
# convert mp4 to ogv and/or webm
# mp4: http://caniuse.com/#search=mp4
# ogv: http://caniuse.com/#search=ogv
# webm: http://caniuse.com/#search=webm
# install
brew install ffmpeg --with-fdk-aac --with-ffplay --with-freetype --with-frei0r --with-libass --with-libvo-aacenc --with-libvorbis --with-libvpx --with-opencore-amr --with-openjpeg --with- --with-rtmpdump --with-schroedinger --with-speex --with-theora --with-tools
# mp4 to ogv
ffmpeg -i input.mp4 -q:v 10 -c:v libtheora -c:a libvorbis output.ogv
# mp4 to webm
ffmpeg -i input.mp4 -q:v 10 -c:v libvpx -c:a libvorbis output.webm
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment