So, Akademy 2012 is over. A huge thanks to everyone involved, it has been amazing. Met a lot of friends, made many new ones, attended really interesting talks about varied subjects, attended even more varied BoFs, hacked and partied. Even attended the start of the QtQuick workshop (but had to leave for the Phonon BoF before they started handing out N9s :P). A huge thanks also to the KDE e. V. so that I could attend (even without a paying job).
The most interesting results of Akademy are probably the plans for Phonon 5 (and the rest of the discussion about Phonon), the plans for KDE multimedia in general, and I finally managed to revive carewolf’s avkode project. Which is so interesting that it’ll get its own paragraphs.
Some of you may remember the aKode project from KDE 3 times, which was an audio playback framework made by Allan Sandfeld Jensen. What not so many people know is that he started working on a sibling during the KDE 4.0 times, which also supported video playback, with a corresponding Phonon backend. Unfortunately he got busy with Real Life™, and avkode was left alone in SVN for many, many years. Then along came a bored Sandsmark and first got it to build, updated it to not use outdated ffmpeg API, and rewrote most of the Phonon backend (it was written before the final version of Phonon was release, apparently, so it didn’t really match with how things are done nowadays). Then at Akademy Allan and I sat down and hacked on it a bit, to the point where I am now using it as my main Phonon backend (it seems to work well in JuK, Dragon, Amarok, file dialog previews, etc.).
I started looking into creating a tiny, minimal Phonon backend, for many reasons; firstly we are now working towards Phonon 5, so I wanted to get a fresh look on how the backend/frontend integration works, and I also got a bit tired of working around bugs in the frameworks Phonon are using. Making a backend that uses ffmpeg/xv/alsa-lib/etc. directly has been something I’ve wanted to look into for a long while now. And when I finally sat down, and looked at aKode for inspiration, I found that Allan had already done most of the work needed. So now we have a pretty minimal Phonon backend (it only depends on Qt, ffmpeg, libxv and alsa-lib), though it doesn’t support most of the advanced features available in other backends (like painting on anything other than the normal VideoWidget).
For now the code is at http://quickgit.kde.org/index.php?p=scratch/sandsmark/avkode.git&a=summary
It is still kind of rough around the edges, and will probably stay like that for a while, as I plan on working more on VLC (I have plans for a KIO access module for example, so we can avoid the ugly platform plugin kio hackery with phonon-vlc). I give no guarantees for it (I’m not even sure it builds on many major distributions at all, since they apparently have started shipping the libav fork instead of proper ffmpeg). And it has no website, logo or documentation for now, though I did put up a PKGBUILD for Arch in the AUR.
Another thing that you’ll notice with avkode is that when using it playback progress bars should be smooth, since it has spatial tick emission (not properly, it assumes that all progress bars are 1024 pixels for now). Spatial tick emission is a fancy name I made up on the spot, where instead of always emitting a progress tick at fixed intervals it emits a fixed amount of ticks per media object, independent of how long it is, so that an application can get pixel-perfect progress bars.