Skip Menu |

This queue is for tickets about the Image-ExifTool CPAN distribution.

Report information
The Basics
Id: 38708
Status: rejected
Worked: 20 min
Priority: 0/
Queue: Image-ExifTool

People
Owner: Nobody in particular
Requestors: Mario.Paumann [...] apa.at
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: 6.57
Fixed in: (no value)



Subject: Multiple IPTC Captions found
Date: Mon, 25 Aug 2008 12:57:15 +0200
To: <bug-Image-ExifTool [...] rt.cpan.org>
From: "Paumann Mario" <Mario.Paumann [...] apa.at>
Download RE09CD10.JPG
image/jpeg 606.1k

Message body is not shown because sender requested not to inline it.

Hello ! With the picture attached Exiftool finds 2xCaption-Abstract. One of the Caption-Abstract seems to be bogus. I've reproduced it with exiftool 6.90 and 7.39. exiftool -a -IPTC:Caption-Abstract RE09CD10.JPG shows Caption-Abstract : ITAR-TASS 212: KIEV, UKRAINE. AUGUST 24. Tanks roll down Khreshchatyk Street in central Kiev during a military parade on Independence Day, 24 August, 2008. (Photo ITAR-TASS / Mikhail Markiv) Caption-Abstract : Ã^cîäîâùèíà Ã^måçà âèñèìîñòè Ã^sêðà èíû. Ã^oà ðà ä. Ã^jèåâ...Ã^tîòî Ã^lèõà à ¨Ã«Ã Ã^là ðêèâà I've tested this picture with PhotoME and there was no problem. Any help would be appriciated. The picture can be also downloaded at http://mario.myphotos.cc/RE09CD10.JPG Thank you, Mario $> script/exiftool -ver 7.39 $> uname -a HP-UX apacrse2 B.11.23 U ia64 1841205320 unlimited-user license $> perl -v This is perl, v5.8.8 built for IA64.ARCHREV_0-thread-multi (with 33 registered patches, see perl -V for more detail) Copyright 1987-2006, Larry Wall Binary build 817.1 [268662] provided by ActiveState http://www.ActiveState.com Built Sep 19 2006 13:53:03
Hi Mario, PhotoME doesn't have a problem with this image because it doesn't read the FotoStation trailer. ExifTool is the only application I know (other than FotoStation) that will read this information. Unfortunately, the character encoding is very odd for this caption, and it isn't coded using a standard IPTC technique, so it shows up as gibberish.<br><br> There are a few ways around this problem:<br><br> 1) Extract only the first IPTC record using <b>-1IPTC:all</b>.<br><br> 2) Avoid reading the second IPTC record using <b>--IPTC2:all</b>.<br><br> 3) Avoid reading trailers with the <b>-fast</b> option.<br><br> 4) Delete the FotoStation trailer with <b>-fotostation:all=</b>.<br><br> - Phil
Ignore all the <br>'s in the previous message -- I was in HTML mode when I responded. :P
Subject: RE: [rt.cpan.org #38708] Multiple IPTC Captions found
Date: Mon, 25 Aug 2008 14:41:34 +0200
To: <bug-Image-ExifTool [...] rt.cpan.org>
From: "Paumann Mario" <Mario.Paumann [...] apa.at>
I'm using the exiftool lib. Any chance to do examine to where a field belongs ? foreach my $tag ($exifTool->GetFoundTags()) { my $tagname=Image::ExifTool::GetTagName($tag); my $value=$exifTool->GetValue($tag); } tagname returns e.g. 2xCaption-Abstract. How can I know if it is from IPTC, FotoStation or XMP or whatever ? Thank you, mario
You could do something like this in your loop: my $group = $exifTool->GetGroup($tag, 1); next if $group eq 'IPTC2'; Unfortunately you don't know that the second IPTC is in a FotoStation trailer, but IPTC in a trailer will come after any other IPTC. Also, to ignore trailers totally, you could set the FastScan option when extracting information.
Subject: RE: [rt.cpan.org #38708] Multiple IPTC Captions found
Date: Mon, 25 Aug 2008 15:30:43 +0200
To: <bug-Image-ExifTool [...] rt.cpan.org>
From: "Paumann Mario" <Mario.Paumann [...] apa.at>
Sorry, but another question about this : I'm using ExtractInfo and GetValue. How can I restrict GetValue to the desired Value ? e.g. GetValue("Caption-Abstract") returns any caption (iptc, xmp or fotostation iptc). How can GetValue("1IPTC:Caption-Abstract") doesn't seem to work.
Hi Mario, GetValue takes a tag key. You restrict it by passing only passing the key for the caption- abstract with the proper group as in my last example. It is possible to use GetInfo() if you really want to pass a GROUP:TAG name instead of a tag key, but in most cases it is more efficient to do the group checking yourself. I hope this helps.