How to convert mkv to mp4

I’m using Ubuntu linux and would like to know how to convert mkv (
matroska ) media file to mp4 format so I can play this file on my PS3
console. It seems that MKV video format is not supported on
Playstation.

thank you

Hi,
try this:

first install prerequisites:

sudo apt-get install libav-tools gpac mkvtoolnix normalize-audio faac

then create a bash script with following content:

#!/bin/bash
audiofile=`mktemp`
videofile=`mktemp`

cd "`pwd`"

avconv -i $1 -vn -acodec pcm_s16le -ac 2 $audiofile.wav &> /dev/null
normalize-audio $audiofile.wav  &> /dev/null
faac -c 48000 -q 100 $audiofile.wav &>/dev/null
mkvextract tracks $1 1:$videofile.h264 &> /dev/null
MP4Box -fps 23.976 -add $videofile.h264 -add $audiofile.aac ${1%.*}.mp4 &> /dev/null

# cleanup
rm $audiofile $videofile

make it executable and run it with a single argument and that is a file in mkv format:

$ chmod +x mkv2mp4.sh
$ ./mkv2mp4.sh file.mkv

the above will produce a new file.mp4

hope it helps

Lubos

To convert MKV to MP4, you can try VLC, HandBrake, or Joyoshare Media Cutter. All of them are professional video editing software, giving the option to convert videos. Especially the last one, it can help to convert MKV to MP4 without quality loss.

These days there is a really good desktop application called winff, which is a front end for ffmpeg the codec transcoding application. It comes with a Qt gui and a Gtk2 gui, on Debain based distro’s it should be something like winff-qt or winff-gtk2. Once installed follow the help instructions and you should be good to go.

Yes, PS3 can’t handle MKV files.
You are wise to know to find a video converter.
Before you find the video converter, you need to know what kind of video formats supported by PS3.
PS3 supported formats are displayed on the official sites, you can check them there.
Also, you have to know which video converter supports Ubuntu Linux.
After that, the video converter which is compatible with Ubuntu Linux and can convert MKV to PS3 supported formats like MP4 includes: online converter CloudConvert, media player VLC, desktop software WinX Video Converter, open-source tool Handbrake, and the like.
You can choose the one you like most.