NEWS CATEGORIES:



NEWS ARCHIVE >>
SOFTPEDIA REVIEWS >>
MEET THE EDITORS >>
Home / News / Linux / Other Tips, Tricks and Tutorials

Other Tips, Tricks and Tutorials


Convert Movies (with subtitles) for Your PSP on Ubuntu

AVI/MKV/DVD to MP4/H.264/AAC

By Marius Nestor, Linux Editor

7th of October 2007, 12:52 GMT

Adjust text size:


PSP
Enlarge picture
For this task, you will need Avidemux 2.4 Preview 2. Why? Simply because it has improved support for H.264 videos, that means most of today's HR (High Resolution) movies and HDTV content. Let's say for example that you've recorded a TV show from your favorite HDTV channel and you don't have time to watch it (that's the reason why you have recorded it in the first place) and you are in a rush. What can you do? Answer: Convert it to a format that can be watched on your PSP (PlayStation Portable)! How? Read the detailed guide below on how to achieve this simple task with nothing but free software on a free platform, Ubuntu Linux.

I've used Ubuntu Gutsy Beta, the AMD64/EMT64 one, for this guide, to demonstrate to everyone that always ask me: how is Linux on a 64-bit platform? Do you have all the software you need? Well, Linux (Ubuntu, because this is what I have been using for some time now... more than a year) and the whole open source community made a lot of progress regarding the 64-bit platform and I can honestly say that... it works folks!

Installing Avidemux 2.4 from SVN

Unfortunately, you will have to open up a terminal for this task and copy/paste the following code, in order to install the dependencies for Avidemux:

CODE
sudo apt-get -y install automake1.10 g++ gcc liba52-0.7.4 liba52-0.7.4-dev libfaac-dev libfaad2-dev libstdc++6 libgtk2.0-dev libglib2.0-dev libsdl-console-dev libxv-dev pkg-config liblame-dev libmad0-dev libvorbis-dev libxml2-dev libxvidcore4-dev subversion gettext libmozjs-dev cmake libqt4-dev libsamplerate0-dev libjack-dev libarts1-dev libx264-dev

Also, go to Applications -> Add/Remove Programs and search for ubuntu restricted extras and install it.

Review image


Now fetch the Avidemux 2.4 files from SVN with the following command:

CODE
svn co svn://svn.berlios.de/avidemux/branches/avidemux_2.4_branch/

When the download is over, enter the Avidemux source directory with:

CODE
cd avidemux_2.4_branch/

And type:

CODE
cmake .

Take a look at the summary when cmake finished. It should look like this:

CODE
*******************
** Summary **
*******************
Gtk TRUE
Qt4 YES
*** Video Codec ***
X264 Yes
Xvid4 Yes
*** Audio Codec ***
LAME Yes
FAAD Yes
FAAC Yes
Vorbis Yes
Aften No
libDCA No
libAMRNB No
*** Audio Device ***
ESD Yes
OSS Yes
ARTS Yes
JACK Yes
*** Misc ***
SDL Yes
FreeType Yes
FontConfig Yes
Gettext Yes
Xvideo Yes
samplerate Yes
*******************
*******************

As you can see, except for the Aften, libDCA (DTS support) and libAMRNB (AMR support) audio codecs that can't be found in Ubuntu, the rest of the dependencies are present. Now you can continue with the compilation, type:

CODE
make

This is why I love cmake, it shows you the percent of the compilation status, so you don't have to worry all the time: how long is it gonna take? Can I take a shower until this thing is done? Well, on my computer the compilation reached 100% (it shows 99% actually) in about 5-6 minutes. When it's done, type:

CODE
sudo make install

And Avidemux will be installed on your system.

Let's create a desktop shortcut for Avidemux. Right click on your desktop, go to Create Launcher and in the new window that appears enter in the Name: field, Avidemux2 and in the Command: field, avidemux_gtk, choose an icon by clicking on the icon button and when you're done, click OK and the shortcut will be created on your desktop. Double click it and Avidemux will open.

Review image


Convert a movie to PSP specific format

For this example I have used an MKV file, encoded with H.264 video codec and an AC3 5.1 audio codec. Click "Open", search for the video file that you want to convert and double click it. Now, let the application read the file, or index it if it's necessary, and if the codec is supported it will open. If you have an H.264 file, like me, Avidemux will ask you if you want to use an implemented mode for this kind of file, but you will click "Cancel" and then you'll need to rebuild the frames of the file, so click "Yes" when asked. Take a look at the example below:

Review image

Review image


Go to "Auto" menu and select "PSP (H.264)":

Review image


In the new window that will appear, select at 'Target type', PSP 480*272:

Review image


Click the 'Configure' button so we can configure the x264 video codec:

Review image


Type 1000 on the 'Target bitrate' field:

Review image


Then move to second tab (Motion & Misc) and at 'Partition decision' select last option, 7B - Ultra High (RDO on Bframes):

Review image


And on the 'Method' section, select "Exhaustive search":

Review image


Now that the x264 codec is configured, click the 'Filters' button to add a SRT or SUB subtitle (optional) on your movie. On the Filters window, select the 'Subtitles' left tab and double click the first filter called "Subtitler":

Review image


Now, choose the subtitle, choose a preferred font, choose the encoding type (I've used Ascii). Select a color for the subtitle and remember to click on the "Set Size and Position" button so you can adjust the size of the subtitle and where it will appear on the movie. Optionally, you can check the 'Auto split' option or set a delay (in milliseconds).

Review image

Review image


Click OK when you're done with the subtitle configuration and you should see the 'Subtitler' filter added to the 'Active Filters' list.

Review image

Let's configure the audio codec (FAAC in our case). Click the 'Filters' button on the Audio section:

Review image


And select on the 'Mixer' section, Stereo; and on the 'Resampling (Hz)' section, choose 48000 (just check the option and it will be activated):

Review image


Click the 'Save' button and type a desired name and select the location were you want to save the file. Remember to add the .mp4 extension to the name of the file, because Avidemux doesn't auto-complete the file's extension.

Review image


Encoding will start and, depending on your computer specs and the length of the file, it can take between 2-3 hours or a couple of minutes. Our clip was 43 minutes long and it took about 26 minutes to finish, on an Intel Core Duo with 1 GB of RAM machine.


Review image


When the encoding is over, connect your PSP to the computer via USB and upload the .mp4 file in the 'Video' folder. Disconnect the PSP, navigate to Video menu and enjoy your movies (with subtitles).

TAGS:

PSP | video | conversion | Ubuntu | Avidemux
Read by 53,639 user(s) | Add comment | Link to this article TWEET THIS


Article rating:
Very Good (4.2/5) 16 vote(s)    

Subscribe to news | Print article | Send to friend

© Copyright 2001-2009 Softpedia
Contact:

 

 

SEARCH THE NEWS ARCHIVE :




Today's News
| Yesterday's News | News Archive


MORE RELATED ARTICLES:


How to Install Compiz Fusion on Ubuntu

Install Ubuntu from Windows in 3 Steps without Using a CD

How to Install Ubuntu 7.04 (Windows User P.O.V.)

Ubuntu Is Enterprise Friendly

Ubuntu 8.04 Is an LTS Release

Ubuntu 7.04 - Well Done

Ubuntu Studio 7.04 Released

Ubuntu Goes Mobile

User opinions:


Comment #1 by: brandonjp on 16 Dec 2007, 04:27 GMT reply to this comment

This is a great guide, except someone needs to pay a little more attention to detail when they're just writing the guide....like you need to click "configure" not "filters" and "partition decision" not "method" and "method" not "range" - other than that, it's a top notch guide and a dead simple gui for linux video conversion

Comment #1.1 by: marius.nestor on 16 Dec 2007, 08:38 GMT

We've corrected the typing errors. Thank you!


Comment #2 by: brock on 22 Feb 2008, 02:05 GMT reply to this comment

i am trying to encode an .avi file and when i go to Auto and choose either PSP or PSP (H.264) the video codec on the side is MPEG-4 ASP (Xvid4) not MPEG-4 AVC (x264) not allowing me to pick the same options in the guide
do you know how to either install the same codec or configure the inputs and settings to make the output work?


Comment #3 by: Mike on 11 Apr 2008, 21:53 GMT reply to this comment

Killer guide. Thanks ;)

I never would have thought of compiling it myself. I figured the Avidemux in the repositories was just as good as you could get from a self-compile job ^_^

However, even after following every instruction, Avidemux is still unable to handle MKV w/ AAC audio. That, I'm a little disappointed about.


Comment #4 by: Mohammed Khoory on 12 Oct 2008, 23:33 GMT reply to this comment

Finally I have found a guide to convert mkv to avi. Now I could watch anime in my psp. Or so I thought. For some reason my PSP doesn't want to read the file, saying that it's corrupted. I followed the guide like 3 times but to no avail.

So I got an old file I encoded for the psp with PSP video 9 on windows, pressed triangle, then Information. It says that the video codec is AVC. whereas if I go to the one encoded by avidemux it says it's MPEG-4 AVC. Maybe that's why it doesn't read it? I have no idea :S But please help.

Also if there was a way to do this in a batch manner I would gladly appreciate if you make a guide because anime comes in episodes :P


Comment #5 by: Wibble on 13 Oct 2008, 00:24 GMT reply to this comment

I couldn't get very far because of this;

dad@dad-desktop:~$ sudo apt-get -y install automake1.10 g gcc liba52-0.7.4 liba52-0.7.4-dev libfaac-dev libfaad2-dev libstdc 6 libgtk2.0-dev libglib2.0-dev libsdl-console-dev libxv-dev pkg-config liblame-dev libmad0-dev libvorbis-dev libxml2-dev libxvidcore4-dev subversion gettext libmozjs-dev cmake libqt4-dev libsamplerate0-dev libjack-dev libarts1-dev libx264-dev
Password:
Reading package lists... Done
Building dependency tree
Reading state information... Done
Note, selecting automake for regex ‘automake1.10’
E: Couldn't find package g
dad@dad-desktop:~$


Comment #6 by: Snak3 on 18 Dec 2008, 19:02 GMT reply to this comment

This is what my summary output displayed...
*******************
** Summary **
*******************
Gtk TRUE
Qt4
*** Video Codec ***
X264 No
Xvid4 No
*** Audio Codec ***
LAME No
FAAD No
FAAC No
Vorbis No
Aften No
libDCA No
libAMRNB No
*** Audio Device ***
ESD No
OSS Yes
ARTS No
JACK No
PULSE SIMP No
*** Misc ***
SDL No
FreeType Yes
FontConfig Yes
Gettext No
Xvideo No
samplerate No
*******************
*******************
-- Configuring done

NO NO NO and more NO's....where can I get the codecs?

Also I've got an error:

CMake Error: File /home/snak3/avidemux_2.4_branch/config.h.cmake does not exist.
CMake Error at CMakeLists.txt:201 (CONFIGURE_FILE):
configure_file Problem configuring file

so I can't issue the "make" command.

What do I do?


Comment #7 by: Marius Nestor on 18 Dec 2008, 23:49 GMT reply to this comment

For Snak3: What operating system do you have? You need to install a lot of development packages!


Comment #8 by: Ollie on 15 Feb 2009, 13:53 GMT reply to this comment

Wonderful guide, though I have a quick question:

what do you do when the subtitles don't come as a separate file? I've got an MKV file with subtitles options:
None
Eng

Seems like the subtitles are inside the MKV file itself, so how do I go about to make them show?

I managed to convert the file and both sound and image are flawless on my PSP, though I won't understand a word without subtitles.


Comment #9 by: BurntResistor on 03 Apr 2009, 01:11 GMT reply to this comment

I have unbuntu 8.10 what development packages do i need


Comment #10 by: MartinLinux on 13 Jul 2009, 03:04 GMT reply to this comment

This guide is AWESOME, I will add this article to my bookmarks.
I want to congratulate you for this and follow on this way. Thanks a lot!


Comment #11 by: Rishca on 22 Jul 2009, 00:05 GMT reply to this comment

This guide is OP!
Thanks man, now i can play with movies for my psp under Ubuntu!!

Share your opinion:

Your Name:
Your Email Address:
(will not be used for commercial purposes)
Solve this to prove you're not a bot: =
Your review/opinion:

 




Windows tabGames tabDrivers tabMac tabLinux tabScripts tabMobile tabHandheld tabGadgets tabNews tab

SUBMIT PROGRAM   |   ADVERTISE   |   GET HELP   |   SEND US FEEDBACK   |   RSS FEEDS   |   ENTER NEWS SITE   |   ENGLISH BOARD   |   ROMANIAN FORUM