$info;
}
+my %banned_tags = map { $_ => 1 }
+ qw( CodedCharacterSet ApplicationRecordVersion );
+
sub _exif_info {
my $exifTool = new Image::ExifTool;
- $exifTool->Options(Group0 => ['EXIF', 'MakerNotes', 'Composite']);
+ $exifTool->Options(Group0 => ['IPTC', 'EXIF', 'MakerNotes', 'Composite']);
my $info = $exifTool->ImageInfo(shift->path);
my $hash = {};
foreach my $tag ($exifTool->GetFoundTags('Group0')) {
+ next if $banned_tags{$tag};
my $group = $exifTool->GetGroup($tag);
my $val = $info->{$tag};
next if ref $val eq 'SCALAR';
- next if $val =~ /^[0\s]*$/;
+ next if $val =~ /^[0\s]*$/ or $val =~ /^nil$/;
$hash->{$group}->{$exifTool->GetDescription($tag)} = $val;
}
return $hash;