Wednesday, June 10, 2009

gmerlin video thumbnailer

The project
The goal of this 2-day project was to write a gmerlin based video thumbnailer, which fails for fewer files than the gstreamer based thumbnailer shipped with Ubuntu. The result is a small (less than 350 lines) program, which takes a video file as argument and produces a small png preview. All required functionality was already available in gmerlin and gavl.

How to try
If you want, you can check out and install the latest gmerlin CVS. Make sure that gmerlin is compiled with libpng support. The program is called gmerlin-video-thumbnailer. To enable gmerlin thumbnails in nautilus, open gconf-editor and go to /desktop/gnome/thumbnailers. For each mimetype, you have a directory. In each directory, you have a key called command. For each mimetype you want to be thumbnailed by gmerlin, simply change the command to

/usr/local/bin/gmerlin-video-thumbnailer -s %s %i %o

Of course you must change /usr/local to the prefix where you installed gmerlin.

Bugs fixed
The thumbnailer quickly exposed some bugs in gmerlin-avdecoder and gavl. Looking at a nautilus window full of thumbnails is faster than playing 100s of movie files. 3 major bugs were fixed, one minor bug will get fixed before the next release.

The thumbnail standard, which seems to be used by gnome, is here. How thumbnailers are installed in gnome, is described here.

No comments: