taglib python bindings
Tor Hveem
tor at bash.no
Thu Jul 29 21:32:41 CEST 2004
Hi list!
A friend of mine (Eivind M. Hvidevold) and I have made it possible to generate
python bindings for taglib using SWIG, a simple makefile and a simple SWIG
instruction file.
I have these files provided in a source rpm. Just rebuild the .src.rpm to get
a binary rpm containing the bindings. SWIG generates som "ugly" warnings, but
I consider them harmless.
You can download it here: http://hveem.no/src/python-taglib-1.1-3emh.src.rpm
Scott, we would find it great if these bindings eventually could be included
in the distribution, ideally along with bindings for other languages as well.
Sample code:
from TagLib import *
fileref = FileRef("nice tune.mp3")
tag = fileref.tag()
year = tag.year()
artist = tag.artist()
genre = tag.genre()
album = tag.album()
print "%s %s %s %s" %(year, artist, album, genre)
--
Tor Hveem
More information about the taglib-devel
mailing list