Skip to content

Instantly share code, notes, and snippets.

@pix0r
Created April 2, 2011 01: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 pix0r/899142 to your computer and use it in GitHub Desktop.
Save pix0r/899142 to your computer and use it in GitHub Desktop.
Convert MPEG audio or video into MPEG Transport Stream (simple ffmpeg commandline)
#!/bin/sh
IN=$1
OUT=$2
if [ "$IN" = "" ]; then
echo "Convert MPEG audio or video into MPEG Transport Stream"
echo "Usage: $0 <infile> [outfile]"
exit
fi
if [ "$OUT" = "" ]; then
OUT="$IN.ts"
fi
ffmpeg -i $IN -f mpegts -acodec copy -vcodec copy $OUT
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment