Skip to content

Instantly share code, notes, and snippets.

@dgomes
Created April 30, 2012 17:39
Show Gist options
  • Select an option

  • Save dgomes/2560355 to your computer and use it in GitHub Desktop.

Select an option

Save dgomes/2560355 to your computer and use it in GitHub Desktop.
How to encode a video to play on a STB
ffmpeg -i $1 -scodec copy -vcodec libx264 -vprofile high -preset slow -b:v 800k -maxrate 800k -bufsize 2000k -threads 16 -acodec libfaac -ac 2 -ab 128k -vol 400 -f mp4 -an -pass 1 -y /dev/null
ffmpeg -i $1 -scodec copy -vcodec libx264 -vprofile high -preset slow -b:v 800k -maxrate 800k -bufsize 2000k -threads 16 -acodec libfaac -ac 2 -ab 128k -vol 400 -f mp4 -pass 2 -y $1.tmp
qt-faststart $1.tmp $1.m4v
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment