The file sites/all/modules/cumulus/cumulus.js is missing. Please download it from http://pratul.in/files/cumulus.js, and add it to the Cumulus module folder!

Useful video transcoding commands

One of the handiest tools in my Linux toolchest is FFMPEG, the universal media transcoder. I'm pretty sure this fantastically useful piece of software runs in the background of every service that converts audio or video from one format to another (Google video, YouTube, Archive.org, etc). Over the years I've amassed a small collection of commands that will allow me to take media from one source and convert it for use in another - for example ripping video from a DVD or the web and then editing it and burning it back to DVD.

If you encounter problems running any of these commands be sure to install the full (restricted) version of ffmpeg as per this thread. If you are looking for instructions on how to convert video for the Google Nexus One running Android read this post!. Hopefully these will prove to be of use to you:

1) Converting any video to DVD-compatible MPEG2:

ffmpeg -y -i inputfile.xyz -vcodec mpeg2video -target ntsc-dvd -r ntsc -deinterlace -aspect 4:3 outputfile.m2v


2) Converting video for the web (w/o frame size reduction):

ffmpeg -i inputfile.xyz -f avi -vcodec mpeg4 -ab 128 output.avi


3) Convert DVD (MPEG2) files to MPEG4:

ffmpeg -i inputfile.vob -f avi -vcodec mpeg4 -b 800 -g 300 -bf 2 outputfile.avi


4) Prepare Cinelerra edited .DV (from Canon GL1*) for Google video upload:

ffmpeg -i inputfile.dv -f avi -vcodec mpeg4 -cropleft 8 -cropright 4 -s 640x480 -b 1200 -g 300 -bf 2 -acodec mp3 -ab 128 outputfile.avi


5) Convert electric sheep for Resiloom:


ffmpeg -i inputfile.mpg -f avi -vcodec mpeg4 -s 640x480 -b 6000 -g 300 -bf 2 -acodec mp3 -ab 128 outputfile.avi


6) Convert to raw DV (eg. for editing in Cinelerra or similar):


ffmpeg -i inputfile.xyz -target ntsc-dv outputfile.dv

 

7) Batch convert a directory of files (eg. from .mp3 to .wav):

for f in *.mp3; do ffmpeg -i "$f" "${f%.mp3}.wav"; done

 

8) Downsample mp3 audio file to 22050hz**:

ffmpeg -i inputfile.mp3 -acodec mp3 -ab 128 -ar 22050 outputfile.mp3

* The Canon GL1 does not shoot a full 720x480. This command include the options to remove the black bands that the GL1 adds to the sides of DV video during the transcode.
** This requires a versionn of FFMpeg that has been compiled with Lame (MP3) support.

 

Post new comment

The content of this field is kept private and will not be shown publicly.
  • Web page addresses and e-mail addresses turn into links automatically.
  • You may insert videos with [video:URL]

More information about formatting options

CAPTCHA
This question is for testing whether you are a human visitor and to prevent automated spam submissions.