Tuesday, May 18, 2010

How to install proprietary codecs on Ubuntu Linux 10.04 (Lucid Lynx) Flash, MP3, DVD

Most Linux distributions, Ubuntu included, ship with only "free software". Not just free as in price, but free as in freedom. That is software that is free of patents, licensing restrictions, copyright restrictions and DRM (digital rights management), where the source is fully available for anyone to modify or extend. Free software has many benefits and in many cases, free software is of much greater quality than its proprietary or commercial counterparts.

Shipping without proprietary software, also means shipping without proprietary media codecs such as Mp3, AAC, Flash, Mpeg4 (DVD) or h.264 (HTML5, Blu-Ray and many others). Instead they come with codecs such as Ogg Vorbis and Flac for music and Theora for video. These are wonderful formats and I am lucky to have all my computers and devices running Linux so I can take full advantage of them. However, device support across the board is not so great, and for those less fortunate, or those just getting into Linux, who might have large collections of media stored in "bad" formats, their media will not play out-of-box on Linux. You may simply just wish to watch YouTube, play your own DVD's, or listen to music purchased online from the Ubuntu One Music store for instance, which also because of licensing constraints and even because of legal issues in some countries cannot be played on a fresh install of Linux.

Well have no fear, you can play pretty much anything on Linux, very easily, you don't even need to visit the terminal. Just follow my simple video below:

If you don't already have Flash installed and cannot watch the video here is what to do:

1) Open 'Software Center' from the Applications menu
2) Search for 'Ubuntu restricted extras' and click 'Install' then enter your password at the prompt -- the install may take some time, it is downloading and installing tons of media codecs

You now have support for most media except for playing back encrypted (commercial) DVD's, to add support for encrypted DVD's:

3) Press 'Alt' and 'F2' on your keyboard at the same time to bring up the run dialog
4) Type 'gksudo /usr/share/doc/libdvdread4/install-css.sh' and click 'Run' -- the command will run and you will not see a confirmation unless you check the 'Run in terminal' option, either way it will only take a few seconds

That's it, You can playback just about all of the popular media codecs in use today! Most people will can stop at this point.

So what about the more obscure formats? If you want to be able to play just about any format imaginable (and then some) there are just a few more steps. This is one of the few times that I will request you use a terminal, because it really is a much easier route to take.

1) Open a new terminal by going to your Applications menu, then Accessories and click 'Terminal'
2) Copy and paste the following command and press Enter:
echo "deb http://packages.medibuntu.org/ lucid free non-free" | sudo tee -a /etc/apt/sources.list
3) Copy and paste the following command and press Enter:
wget -q http://packages.medibuntu.org/medibuntu-key.gpg -O- | sudo apt-key add - && sudo apt-get update
4) Open 'Software Center' from the Applications Menu
5) Search for 'non-free codecs' and click 'Install'

No comments:

Post a Comment