Skip to content

Instantly share code, notes, and snippets.

@magsol
Last active August 5, 2020 16:37
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save magsol/f2961e0c8bfeee56339973773c8b6d8a to your computer and use it in GitHub Desktop.
Save magsol/f2961e0c8bfeee56339973773c8b6d8a to your computer and use it in GitHub Desktop.
ffmpeg video format conversion
# converts vidfile.avi to vidfile.mov
# re-encodes video using h264 codec
# This is good for, e.g., creating a video to post to instagram.
ffmpeg -i vidfile.avi -c:v h264 vidfile.mov
# This is good for, e.g., creating a video to embed in PPTX.
ffmpeg -i vidfile.avi -pix_fmt yuv420p vidfile.mov
# see the list of available codecs
ffmpeg -codecs
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment