Playback of Matroska MKV Files on PS3 with no transcoding.

A previous post mentions some difficulties I’ve experienced trying to remux a Matroska MKV file to something that the PS3 can handle natively. I assumed that something like a standard MP4 file would be the best solution, and whilst I was close, I wasn’t quite there. It turns out that the answer was staring me right in the face.

My goal was to use the H.264 video stream that most MKV videos contain, and mux it into another container format that the PS3 could deal with, without having to use a DNLA streamer that could remux or transcode in realtime, like PS3 Media Server. Using a streamer like PS3 Media Server, or MediaLink generally makes life easier to simply watch a video, and if they’re just streaming the data, they work really well. If they’re transcoding the data, this is where things come unstuck. Simple things like subtitles may or may not be handled correctly depending on a number of factors. Also nice things, like being able to easily fast forward and rewind will being even a fast workstation to it’s knees as it tries to keep up.

Converting an MKV to MP4 was almost a workable solution. The H.264 video didn’t need to be re-encoded, saving a huge amount of time. A lot of MKV videos however have Dolby Digital (AC3) audio streams, and this isn’t supported in an MP4 container – it needs to be something like AAC instead. Transcoding the audio was not ideal, but if it worked, then it would be OK as it’s a lot quicker than transcoding the video. There are also issues with 32-bit and 64-bit files (ie, files larger than 4GB) and some of the tools I was using either didn’t work at all, or worked poorly on 64-bit files. Subtitles are also poorly supported in MP4 containers.

Back to the solution staring me in the face – Watching a blu-ray disc, the PS3 is playing back H.264 video, and can be playing back AC3 audio, and it can have subs as well. Perfect. As it turns out, blu-ray discs use the .m2ts container format, which supports everything I need. It’s natively handled on the PS3, so the DNLA streaming software only has to send the raw data down the wire, no fancy conversions required. It most commonly contains H.264 video and AC3 audio, in contrast to an MP4 which has AAC audio. It also can contain subs, and many other data formats.

Enter from stage left: tsMuxeR. This will read in an MKV, or a number of other video formats, and remux it (with no re-encoding on either the audio or video) and spit out a m2ts file that the PS3 can then play back these files with no conversions required. What’s more it’s fast as all it has to do is get the data that’s already there and put it in a new container. As an example, a 4+ GB video was converted in less than one and a half minutes.

This article was posted by Kai Howells. If you liked this content and have any technical work in the Melbourne area, say hello via my contact form or give me a call on 0419 361 653 - I cover most of the greater Melbourne area and my rates are competitive.

One Response to Playback of Matroska MKV Files on PS3 with no transcoding.

Leave a Reply

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