On Fri, Oct 1, 2010 at 04:45, Johannes Wienke <span dir="ltr"><<a href="mailto:languitar@semipol.de">languitar@semipol.de</a>></span> wrote:<br><div class="gmail_quote"><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">

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

<br><a href="http://dev.exiv2.org/projects/exiv2/repository/entry/trunk/src/easyaccess.cpp#L252">http://dev.exiv2.org/projects/exiv2/repository/entry/trunk/src/easyaccess.cpp#L252</a><br><br>If there is a need to fix/improve/add more of these functions, let me know.<br>

<br>-ahu.<br><br>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.<br>
<br></div></div>