Looking for some feedback on writing EXIF tags in Python 3.



Hi hackers,

Anybody out there writing a Python 3 app that needs to be able to
manipulate photo EXIF metadata, and disappointed with the general
state of affairs? (ie, pyexiv2 only supports Python 2, and most other
EXIF libraries are read-only as far as I know).

Well, libgexiv2 is the GObject-based library used by Shotwell to read
and write EXIF metadata, and I'm experimenting with adding
introspection support to it so that languages other than Vala can also
benefit.

Anyway, I started a git repo for my work here:

https://github.com/robru/gexiv2

And you can see an overall diff of how little work was necessary here:

https://github.com/robru/gexiv2/compare/12f864af8b6dd4f550a1289830a3988b220e4794...master

BUT... I need feedback and bugtesting. As it stands, it's "good
enough" for the app I'm writing, but I only have simple needs. What
kinds of features do you need for manipulating metadata? What am I
missing? How can I improve this so it's more useful for everybody
else?

Here's an example usage with the existing code:

    from gi.repository import GExiv2

    photo = GExiv2.Metadata('IMG_2411.JPG')

    photo['Exif.Image.Make'] = 'FooCam'

    longitude, latitude, altitude = photo.get_gps_info()
    photo.set_gps_info(-113.5, 53.5, 700)

    photo.save_file()

If you'd like to see some specific features in the Python overrides
that makes it nicer for you to use, now would be a good time to let me
know what I should add, before it gets merged upstream ;-)

Thanks!

-- 
http://exolucere.ca


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]