Saturday, 29 November 2008

Bringing QuickTime to the Wii

OK so while the title is true it is rather misleading. Let me explain.

I have a web application that contains QuickTime movies (film trailers) and I wanted to make sure that if the user of the site didn't have QuickTime installed they could still see the movies. My main reason for this is that I wanted the site to work fully when viewed through the web browser on the Wii and the Wii doesn't support QuickTime.

The solution is to try and use QuickTime but if it isn't installed then to convert, on the fly (using FFmpeg), the QuickTime movie to an FLV file and then play this back in a Flash based movie player (specifically the JW FLV Player) that will work on the Wii.

Now I know that there are a number of systems available that use the web browser on the Wii to turn it into a media player but these are all huge systems with their own front and back end code and didn't seem like a reasonable starting point for what I wanted. A few people have also tried to work on a small scale and do what I wanted to achieve but from my perspective their approaches suffered from two problems 1) none of them used servlets as the back end code and I was already committed to using Tomcat and 2) they all had problems with seeking within the resulting FLV movies. So I set out to solve both of these problems.

It's taken me a few days to get something that works but I'm now happy enough with the code to release it into the wild for others to play with and improve upon. Unfortunately I can't easily show you a demo as the machine hosting this blog doesn't provide me with the ability to run server side scripts but you can download the entire example which when unzipped provides a complete Tomcat webapp.

v0.4 (08/04/2011): Updated to the newest version of JW FLV Player, fixed numerous bugs and re-factored the code to make it more flexible and maintainable. This release should be much more usable then the previous ones.

v0.3 (14/03/2010): Fixed a bug that was causing an error on the Wii and updated the JW FLV Player to the newest version. The code is now also being hosted (and built by Hudson) along with the rest of my projects.

Updated 02/12/2008: I've cleaned up a lot of the server side code to make it easier to understand and maintain. I've also updated the bundled copy of FFmpeg to a much newer build. Finally I've updated the version of the QuickTime embedding script to the newest version.

Post a Comment