Useful ffmpeg and mencoder commands on Ubuntu 9.10 Karmic

By | July 11, 2019

FFmpeg can be installed easily from synaptic

$ sudo apt-get install ffmpeg

Some useful FFMPEG commands :

1. convert mpeg to flv

ffmpeg -i /path/to/movie.mpeg -ar 22050 -ab 32 -f flv -b 500000 -s 480x360 -y movie.flv

2. convert mp3 to flv

ffmpeg -i /path/to/track.mp3 -f mp3 -ab 64000 -ar 22050 myfile.mp3

3. convert mpeg to flv with mp3

ffmpeg -i /path/to/movie.mpeg -ar 22050 -ab 64000 -acodec libmp3lame -f flv -b 1000000 -s 480x360 -y movie.flv

4. convert ogv to avi

ffmpeg -i /path/to/movie.ogv output.avi

-i denotes the input file path
-acodec - denotes the audio codec , libmp3lame in this case , can be installed from synaptic
-s the dimension of final movie e.g. 480x360
-ab audio bitrate of output e.g. 64000

FFMpeg Options
FFmpeg Docs

Useful links :
19 ffmpeg commands
19 ffmpeg commands

For help go to irc channel #ffmpeg on


1. Convert ogv to wmv (Windows) :

mencoder -idx /path/to/file.ogv -ovc lavc -oac lavc -lavcopts vcodec=wmv2 -of lavf -o outfile.wmv

-ovc : Output Video Codec
-oac - Output Audio Code
lavc - Select from libavcodec (can be installed from synaptic)
-of : output format
Mencoder Usage Guide

libavcodec-extra-52 should also be installed for mp3 support.


Last Updated On : 11th July 2019

One thought on “Useful ffmpeg and mencoder commands on Ubuntu 9.10 Karmic

Leave a Reply

Your email address will not be published. Required fields are marked *