[Digikam-devel] Re: extragear/graphics/digikam/libs/dmetadata

Andreas Huggel ahuggel at gmx.net
Fri Oct 1 02:13:54 BST 2010


On Fri, Oct 1, 2010 at 04:45, Johannes Wienke <languitar at semipol.de> wrote:

> Hey,
>
> just a remark from a developer with no time left for digiKam. ;) We
> should really think about extracting these exif tag rules in an external
> file that is parsed at runtime. This is configuration knowledge that
> should be easily changeable without recompiling digikam.
>
> Regards,
> Johannes
>
> Am 30.09.2010 16:03 schrieb Gilles Caulier:
> > SVN commit 1181246 by cgilles:
> >
> > improve lens detection. add Sony id tag.
> >
> >
> >  M  +2 -1      dmetadata.cpp
> >
> >
> > --- trunk/extragear/graphics/digikam/libs/dmetadata/dmetadata.cpp
> #1181245:1181246
> > @@ -971,6 +971,7 @@
> >      lensExifTags.append("Exif.NikonLd2.LensIDNumber"); // Nikon Cameras
> Makernote.
> >      lensExifTags.append("Exif.NikonLd3.LensIDNumber"); // Nikon Cameras
> Makernote.
> >      lensExifTags.append("Exif.Minolta.LensID");        // Minolta
> Cameras Makernote.
> > +    lensExifTags.append("Exif.Sony1.LensID");          // Sony Cameras
> Makernote.
> >      lensExifTags.append("Exif.Sony2.LensID");          // Sony Cameras
> Makernote.
> >      lensExifTags.append("Exif.Pentax.LensType");       // Pentax Cameras
> Makernote.
> >      lensExifTags.append("Exif.Panasonic.0x0051");      // Panasonic
> Cameras Makernote.
>


Exiv2 has easy-access functions to deal with such selections. There is one
to select the lens without the application having to keep track of all
supported makernotes:

http://dev.exiv2.org/projects/exiv2/repository/entry/trunk/src/easyaccess.cpp#L252

If there is a need to fix/improve/add more of these functions, let me know.

-ahu.

PS: One has to be careful to make sure that code like the above doesn't
throw Exiv2 exceptions if an Exiv2 version is used that doesn't know all of
the keys listed. Which is another indicator that this is something the
library needs to deal with, not the application.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/digikam-devel/attachments/20101001/450a470d/attachment.html>


More information about the Digikam-devel mailing list