Adventures in OSS with a Canon HF-10, AVCHD, and Transcoding

We bought a Canon HF-10 video camera in July, mostly to take to E3 to shoot the occasional video. It’s a great camera – small, light, easy to use, nice build quality, SDHC cards, etc.

The software that comes with it – something called ImageMixer 3 SE – is surprisingly not sucky. I mean, it still sucks in the sense that almost all OEM software does, but I was impressed that it supported three export types (DVD-quality MPEG2, iPod-quality h264 MP4, and Youtube). Unfortunately since installing the software my laptop is prone to bluescreen, but I guess that happens.

Sadly, those export options aren’t enough for me – I want more control over the formats.

So, that created the still-ongoing saga of trying to find an path to convert the camera’s native .M2TS or .MTS files into any random format (preferably h264 MPEG-4 for use in a Flash video player) – using open source software.

MediaCoder

The first thing I tried was MediaCoder, which I’ve had some success with in the past. It’s under active development by a dude in China and is relatively reliable, updated frequently with the latest versions of things like ffmpeg and x264 – so it can generally read just about anything.

I was further stoked when I read on their blog that it had AVCHD support in a recent update. Unfortunately, try as a I might, I couldn’t get it working (along with just about everyone else). You can read about some of the saga here, but the short version is I could only get it working after reading some random post on the forums with some information about specific settings.

I’ve compiled those settings into a sort-of-working MediaCoder preset profile, which you can download here:

* Download HF-10/AVCHD MediaCoder preset

Note, however, that it doesn’t work reliably for me. The longer the file the more likely it is to fail, crashing randomly at some point in the file. For short files though, it seems to work fine. I’ve posted about this on the forum.

Other OSS software:

I tried just about everything else I could find in various combinations. The only thing that came close to working was installing a recent version of ffdshow-tryout and using AviSynth and VirtualDub to read via a simple DirectShowSource script – but ffdshow looks like it still isn’t reading the AVCHD format 100% cleanly; there were a lot of visual artifacts – not enough to totally ruin it but enough to make me not want to use it.

Basically everything else I tried was the same as MediaCoder – using some variant/combination of ffmpeg, x264, mplayer, mencoder – all came close but didn’t cut the mustard.

The (sadly closed source) solution

In the end I just shelled out for a copy of the CoreAVC Professional Edition. Installed that, fired up VirtualDub and AviSynth and (using DirectShowSource again) had it working perfectly. In about 10 minutes I had a beautiful looking HD xvid encoded that made the previous weeks of effort looking for an open source solution completely wasted.

The verdict

I’m by no means a video expert, so I might have missed something. I think I know more than the average bear though, so I figure if I can’t get it working, most people aren’t going to have much of a shot.

I was about to give up and buy Nero Vision, which I think is one of the few commercial products that a) doesn’t COMPLETELY suck, b) isn’t ridiculously priced, and c) actually fucking works, but the CoreAVC option integrates happily and more effectively with the rest of my OSS tools, so I think that’ll be what I do for a while.

If you’re trying to do something similar with OSS tools, I’d give up for now and drop the ~US$15 on CoreAVC and use VirtualDub and/or other solutions that can read from a DirectShow source.

I’ll be keeping an eye on it; I’m sure it’s only a matter of time before MediaCoder (or its dependent components) are updated to work effectively.

One thought on “Adventures in OSS with a Canon HF-10, AVCHD, and Transcoding”

  1. OSS total cost of ownership = Free + 2 week’s pay => random results
    Commercial software cost = $15 + 15 minutes pay => functioning application.

    More often than not, that’s my experience too.
    Unless you have the time to tinker, or you’re doing a proper evaluation, best bet is to spend the 10 minutes up front googling up opinions of the what works then follow suit.

Leave a Reply

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