exiftool_vendored 11.52.0 → 11.53.0

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of exiftool_vendored might be problematic. Click here for more details.

checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 708b8f54e7785c774043632d9e5dcefe98ae0a8d
4
- data.tar.gz: 1d0693dcecc6c821a9ae9aab22427cd42d63ea8a
3
+ metadata.gz: 97fbb02d04f7a13c79740ef2c0ca3aa5397dbb8f
4
+ data.tar.gz: a0bdb72ec276cfc6612f9551fd78f681352f1853
5
5
  SHA512:
6
- metadata.gz: 457d788e530ab3b621d414c6ad4c23bac4427b584886f5667cb1b3865dcd6ec77897a944a6b7ff5820e03e955826f37bd42c80269a75f30f47481ff5aec27ec4
7
- data.tar.gz: dc5b34c896e756158c04c3ceb286746fe813fd2b0a1f37aca9faa517df5ce4706c53fc38e514647ed845d1bdbf519d2d2618087e8dcb6b84084ff0c82eba4e9e
6
+ metadata.gz: c8771355f5818b9bb5720b8a3caa567b111fa6582120519746658e03135b3df367b4c861a9b40eb7c274d36e858ac96949c1c3e4063162a27251a85537853f72
7
+ data.tar.gz: 128d993de5cb91c2e8929893d8cc6481c446203de05f0f8807e41aaa3131a76152b34e825a36d472b98a7939fceb64234b298e0c01ecaf669f9261aee7975464
@@ -7,11 +7,30 @@ RSS feed: http://owl.phy.queensu.ca/~phil/exiftool/rss.xml
7
7
  Note: The most recent production release is Version 11.50. (Other versions are
8
8
  considered development releases, and are not uploaded to CPAN.)
9
9
 
10
+ June 24, 2019 - Version 11.53 - "Exif 2.32"
11
+
12
+ - Added support for the new tags of the Exif 2.32 specification
13
+ - Added a new SamsungModelID (thanks LibRaw)
14
+ - Added warning if extracting ZIP file contents without the -a option
15
+ - Added ability to extract EmbeddedVideo from the trailer of Android JPEG
16
+ images with the ExtractEmbedded option
17
+ - Decode timed GPS from Cobra Dash Cam AVI videos
18
+ - Decode a new GoPro tag
19
+ - Enhanced -struct option to allow extraction of structured Torrent Info
20
+ - Improved error handling when an unexpected terminator is encountered while
21
+ writing a QuickTime-format file
22
+ - Renamed one of the Nikon Saturation tags to "SaturationAdj"
23
+ - Removed warning message when writing FujiFilm RAFVersion 0240 and 0261 files
24
+ - Fixed encoding problem when writing some QuickTime UserData tags with
25
+ strings containing special characters
26
+ - API Changes:
27
+ - Enhanced XMPShorthand option to add level 2
28
+
10
29
  June 17, 2019 - Version 11.52
11
30
 
12
31
  - Added a few new Nikon CropHiSpeed values (thanks Hayo Baan)
13
- - Added a couple of new Nikon LensID's
14
- - Fixed problem where processing large, corrupt AIFF files may could take an
32
+ - Added a new Nikon LensID (thanks Yves)
33
+ - Fixed problem where reading a large, corrupt AIFF file may could take an
15
34
  excessively long time
16
35
  - API Changes:
17
36
  - Enhanced Compact option to add levels 3, 4 and 5
@@ -47,6 +47,6 @@
47
47
  }
48
48
  },
49
49
  "release_status" : "stable",
50
- "version" : "11.52",
50
+ "version" : "11.53",
51
51
  "x_serialization_backend" : "JSON::PP version 4.02"
52
52
  }
@@ -28,5 +28,5 @@ recommends:
28
28
  Time::HiRes: '0'
29
29
  requires:
30
30
  perl: '5.004'
31
- version: '11.52'
31
+ version: '11.53'
32
32
  x_serialization_backend: 'CPAN::Meta::YAML version 0.018'
data/bin/README CHANGED
@@ -104,8 +104,8 @@ your home directory, then you would type the following commands in a
104
104
  terminal window to extract and run ExifTool:
105
105
 
106
106
  cd ~/Desktop
107
- gzip -dc Image-ExifTool-11.52.tar.gz | tar -xf -
108
- cd Image-ExifTool-11.52
107
+ gzip -dc Image-ExifTool-11.53.tar.gz | tar -xf -
108
+ cd Image-ExifTool-11.53
109
109
  ./exiftool t/images/ExifTool.jpg
110
110
 
111
111
  Note: These commands extract meta information from one of the test images.
@@ -12,7 +12,7 @@
12
12
  use strict;
13
13
  require 5.004;
14
14
 
15
- my $version = '11.52';
15
+ my $version = '11.53';
16
16
 
17
17
  # add our 'lib' directory to the include list BEFORE 'use Image::ExifTool'
18
18
  my $exeDir;
@@ -5119,7 +5119,7 @@ with this command:
5119
5119
 
5120
5120
  produces output like this:
5121
5121
 
5122
- -- Generated by ExifTool 11.52 --
5122
+ -- Generated by ExifTool 11.53 --
5123
5123
  File: a.jpg - 2003:10:31 15:44:19
5124
5124
  (f/5.6, 1/60s, ISO 100)
5125
5125
  File: b.jpg - 2006:05:23 11:57:38
@@ -7,7 +7,7 @@
7
7
  #
8
8
  # Revisions: Nov. 12/2003 - P. Harvey Created
9
9
  # (See html/history.html for revision history)
10
- #
10
+ #2.32
11
11
  # Legal: Copyright (c) 2003-2019, Phil Harvey (phil at owl.phy.queensu.ca)
12
12
  # This library is free software; you can redistribute it and/or
13
13
  # modify it under the same terms as Perl itself.
@@ -27,7 +27,7 @@ use vars qw($VERSION $RELEASE @ISA @EXPORT_OK %EXPORT_TAGS $AUTOLOAD @fileTypes
27
27
  %mimeType $swapBytes $swapWords $currentByteOrder %unpackStd
28
28
  %jpegMarker %specialTags %fileTypeLookup);
29
29
 
30
- $VERSION = '11.52';
30
+ $VERSION = '11.53';
31
31
  $RELEASE = '';
32
32
  @ISA = qw(Exporter);
33
33
  %EXPORT_TAGS = (
@@ -1662,6 +1662,7 @@ my %systemTagsNotes = (
1662
1662
  commas, eg. C<-ForceWrite=exif,xmp>
1663
1663
  },
1664
1664
  },
1665
+ EmbeddedVideo => { Groups => { 2 => 'Video' } },
1665
1666
  );
1666
1667
 
1667
1668
  # YCbCrSubSampling values (used by JPEG SOF, EXIF and XMP)
@@ -2108,7 +2109,7 @@ sub ClearOptions($)
2108
2109
  CharsetPhotoshop => 'Latin', # internal encoding for Photoshop resource names
2109
2110
  CharsetQuickTime => 'MacRoman', # internal QuickTime string encoding
2110
2111
  CharsetRIFF => 0, # internal RIFF string encoding (0=default to Latin)
2111
- Compact => undef, # compact XMP and IPTC data
2112
+ Compact => 0, # write compact XMP
2112
2113
  Composite => 1, # flag to calculate Composite tags
2113
2114
  Compress => undef, # flag to write new values as compressed if possible
2114
2115
  CoordFormat => undef, # GPS lat/long coordinate format
@@ -5974,29 +5975,50 @@ sub ProcessJPEG($$)
5974
5975
  # we are here because we are looking for trailer information
5975
5976
  if ($wantTrailer) {
5976
5977
  my $start = $$self{PreviewImageStart};
5977
- if ($start) {
5978
+ if ($start or $$options{ExtractEmbedded}) {
5978
5979
  my $buff;
5979
5980
  # most previews start right after the JPEG EOI, but the Olympus E-20
5980
5981
  # preview is 508 bytes into the trailer, the K-M Maxxum 7D preview is
5981
5982
  # 979 bytes in, and Sony previews can start up to 32 kB into the trailer.
5982
5983
  # (and Minolta and Sony previews can have a random first byte...)
5983
5984
  my $scanLen = $$self{Make} =~ /Sony/i ? 65536 : 1024;
5984
- if ($raf->Read($buff, $scanLen) and ($buff =~ /\xff\xd8\xff./g or
5985
- ($$self{Make} =~ /(Minolta|Sony)/i and $buff =~ /.\xd8\xff\xdb/g)))
5986
- {
5987
- # adjust PreviewImageStart to this location
5988
- my $actual = $pos + pos($buff) - 4;
5989
- if ($start ne $actual and $verbose > 1) {
5990
- print $out "(Fixed PreviewImage location: $start -> $actual)\n";
5991
- }
5992
- # update preview image offsets
5993
- $$self{VALUE}{PreviewImageStart} = $actual if $$self{VALUE}{PreviewImageStart};
5994
- $$self{PreviewImageStart} = $actual;
5995
- # load preview now if we tried and failed earlier
5996
- if ($$self{PreviewError} and $$self{PreviewImageLength}) {
5997
- if ($raf->Seek($actual, 0) and $raf->Read($buff, $$self{PreviewImageLength})) {
5998
- $self->FoundTag('PreviewImage', $buff);
5999
- delete $$self{PreviewError};
5985
+ if ($raf->Read($buff, $scanLen)) {
5986
+ if ($buff =~ /^.{4}ftyp/s) {
5987
+ my $val;
5988
+ if ($raf->Seek(0,2)) {
5989
+ my $len = $raf->Tell() - $pos;
5990
+ if ($$options{Binary}) {
5991
+ $val = \$buff if $raf->Seek($pos,0) and $raf->Read($buff,$len)==$len;
5992
+ } else {
5993
+ $val = "(Binary data $len bytes)";
5994
+ }
5995
+ if ($val) {
5996
+ $self->FoundTag('EmbeddedVideo', $val);
5997
+ } else {
5998
+ $self->Warn('Error reading trailer');
5999
+ }
6000
+ } else {
6001
+ $self->Warn('Error seeking to end of file');
6002
+ }
6003
+ } elsif ($buff =~ /\xff\xd8\xff./g or
6004
+ ($$self{Make} =~ /(Minolta|Sony)/i and $buff =~ /.\xd8\xff\xdb/g))
6005
+ {
6006
+ # adjust PreviewImageStart to this location
6007
+ my $actual = $pos + pos($buff) - 4;
6008
+ if ($start and $start ne $actual and $verbose > 1) {
6009
+ print $out "(Fixed PreviewImage location: $start -> $actual)\n";
6010
+ }
6011
+ # update preview image offsets
6012
+ if ($start) {
6013
+ $$self{VALUE}{PreviewImageStart} = $actual if $$self{VALUE}{PreviewImageStart};
6014
+ $$self{PreviewImageStart} = $actual;
6015
+ }
6016
+ # load preview now if we tried and failed earlier
6017
+ if ($$self{PreviewError} and $$self{PreviewImageLength}) {
6018
+ if ($raf->Seek($actual, 0) and $raf->Read($buff, $$self{PreviewImageLength})) {
6019
+ $self->FoundTag('PreviewImage', $buff);
6020
+ delete $$self{PreviewError};
6021
+ }
6000
6022
  }
6001
6023
  }
6002
6024
  }
@@ -6047,7 +6069,7 @@ sub ProcessJPEG($$)
6047
6069
  # only if we can't finish without scanning from end of file)
6048
6070
  $self->ProcessTrailers($trailInfo) and undef $trailInfo;
6049
6071
  }
6050
- if ($wantTrailer) {
6072
+ if ($wantTrailer and $$self{PreviewImageStart}) {
6051
6073
  # seek ahead and validate preview image
6052
6074
  my $buff;
6053
6075
  my $curPos = $raf->Tell();
@@ -6064,6 +6086,8 @@ sub ProcessJPEG($$)
6064
6086
  require Image::ExifTool::Panasonic;
6065
6087
  Image::ExifTool::Panasonic::ProcessLeicaTrailer($self);
6066
6088
  $wantTrailer = 1 if $$self{LeicaTrailer};
6089
+ } else {
6090
+ $wantTrailer = 1 if $$options{ExtractEmbedded};
6067
6091
  }
6068
6092
  next if $trailInfo or $wantTrailer or $verbose > 2 or $htmlDump;
6069
6093
  }
@@ -537,7 +537,7 @@ When set to 2, spaces to indent XMP for readability are also dropped. A
537
537
  setting of 3 places all tags in a single rdf:Description element, and 4
538
538
  removes newlines from between XMP elements. A setting of 5 also writes XMP
539
539
  in shorthand format (to save setting the XMPShorthand option separately).
540
- Default is undef.
540
+ Default is 0.
541
541
 
542
542
  =item Composite
543
543
 
@@ -1001,7 +1001,8 @@ look like rational numbers or dates. Default is 1.
1001
1001
 
1002
1002
  =item XMPShorthand
1003
1003
 
1004
- Flag set to write xmp in shorthand format. Default is undef.
1004
+ Set to 1 to write xmp in shorthand format, or 2 to also combine properties
1005
+ into a single rdf:Description element. Default is 0.
1005
1006
 
1006
1007
  =back
1007
1008
 
@@ -256,11 +256,11 @@ tags remain.
256
256
 
257
257
  The table below lists all EXIF tags. Also listed are TIFF, DNG, HDP and
258
258
  other tags which are not part of the EXIF specification, but may co-exist
259
- with EXIF tags in some images. Tags which are part of the EXIF 2.31
259
+ with EXIF tags in some images. Tags which are part of the EXIF 2.32
260
260
  specification have an underlined B<Tag Name> in the HTML version of this
261
261
  documentation. See
262
- L<http://www.cipa.jp/std/documents/e/DC-008-Translation-2016-E.pdf> for the
263
- official EXIF 2.31 specification.
262
+ L<http://www.cipa.jp/std/documents/e/DC-008-Translation-2019-E.pdf> for the
263
+ official EXIF 2.32 specification.
264
264
  },
265
265
  GPS => q{
266
266
  These GPS tags are part of the EXIF standard, and are stored in a separate
@@ -55,7 +55,7 @@ use vars qw($VERSION $AUTOLOAD @formatSize @formatName %formatNumber %intFormat
55
55
  use Image::ExifTool qw(:DataAccess :Utils);
56
56
  use Image::ExifTool::MakerNotes;
57
57
 
58
- $VERSION = '4.16';
58
+ $VERSION = '4.17';
59
59
 
60
60
  sub ProcessExif($$$);
61
61
  sub WriteExif($$$);
@@ -1975,7 +1975,8 @@ my %sampleFormat = (
1975
1975
  Writable => 'undef',
1976
1976
  Mandatory => 1,
1977
1977
  RawConv => '$val=~s/\0+$//; $val', # (some idiots add null terminators)
1978
- PrintConvInv => '$val=~tr/.//d; $val=~/^\d{4}$/ ? $val : undef',
1978
+ # (allow strings like "2.31" when writing)
1979
+ PrintConvInv => '$val=~tr/.//d; $val=~/^\d{4}$/ ? $val : $val =~ /^\d{3}$/ ? "0$val" : undef',
1979
1980
  },
1980
1981
  0x9003 => {
1981
1982
  Name => 'DateTimeOriginal',
@@ -2699,6 +2700,74 @@ my %sampleFormat = (
2699
2700
  0xa433 => { Name => 'LensMake', Writable => 'string' }, #24
2700
2701
  0xa434 => { Name => 'LensModel', Writable => 'string' }, #24
2701
2702
  0xa435 => { Name => 'LensSerialNumber', Writable => 'string' }, #24
2703
+ 0xa460 => { #Exif2.32
2704
+ Name => 'CompositeImage',
2705
+ Writable => 'int16u',
2706
+ PrintConv => {
2707
+ 1 => 'No',
2708
+ 2 => 'General Composite Image',
2709
+ 3 => 'Composite Image Captured While Shooting',
2710
+ },
2711
+ },
2712
+ 0xa461 => { #Exif2.32
2713
+ Name => 'CompositeImageCount',
2714
+ Notes => q{
2715
+ 2 values: number of source images and the number of images used. Called
2716
+ SourceImageNumberOfCompositeImage by the EXIF spec.
2717
+ },
2718
+ Writable => 'int16u',
2719
+ Count => 2,
2720
+ },
2721
+ 0xa462 => { #Exif2.32
2722
+ Name => 'CompositeImageExposureTimes',
2723
+ Notes => q{
2724
+ 9 or more values: 1. total exposure time period, 2. total exposure of all
2725
+ source images, 3. total exposure of all used images, 4. Max exposure time of
2726
+ source images, 5. Max exposure time of used images, 6. Min exposure time of
2727
+ source images, 7. Min exposure of used images, 8. Number of sequences, 9.
2728
+ Number of source images in sequence. 10-N. Exposure times of each source
2729
+ image. Called SourceExposureTimesOfCompositeImage by the EXIF spec.
2730
+ },
2731
+ Writable => 'undef',
2732
+ RawConv => sub {
2733
+ my $val = shift;
2734
+ my @v;
2735
+ my $i = 0;
2736
+ for (;;) {
2737
+ if ($i == 56 or $i == 58) {
2738
+ last if $i + 2 > length $val;
2739
+ push @v, Get16u(\$val, $i);
2740
+ $i += 2;
2741
+ } else {
2742
+ last if $i + 8 > length $val;
2743
+ push @v, Image::ExifTool::GetRational64u(\$val, $i);
2744
+ $i += 8;
2745
+ }
2746
+ }
2747
+ return join ' ', @v;
2748
+ },
2749
+ RawConvInv => sub {
2750
+ my $val = shift;
2751
+ my @v = split ' ', $val;
2752
+ my $i;
2753
+ for ($i=0; ; ++$i) {
2754
+ last unless defined $v[$i];
2755
+ $v[$i] = ($i == 7 or $i == 8) ? Set16u($v[$i]) : Image::ExifTool::SetRational64u($v[$i]);
2756
+ }
2757
+ return join '', @v;
2758
+ },
2759
+ PrintConv => sub {
2760
+ my $val = shift;
2761
+ my @v = split ' ', $val;
2762
+ my $i;
2763
+ for ($i=0; ; ++$i) {
2764
+ last unless defined $v[$i];
2765
+ $v[$i] = PrintExposureTime($v[$i]) unless $i == 7 or $i == 8;
2766
+ }
2767
+ return join ' ', @v;
2768
+ },
2769
+ PrintConvInv => '$val',
2770
+ },
2702
2771
  0xa480 => { Name => 'GDALMetadata', Writable => 'string', WriteGroup => 'IFD0' }, #3
2703
2772
  0xa481 => { Name => 'GDALNoData', Writable => 'string', WriteGroup => 'IFD0' }, #3
2704
2773
  0xa500 => { Name => 'Gamma', Writable => 'rational64u' },
@@ -30,7 +30,7 @@ use vars qw($VERSION);
30
30
  use Image::ExifTool qw(:DataAccess :Utils);
31
31
  use Image::ExifTool::Exif;
32
32
 
33
- $VERSION = '1.71';
33
+ $VERSION = '1.72';
34
34
 
35
35
  sub ProcessFujiDir($$$);
36
36
  sub ProcessFaceRec($$$);
@@ -53,8 +53,10 @@ my %testedRAF = (
53
53
  '0212' => 'S3Pro Ver2.12',
54
54
  '0216' => 'S3Pro Ver2.16', # (NC)
55
55
  '0218' => 'S3Pro Ver2.18',
56
+ '0240' => 'X-E1 Ver2.40',
56
57
  '0264' => 'F700 Ver2.00',
57
58
  '0266' => 'S9500 Ver1.01',
59
+ '0261' => 'X-E1 Ver2.61',
58
60
  '0269' => 'S9500 Ver1.02',
59
61
  '0271' => 'S3Pro Ver2.71', # UV/IR model?
60
62
  '0300' => 'X-E2',
@@ -16,7 +16,7 @@ use vars qw($VERSION);
16
16
  use Image::ExifTool qw(:DataAccess :Utils);
17
17
  use Image::ExifTool::QuickTime;
18
18
 
19
- $VERSION = '1.02';
19
+ $VERSION = '1.03';
20
20
 
21
21
  sub ProcessGoPro($$$);
22
22
  sub ProcessString($$$);
@@ -78,7 +78,7 @@ my %addUnits = (
78
78
  Binary => 1,
79
79
  },
80
80
  ALLD => 'AutoLowLightDuration', #1 (gpmd) (untested)
81
- # APTO (GPMF) - seen: 'RAW' (fmt c)
81
+ # APTO (GPMF) - seen: 'RAW', 'DYNM' (fmt c)
82
82
  ATTD => { #PH (Karma)
83
83
  Name => 'Attitude',
84
84
  # UNIT=s,rad,rad,rad,rad/s,rad/s,rad/s,
@@ -94,7 +94,7 @@ my %addUnits = (
94
94
  Binary => 1,
95
95
  },
96
96
  AUDO => 'AudioSetting', #PH (GPMF - seen: 'WIND', fmt c)
97
- # AUPT (GPMF) - seen: 'N' (fmt c)
97
+ # AUPT (GPMF) - seen: 'N','Y' (fmt c)
98
98
  BPOS => { #PH (Karma)
99
99
  Name => 'Controller',
100
100
  Unknown => 1,
@@ -104,9 +104,9 @@ my %addUnits = (
104
104
  %addUnits,
105
105
  },
106
106
  # BRID (GPMF) - seen: 0 (fmt B)
107
- # BROD (GPMF) - seen: 'ASK' (fmt c)
107
+ # BROD (GPMF) - seen: 'ASK','' (fmt c)
108
108
  CASN => 'CameraSerialNumber', #PH (GPMF - seen: 'C3221324545448', fmt c)
109
- # CINF (GPMF) - seen: 0x67376be7709bc8876a8baf3940908618 (fmt B)
109
+ # CINF (GPMF) - seen: 0x67376be7709bc8876a8baf3940908618 (fmt B) (Camera INFormation?)
110
110
  # CMOD (GPMF) - seen: 12,13,17 [13 time-laps video, 17 JPEG] (fmt B)
111
111
  CYTS => { #PH (Karma)
112
112
  Name => 'CoyoteStatus',
@@ -130,13 +130,15 @@ my %addUnits = (
130
130
  DVID => { Name => 'DeviceID', Unknown => 1 }, #2 (gpmd)
131
131
  # DVNM (GPMF) seen: 'Video Global Settings' (fmt c), 'Highlights' (fmt c)
132
132
  # DVNM (gpmd) seen: 'Camera' (Hero5), 'Hero6 Black' (Hero6), 'GoPro Karma v1.0' (Karma)
133
- DVNM => 'DeviceName', #PH
133
+ DVNM => 'DeviceName', #PH (n/c)
134
134
  DZOM => { #PH (GPMF - seen: 'Y', fmt c)
135
135
  Name => 'DigitalZoom',
136
136
  PrintConv => { N => 'No', Y => 'Yes' },
137
137
  },
138
138
  # DZST (GPMF) - seen: 0 (fmt L) (something to do with digital zoom maybe?)
139
- # EISA (GPMF) - seen: 'Y','N' [N was for a time-lapse video] (fmt c)
139
+ EISA => { #PH (GPMF) - seen: 'Y','N', 'HS EIS' (fmt c) [N was for a time-lapse video]
140
+ Name => 'ElectronicImageStabilization',
141
+ },
140
142
  # EISE (GPMF) - seen: 'Y' (fmt c)
141
143
  EMPT => { Name => 'Empty', Unknown => 1 }, #2 (gpmd)
142
144
  ESCS => { #PH (Karma)
@@ -147,7 +149,7 @@ my %addUnits = (
147
149
  Unknown => 1,
148
150
  %addUnits,
149
151
  },
150
- # EXPT (GPMF) - seen: '' (fmt c)
152
+ # EXPT (GPMF) - seen: '', 'AUTO' (fmt c)
151
153
  FACE => 'FaceDetected', #PH (gpmd)
152
154
  FCNM => 'FaceNumbers', #PH (gpmd) (faces counted per frame, ref 1)
153
155
  FMWR => 'FirmwareVersion', #PH (GPMF - seen: HD6.01.01.51.00, fmt c)
@@ -213,7 +215,7 @@ my %addUnits = (
213
215
  RawConv => '$val', # necessary to use scaled value instead of raw data as subdir data
214
216
  SubDirectory => { TagTable => 'Image::ExifTool::GoPro::KBAT' },
215
217
  },
216
- # LINF (GPMF) - seen: LAJ7061916601668 (fmt c)
218
+ # LINF (GPMF) - seen: LAJ7061916601668 (fmt c) (Lens INFormation?)
217
219
  LNED => { #PH (Karma)
218
220
  Name => 'LocalPositionNED',
219
221
  # UNIT=s,m,m,m,m/s,m/s,m/s
@@ -241,7 +243,7 @@ my %addUnits = (
241
243
  PHDR => 'HDRSetting', #PH (APP6 - seen: 0)
242
244
  PIMN => 'AutoISOMin', #PH (GPMF - seen: 100, fmt L)
243
245
  PIMX => 'AutoISOMax', #PH (GPMF - seen: 1600, fmt L)
244
- # PRAW (APP6) - seen: 0
246
+ # PRAW (APP6) - seen: 0, 'N' (fmt c)
245
247
  PRES => 'PhotoResolution', #PH (APP6 - seen: '12MP_W')
246
248
  PRTN => { #PH (GPMF - seen: 'N', fmt c)
247
249
  Name => 'ProTune',
@@ -348,7 +350,7 @@ my %addUnits = (
348
350
  # UNIT=m/s,m/s,m,m/s,deg,%
349
351
  # TYPE=ffffsS
350
352
  },
351
- # VLTE (GPMF) - seen: 'Y' (fmt c)
353
+ # VLTE (GPMF) - seen: 'Y','N' (fmt c)
352
354
  WBAL => 'ColorTemperatures', #PH (gpmd)
353
355
  WRGB => { #PH (gpmd)
354
356
  Name => 'WhiteBalanceRGB',
@@ -239,6 +239,10 @@ sub ProcessJPEG_HDR($$$);
239
239
  Name => 'PreviewImage',
240
240
  Condition => '$$valPt =~ /^\xff\xd8\xff/',
241
241
  Writable => 1, # (for docs only)
242
+ }, {
243
+ Name => 'EmbeddedVideo',
244
+ Notes => 'extracted only when ExtractEmbedded option is used',
245
+ Condition => '$$valPt =~ /^.{4}ftyp/s',
242
246
  }],
243
247
  );
244
248
 
@@ -60,7 +60,7 @@ use Image::ExifTool qw(:DataAccess :Utils);
60
60
  use Image::ExifTool::Exif;
61
61
  use Image::ExifTool::GPS;
62
62
 
63
- $VERSION = '3.65';
63
+ $VERSION = '3.66';
64
64
 
65
65
  sub LensIDConv($$$);
66
66
  sub ProcessNikonAVI($$$);
@@ -574,7 +574,6 @@ sub GetAFPointGrid($$;$);
574
574
  'F7 53 5C 80 24 24 84 06' => 'Tamron SP AF 70-200mm f/2.8 Di LD (IF) Macro (A001)',
575
575
  'FE 53 5C 80 24 24 84 06' => 'Tamron SP AF 70-200mm f/2.8 Di LD (IF) Macro (A001)',
576
576
  'F7 53 5C 80 24 24 40 06' => 'Tamron SP AF 70-200mm f/2.8 Di LD (IF) Macro (A001)',
577
- 'E2 47 5C 80 24 24 DF 4E' => 'Tamron SP 70-200mm f/2.8 Di VC USD G2 (A025)', #30
578
577
  # 'FE 54 5C 80 24 24 DF 0E' => 'Tamron SP AF 70-200mm f/2.8 Di VC USD (A009)',
579
578
  'FE 54 5C 80 24 24 DF 0E' => 'Tamron SP 70-200mm f/2.8 Di VC USD (A009)', #NJ
580
579
  'E2 47 5C 80 24 24 DF 4E' => 'Tamron SP 70-200mm f/2.8 Di VC USD G2 (A025)', #forum9549
@@ -1786,7 +1785,7 @@ my %binaryDataAttrs = (
1786
1785
  9 => 'Packed 12 bits', #IB (2 pixels in 3 bytes)
1787
1786
  },
1788
1787
  },
1789
- 0x0094 => { Name => 'Saturation', Writable => 'int16s' },
1788
+ 0x0094 => { Name => 'SaturationAdj', Writable => 'int16s' },
1790
1789
  0x0095 => { Name => 'NoiseReduction', Writable => 'string' }, # ("Off" or "FPNR"=long exposure NR)
1791
1790
  0x0096 => {
1792
1791
  Name => 'NEFLinearizationTable', # same table as DNG LinearizationTable (ref JD)
@@ -29,7 +29,7 @@ use strict;
29
29
  use vars qw($VERSION);
30
30
  use Image::ExifTool qw(:DataAccess :Utils);
31
31
 
32
- $VERSION = '1.51';
32
+ $VERSION = '1.52';
33
33
 
34
34
  sub ConvertTimecode($);
35
35
  sub ProcessSGLT($$$);
@@ -534,6 +534,32 @@ my %code2charset = (
534
534
  ProcessProc => \&ProcessSLLT,
535
535
  },
536
536
  },
537
+ #
538
+ # tags found in an AlphaImagingTech AVI video - PH
539
+ #
540
+ LIST_INF0 => { # ('0' instead of 'O' -- odd)
541
+ Name => 'Info',
542
+ SubDirectory => { TagTable => 'Image::ExifTool::RIFF::Info' },
543
+ },
544
+ gps0 => {
545
+ Name => 'GPSTrack',
546
+ SetGroups => 'RIFF', # (moves "QuickTime" tags to the "RIFF" group)
547
+ SubDirectory => {
548
+ TagTable => 'Image::ExifTool::QuickTime::Stream',
549
+ # (don't use code ref here or get "Prototype mismatch" warning with some Perl versions)
550
+ ProcessProc => 'Image::ExifTool::QuickTime::Process_gps0',
551
+ },
552
+ },
553
+ gsen => {
554
+ Name => 'GSensor',
555
+ SetGroups => 'RIFF', # (moves "QuickTime" tags to the "RIFF" group)
556
+ SubDirectory => {
557
+ TagTable => 'Image::ExifTool::QuickTime::Stream',
558
+ ProcessProc => 'Image::ExifTool::QuickTime::Process_gsen',
559
+ },
560
+ },
561
+ # gpsa - seen hex "01 20 00 00", same as QuickTime
562
+ # gsea - 16 bytes hex "04 08 02 00 20 02 00 00 1f 03 00 00 01 00 00 00"
537
563
  );
538
564
 
539
565
  # the maker notes used by some digital cameras
@@ -1432,8 +1458,7 @@ sub MakeTagInfo($$)
1432
1458
 
1433
1459
  #------------------------------------------------------------------------------
1434
1460
  # Process RIFF chunks
1435
- # Inputs: 0) ExifTool object reference, 1) directory information reference
1436
- # 2) tag table reference
1461
+ # Inputs: 0) ExifTool ref, 1) dirInfo ref, 2) tag table ref
1437
1462
  # Returns: 1 on success
1438
1463
  sub ProcessChunks($$$)
1439
1464
  {
@@ -1661,9 +1686,14 @@ sub ProcessRIFF($$)
1661
1686
  }
1662
1687
  # RIFF chunks are padded to an even number of bytes
1663
1688
  my $len2 = $len + ($len & 0x01);
1664
- if ($$tagTbl{$tag} or (($verbose or $unknown) and $tag !~ /^(data|idx1|LIST_movi|RIFF)$/)) {
1689
+ my $tagInfo = $$tagTbl{$tag};
1690
+ if ($tagInfo or (($verbose or $unknown) and $tag !~ /^(data|idx1|LIST_movi|RIFF)$/)) {
1665
1691
  $raf->Read($buff, $len2) == $len2 or $err=1, last;
1666
- MakeTagInfo($tagTbl, $tag) if not $$tagTbl{$tag} and ($verbose or $unknown);
1692
+ my $setGroups;
1693
+ if ($tagInfo and ref $tagInfo eq 'HASH' and $$tagInfo{SetGroups}) {
1694
+ $setGroups = $$et{SET_GROUP0} = $$et{SET_GROUP1} = $$tagInfo{SetGroups};
1695
+ }
1696
+ MakeTagInfo($tagTbl, $tag) if not $tagInfo and ($verbose or $unknown);
1667
1697
  $et->HandleTag($tagTbl, $tag, $buff,
1668
1698
  DataPt => \$buff,
1669
1699
  DataPos => 0, # (relative to Base)
@@ -1671,6 +1701,10 @@ sub ProcessRIFF($$)
1671
1701
  Size => $len2,
1672
1702
  Base => $pos,
1673
1703
  );
1704
+ if ($setGroups) {
1705
+ delete $$et{SET_GROUP0};
1706
+ delete $$et{SET_GROUP1};
1707
+ }
1674
1708
  } elsif ($tag eq 'RIFF') {
1675
1709
  # don't read into RIFF chunk (eg. concatenated video file)
1676
1710
  $raf->Read($buff, 4) == 4 or $err=1, last;
@@ -22,7 +22,7 @@ use vars qw($VERSION %samsungLensTypes);
22
22
  use Image::ExifTool qw(:DataAccess :Utils);
23
23
  use Image::ExifTool::Exif;
24
24
 
25
- $VERSION = '1.44';
25
+ $VERSION = '1.45';
26
26
 
27
27
  sub WriteSTMN($$$);
28
28
  sub ProcessINFO($$$);
@@ -234,6 +234,7 @@ my %formatMinMax = (
234
234
  0x500103c => 'WB600 / VLUU WB600 / WB610',
235
235
  0x500133e => 'WB150 / WB150F / WB152 / WB152F / WB151',
236
236
  0x5a0000f => 'WB5000 / HZ25W',
237
+ 0x5a0001e => 'WB5500 / VLUU WB5500 / HZ50W',
237
238
  0x6001036 => 'EX1',
238
239
  0x700131c => 'VLUU SH100, SH100',
239
240
  0x27127002 => 'SMX-C20N',
@@ -8599,7 +8599,7 @@ my %isoSetting2010 = (
8599
8599
  );
8600
8600
 
8601
8601
 
8602
- # AFInfo (SLT models only) (ref PH, decoded mainly from A77)
8602
+ # AFInfo 0x940e (SLT models only) (ref PH, decoded mainly from A77)
8603
8603
  %Image::ExifTool::Sony::AFInfo = (
8604
8604
  PROCESS_PROC => \&ProcessEnciphered,
8605
8605
  WRITE_PROC => \&WriteEnciphered,
@@ -10171,7 +10171,7 @@ sub Decrypt($$$$)
10171
10171
  }
10172
10172
 
10173
10173
  #------------------------------------------------------------------------------
10174
- # Decipher/encipher Sony tag 0x94xx data (ref PH)
10174
+ # Decipher/encipher Sony tag 0x2010, 0x900b, 0x9050 and 0x940x data (ref PH)
10175
10175
  # Inputs: 0) data reference, 1) true to encipher the data
10176
10176
  sub Decipher($;$)
10177
10177
  {
@@ -1547,6 +1547,9 @@ my %tagLookup = (
1547
1547
  'componentversion' => { 92 => 0x80c },
1548
1548
  'composer' => { 354 => ["\xa9com","\xa9wrt"], 362 => ["\xa9com","\xa9wrt"], 480 => 'composer' },
1549
1549
  'composerkeywords' => { 362 => "\xa9cok" },
1550
+ 'compositeimage' => { 114 => 0xa460 },
1551
+ 'compositeimagecount' => { 114 => 0xa461 },
1552
+ 'compositeimageexposuretimes' => { 114 => 0xa462 },
1550
1553
  'composition' => { 445 => 'Composition' },
1551
1554
  'compositionadjust' => { 336 => '0.1' },
1552
1555
  'compositionadjustrotation' => { 336 => 0x7 },
@@ -4921,8 +4924,8 @@ my %tagLookup = (
4921
4924
  'samsungmodelid' => { 376 => 0x3 },
4922
4925
  'sanyoquality' => { 378 => 0x201 },
4923
4926
  'sanyothumbnail' => { 378 => 0x100 },
4924
- 'saturation' => { 10 => 0x6e, 12 => 0x76, 34 => 0xe, 49 => 0x1, 107 => 0xd, 108 => [0x3013,0x1f], 114 => [0xa409,0xfe55], 122 => 0x1003, 148 => 'Saturation', 172 => 0x1f, 173 => 0x32, 174 => 0x28, 175 => 0x1a, 180 => 0x1, 215 => [0x94,0xaa], 217 => 0x35, 218 => 0x3b, 219 => 0x43, 302 => 0x40, 304 => 0x300d, 337 => 0x1f, 344 => 0xd, 363 => 0x27, 365 => 0x58, 368 => 0x28, 369 => 0x1013, 379 => 0x10, 387 => 0x1e, 388 => 0x1b, 400 => 0x2005, 456 => 'Saturation', 460 => 'Saturation' },
4925
- 'saturationadj' => { 98 => 0x20901, 103 => 0x116, 254 => 0x1, 258 => 0x2e, 433 => 0x8016 },
4927
+ 'saturation' => { 10 => 0x6e, 12 => 0x76, 34 => 0xe, 49 => 0x1, 107 => 0xd, 108 => [0x3013,0x1f], 114 => [0xa409,0xfe55], 122 => 0x1003, 148 => 'Saturation', 172 => 0x1f, 173 => 0x32, 174 => 0x28, 175 => 0x1a, 180 => 0x1, 215 => 0xaa, 217 => 0x35, 218 => 0x3b, 219 => 0x43, 302 => 0x40, 304 => 0x300d, 337 => 0x1f, 344 => 0xd, 363 => 0x27, 365 => 0x58, 368 => 0x28, 369 => 0x1013, 379 => 0x10, 387 => 0x1e, 388 => 0x1b, 400 => 0x2005, 456 => 'Saturation', 460 => 'Saturation' },
4928
+ 'saturationadj' => { 98 => 0x20901, 103 => 0x116, 215 => 0x94, 254 => 0x1, 258 => 0x2e, 433 => 0x8016 },
4926
4929
  'saturationadjustmentaqua' => { 456 => 'SaturationAdjustmentAqua' },
4927
4930
  'saturationadjustmentblue' => { 456 => 'SaturationAdjustmentBlue' },
4928
4931
  'saturationadjustmentgreen' => { 456 => 'SaturationAdjustmentGreen' },
@@ -7352,6 +7355,7 @@ my %tagExists = (
7352
7355
  'effectsvisible' => 1,
7353
7356
  'eighteenpercentpoint' => 1,
7354
7357
  'eighthlanguage' => 1,
7358
+ 'electronicimagestabilization' => 1,
7355
7359
  'electronicvr' => 1,
7356
7360
  'elementarystreamtrack' => 1,
7357
7361
  'embeddedaudiofile' => 1,
@@ -7368,6 +7372,7 @@ my %tagExists = (
7368
7372
  'embeddedimagewidth' => 1,
7369
7373
  'embeddedjpg' => 1,
7370
7374
  'embeddedpng' => 1,
7375
+ 'embeddedvideo' => 1,
7371
7376
  'embeddedvideofile' => 1,
7372
7377
  'embeddedvideotype' => 1,
7373
7378
  'emphasis' => 1,
@@ -12,7 +12,7 @@ meta information extracted from or written to a file.
12
12
  =head1 TAG TABLES
13
13
 
14
14
  The tables listed below give the names of all tags recognized by ExifTool.
15
- They contain a total of 22571 tags, with 15015 unique tag names.
15
+ They contain a total of 22577 tags, with 15020 unique tag names.
16
16
 
17
17
  B<Tag ID>, B<Index#> or B<Sequence> is given in the first column of each
18
18
  table. A B<Tag ID> is the computer-readable equivalent of a tag name, and
@@ -144,6 +144,7 @@ L<https://www.w3.org/Graphics/JPEG/jfif3.pdf> for the JPEG specification.
144
144
  MIE MIE
145
145
  Samsung Samsung Trailer
146
146
  PreviewImage yes
147
+ EmbeddedVideo no
147
148
 
148
149
  =head3 JPEG AVI1 Tags
149
150
 
@@ -308,11 +309,11 @@ tags remain.
308
309
 
309
310
  The table below lists all EXIF tags. Also listed are TIFF, DNG, HDP and
310
311
  other tags which are not part of the EXIF specification, but may co-exist
311
- with EXIF tags in some images. Tags which are part of the EXIF 2.31
312
+ with EXIF tags in some images. Tags which are part of the EXIF 2.32
312
313
  specification have an underlined B<Tag Name> in the HTML version of this
313
314
  documentation. See
314
- L<http://www.cipa.jp/std/documents/e/DC-008-Translation-2016-E.pdf> for the
315
- official EXIF 2.31 specification.
315
+ L<http://www.cipa.jp/std/documents/e/DC-008-Translation-2019-E.pdf> for the
316
+ official EXIF 2.32 specification.
316
317
 
317
318
  Tag ID Tag Name Group Writable
318
319
  ------ -------- ----- --------
@@ -752,6 +753,9 @@ official EXIF 2.31 specification.
752
753
  0xa433 LensMake ExifIFD string
753
754
  0xa434 LensModel ExifIFD string
754
755
  0xa435 LensSerialNumber ExifIFD string
756
+ 0xa460 CompositeImage ExifIFD int16u
757
+ 0xa461 CompositeImageCount ExifIFD int16u[2]
758
+ 0xa462 CompositeImageExposureTimes ExifIFD undef
755
759
  0xa480 GDALMetadata IFD0 string
756
760
  0xa481 GDALNoData IFD0 string
757
761
  0xa500 Gamma ExifIFD rational64u
@@ -10895,7 +10899,7 @@ DiMAGE X and Xt.
10895
10899
  ShotInfoUnknown Nikon ShotInfo
10896
10900
  0x0092 HueAdjustment int16s
10897
10901
  0x0093 NEFCompression int16u
10898
- 0x0094 Saturation int16s
10902
+ 0x0094 SaturationAdj int16s
10899
10903
  0x0095 NoiseReduction string
10900
10904
  0x0096 NEFLinearizationTable undef!
10901
10905
  0x0097 ColorBalance0100 Nikon ColorBalance1
@@ -18834,6 +18838,7 @@ about this format.
18834
18838
  'DVID' DeviceID? no
18835
18839
  'DVNM' DeviceName no
18836
18840
  'DZOM' DigitalZoom no
18841
+ 'EISA' ElectronicImageStabilization no
18837
18842
  'EMPT' Empty? no
18838
18843
  'ESCS' EscapeStatus? no
18839
18844
  'FACE' FaceDetected no
@@ -27795,6 +27800,7 @@ sub-documents, but the Duration is calculated for the full video.
27795
27800
  PentaxJunk2 Pentax Junk2
27796
27801
  TextJunk no
27797
27802
  'JUNQ' OldXMP no
27803
+ 'LIST_INF0' Info RIFF Info
27798
27804
  'LIST_INFO' Info RIFF Info
27799
27805
  'LIST_Tdat' Tdat RIFF Tdat
27800
27806
  'LIST_exif' Exif RIFF Exif
@@ -27815,6 +27821,8 @@ sub-documents, but the Duration is calculated for the full video.
27815
27821
  'ds64' DataSize64 RIFF DS64
27816
27822
  'fact' NumberOfSamples no
27817
27823
  'fmt ' AudioFormat RIFF AudioFormat
27824
+ 'gps0' GPSTrack QuickTime Stream
27825
+ 'gsen' GSensor QuickTime Stream
27818
27826
  'labl' Label RIFF Label
27819
27827
  'list' ListType no
27820
27828
  'olym' Olym Olympus WAV
@@ -32953,6 +32961,7 @@ FileName.
32953
32961
  CurrentIPTCDigest File no
32954
32962
  Directory System yes!
32955
32963
  EXIF EXIF yes!
32964
+ EmbeddedVideo File no
32956
32965
  Error ExifTool no
32957
32966
  ExifByteOrder File yes
32958
32967
  ExifToolVersion ExifTool no
@@ -14,7 +14,7 @@ use strict;
14
14
  use vars qw($VERSION);
15
15
  use Image::ExifTool qw(:DataAccess :Utils);
16
16
 
17
- $VERSION = '1.03';
17
+ $VERSION = '1.04';
18
18
 
19
19
  sub ReadBencode($$);
20
20
  sub ExtractTags($$$;$$@);
@@ -232,6 +232,11 @@ sub ExtractTags($$$;$$@)
232
232
  $tagInfo = $et->GetTagInfo($tagTablePtr, $id) or next;
233
233
  }
234
234
  if (ref $val eq 'HASH') {
235
+ if ($et->Options('Struct') and $tagInfo and $$tagInfo{Name} eq 'Info') {
236
+ $et->FoundTag($tagInfo, $val);
237
+ ++$count;
238
+ next;
239
+ }
235
240
  # extract tags from this dictionary
236
241
  my ($table, $rootID, $rootName);
237
242
  if ($$tagInfo{SubDirectory}) {
@@ -268,7 +273,7 @@ sub ProcessTorrent($$)
268
273
  my $dict = ReadBencode($raf, \$buff);
269
274
  my $err = $$raf{BencodeError};
270
275
  $et->Warn("Bencode error: $err") if $err;
271
- if (ref $dict eq 'HASH' and $$dict{announce}) {
276
+ if (ref $dict eq 'HASH' and ($$dict{announce} or $$dict{'created by'})) {
272
277
  $et->SetFileType();
273
278
  my $tagTablePtr = GetTagTable('Image::ExifTool::Torrent::Main');
274
279
  ExtractTags($et, $dict, $tagTablePtr) and $success = 1;
@@ -22,7 +22,7 @@ $VERSION = '1.14';
22
22
  use Image::ExifTool qw(:Utils);
23
23
  use Image::ExifTool::Exif;
24
24
 
25
- # EXIF table tag ID's which are part of the EXIF 2.31 specification
25
+ # EXIF table tag ID's which are part of the EXIF 2.32 specification
26
26
  # (also used by BuildTagLookup to add underlines in HTML version of EXIF Tag Table)
27
27
  %exifSpec = (
28
28
  0x1 => 1,
@@ -42,16 +42,16 @@ use Image::ExifTool::Exif;
42
42
  0x11a => 1, 0x8834 => 1, 0x9403 => 1, 0xa40a => 1,
43
43
  0x11b => 1, 0x8835 => 1, 0x9404 => 1, 0xa40b => 1,
44
44
  0x11c => 1, 0x9000 => 1, 0x9405 => 1, 0xa40c => 1,
45
- 0x128 => 1, 0x9003 => 1, 0xa000 => 1, 0xa420 => 1,
46
- 0x12d => 1, 0x9004 => 1, 0xa001 => 1, 0xa430 => 1,
47
- 0x131 => 1, 0x9010 => 1, 0xa002 => 1, 0xa431 => 1,
48
- 0x132 => 1, 0x9011 => 1, 0xa003 => 1, 0xa432 => 1,
49
- 0x13b => 1, 0x9012 => 1, 0xa004 => 1, 0xa433 => 1,
50
- 0x13e => 1, 0x9101 => 1, 0xa005 => 1, 0xa434 => 1,
51
- 0x13f => 1, 0x9102 => 1, 0xa20b => 1, 0xa435 => 1,
52
- 0x201 => 1, 0x9201 => 1, 0xa20c => 1,
53
- 0x202 => 1, 0x9202 => 1, 0xa20e => 1,
54
- 0x211 => 1, 0x9203 => 1, 0xa20f => 1,
45
+ 0x128 => 1, 0x9003 => 1, 0xa000 => 1, 0xa460 => 1,
46
+ 0x12d => 1, 0x9004 => 1, 0xa001 => 1, 0xa461 => 1,
47
+ 0x131 => 1, 0x9010 => 1, 0xa002 => 1, 0xa462 => 1,
48
+ 0x132 => 1, 0x9011 => 1, 0xa003 => 1, 0xa420 => 1,
49
+ 0x13b => 1, 0x9012 => 1, 0xa004 => 1, 0xa430 => 1,
50
+ 0x13e => 1, 0x9101 => 1, 0xa005 => 1, 0xa431 => 1,
51
+ 0x13f => 1, 0x9102 => 1, 0xa20b => 1, 0xa432 => 1,
52
+ 0x201 => 1, 0x9201 => 1, 0xa20c => 1, 0xa433 => 1,
53
+ 0x202 => 1, 0x9202 => 1, 0xa20e => 1, 0xa434 => 1,
54
+ 0x211 => 1, 0x9203 => 1, 0xa20f => 1, 0xa435 => 1,
55
55
  0x212 => 1, 0x9204 => 1, 0xa210 => 1,
56
56
  0x213 => 1, 0x9205 => 1, 0xa214 => 1,
57
57
  0x214 => 1, 0x9206 => 1, 0xa215 => 1,
@@ -38,7 +38,7 @@ my %mandatory = (
38
38
  0x0128 => 2, # ResolutionUnit (inches)
39
39
  },
40
40
  ExifIFD => {
41
- 0x9000 => '0231', # ExifVersion
41
+ 0x9000 => '0232', # ExifVersion
42
42
  0x9101 => "1 2 3 0",# ComponentsConfiguration
43
43
  0xa000 => '0100', # FlashpixVersion
44
44
  0xa001 => 0xffff, # ColorSpace (uncalibrated)
@@ -793,11 +793,18 @@ sub WriteQuickTime($$$)
793
793
  }
794
794
  $size = $hi * 4294967296 + $lo - 16;
795
795
  $size < 0 and $et->Error('Invalid extended atom size'), last;
796
- } elsif ($size == -8 and not $dataPt) {
797
- # size of zero is only valid for top-level atom, and
798
- # indicates the atom extends to the end of file
799
- # (save in mdat list to write later; with zero end position to copy rest of file)
800
- push @mdat, [ $raf->Tell(), 0, $hdr ];
796
+ } elsif ($size == -8) {
797
+ if ($dataPt) {
798
+ my $pos = $raf->Tell() - 4;
799
+ $raf->Seek(0,2);
800
+ my $str = $$dirInfo{DirName} . ' with ' . ($raf->Tell() - $pos) . ' bytes';
801
+ $et->Error("Terminator found in $str remaining", 1);
802
+ } else {
803
+ # size of zero is only valid for top-level atom, and
804
+ # indicates the atom extends to the end of file
805
+ # (save in mdat list to write later; with zero end position to copy rest of file)
806
+ push @mdat, [ $raf->Tell(), 0, $hdr ];
807
+ }
801
808
  last;
802
809
  } elsif ($size < 0) {
803
810
  if ($$tagTablePtr{VARS}{IGNORE_BAD_ATOMS} and $dataPt) {
@@ -1029,7 +1036,7 @@ sub WriteQuickTime($$$)
1029
1036
  my $prVal = $newVal;
1030
1037
  my $flags = FormatQTValue($et, \$newVal, $$tagInfo{Format});
1031
1038
  next unless defined $newVal;
1032
- my ($ctry, $lang) = (0,0);
1039
+ my ($ctry, $lang) = (0, $undLang);
1033
1040
  if ($$ti{LangCode}) {
1034
1041
  unless ($$ti{LangCode} =~ /^([A-Z]{3})?[-_]?([A-Z]{2})?$/i) {
1035
1042
  $et->Warn("Invalid language code for $$ti{Name}");
@@ -1179,6 +1186,11 @@ sub WriteQuickTime($$$)
1179
1186
  } else {
1180
1187
  $newData = pack('nn', length($newData), $lang) . $newData;
1181
1188
  }
1189
+ } elsif (not $$tagInfo{Format} or $$tagInfo{Format} =~ /^string/ and
1190
+ not $$tagInfo{Binary} and not $$tagInfo{ValueConv})
1191
+ {
1192
+ # write all strings as UTF-8
1193
+ $newData = $et->Encode($newData, 'UTF8');
1182
1194
  }
1183
1195
  }
1184
1196
  $$didTag{$nvHash} = 1; # set flag so we don't add this tag again
@@ -1315,8 +1327,10 @@ sub WriteQuickTime($$$)
1315
1327
  }
1316
1328
  if ($$dirInfo{HasData}) {
1317
1329
  # add 'data' header
1330
+ $lang or $lang = $undLang;
1318
1331
  $newVal = pack('Na4Nnn',16+length($newVal),'data',$flags,$ctry,$lang).$newVal;
1319
1332
  } elsif ($tag =~ /^\xa9/ or $$tagInfo{IText}) {
1333
+ $lang or $lang = $undLang;
1320
1334
  if ($ctry) {
1321
1335
  my $grp = $et->GetGroup($tagInfo,1);
1322
1336
  $et->Warn("Can't use country code for $grp:$$tagInfo{Name}");
@@ -607,7 +607,7 @@ sub LimitXMPSize($$$$$$)
607
607
  my ($sp, $nl) = $noPad ? ('', $noPad > 1 ? '' : "\n") : (' ',"\n");
608
608
  # write the required xmpNote:HasExtendedXMP property
609
609
  $newData .= "$nl$sp<$rdfDesc rdf:about='${about}'\n$sp${sp}xmlns:xmpNote='$nsURI{xmpNote}'";
610
- if ($$et{OPTIONS}{XMPShorthand} or ($$et{OPTIONS}{Compact} and $$et{OPTIONS}{Compact} > 4)) {
610
+ if ($$et{OPTIONS}{XMPShorthand} or $$et{OPTIONS}{Compact} > 4) {
611
611
  $newData .= "\n$sp${sp}xmpNote:HasExtendedXMP='${guid}'/>\n";
612
612
  } else {
613
613
  $newData .= ">$nl$sp$sp<xmpNote:HasExtendedXMP>$guid</xmpNote:HasExtendedXMP>$nl$sp</$rdfDesc>\n";
@@ -723,7 +723,7 @@ sub WriteXMP($$;$)
723
723
  # prefer XMP over other metadata formats in some types of files
724
724
  my $preferred = $xmpFile || ($$et{PreferredGroup} and $$et{PreferredGroup} eq 'XMP');
725
725
  my $verbose = $$et{OPTIONS}{Verbose};
726
- my $compact = $$et{OPTIONS}{Compact} || 0;
726
+ my $compact = $$et{OPTIONS}{Compact};
727
727
  my $dirLen = $$dirInfo{DirLen};
728
728
  $dirLen = length($$dataPt) if not defined $dirLen and $dataPt;
729
729
  $noPad = $compact > 1 ? ($compact > 3 ? 2 : 1) : undef;
@@ -1236,7 +1236,7 @@ sub WriteXMP($$;$)
1236
1236
  # write out the new XMP information (serialize it)
1237
1237
  #
1238
1238
  # start writing the XMP data
1239
- my $useShorthand = $$et{OPTIONS}{XMPShorthand} || $compact > 4;
1239
+ my $useShorthand = $$et{OPTIONS}{XMPShorthand} || ($compact > 4 ? 1 : 0);
1240
1240
  my (@long, @short, @resFlag);
1241
1241
  $long[0] = $long[1] = $short[0] = '';
1242
1242
  if ($$et{XMP_NO_XPACKET}) {
@@ -1316,7 +1316,7 @@ sub WriteXMP($$;$)
1316
1316
  my ($path2, $ns2);
1317
1317
  foreach $path2 (@pathList) {
1318
1318
  my @ns2s = ($path2 =~ m{(?:^|/)([^/]+?):}g);
1319
- my $opening = $compact > 2 ? 1 : 0;
1319
+ my $opening = ($compact > 2 or $useShorthand > 1) ? 1 : 0;
1320
1320
  foreach $ns2 (@ns2s) {
1321
1321
  next if $ns2 eq 'rdf';
1322
1322
  $nsNew{$ns2} and ++$opening, next;
@@ -19,7 +19,7 @@ use strict;
19
19
  use vars qw($VERSION $warnString);
20
20
  use Image::ExifTool qw(:DataAccess :Utils);
21
21
 
22
- $VERSION = '1.24';
22
+ $VERSION = '1.25';
23
23
 
24
24
  sub WarnProc($) { $warnString = $_[0]; }
25
25
 
@@ -308,6 +308,9 @@ sub ProcessRAR($$)
308
308
  $raf->Seek($size, 1) or last if $size;
309
309
  }
310
310
  $$et{DOC_NUM} = 0;
311
+ if ($docNum > 1 and not $et->Options('Duplicates')) {
312
+ $et->Warn("Use the Duplicates option to extract tags for all $docNum files", 1);
313
+ }
311
314
 
312
315
  return 1;
313
316
  }
@@ -387,11 +390,12 @@ sub ProcessZIP($$)
387
390
  {
388
391
  my ($et, $dirInfo) = @_;
389
392
  my $raf = $$dirInfo{RAF};
390
- my ($buff, $buf2, $zip, $docNum);
393
+ my ($buff, $buf2, $zip);
391
394
 
392
395
  return 0 unless $raf->Read($buff, 30) == 30 and $buff =~ /^PK\x03\x04/;
393
396
 
394
397
  my $tagTablePtr = GetTagTable('Image::ExifTool::ZIP::Main');
398
+ my $docNum = 0;
395
399
 
396
400
  # use Archive::Zip if avilable
397
401
  for (;;) {
@@ -566,7 +570,6 @@ sub ProcessZIP($$)
566
570
  # otherwise just extract general ZIP information
567
571
  $et->SetFileType();
568
572
  @members = $zip->members();
569
- $docNum = 0;
570
573
  my ($member, $iWorkType);
571
574
  # special files to extract
572
575
  my %extract = (
@@ -608,12 +611,14 @@ sub ProcessZIP($$)
608
611
  if ($zip) {
609
612
  delete $$dirInfo{ZIP};
610
613
  delete $$et{DOC_NUM};
614
+ if ($docNum > 1 and not $et->Options('Duplicates')) {
615
+ $et->Warn("Use the Duplicates option to extract tags for all $docNum files", 1);
616
+ }
611
617
  return 1;
612
618
  }
613
619
  #
614
620
  # process the ZIP file by hand (funny, but this seems easier than using Archive::Zip)
615
621
  #
616
- $docNum = 0;
617
622
  $et->VPrint(1, " -- processing as binary data --\n");
618
623
  $raf->Seek(30, 0);
619
624
  $et->SetFileType();
@@ -659,6 +664,9 @@ sub ProcessZIP($$)
659
664
  $raf->Read($buff, 30) == 30 and $buff =~ /^PK\x03\x04/ or last;
660
665
  }
661
666
  delete $$et{DOC_NUM};
667
+ if ($docNum > 1 and not $et->Options('Duplicates')) {
668
+ $et->Warn("Use the Duplicates option to extract tags for all $docNum files", 1);
669
+ }
662
670
  return 1;
663
671
  }
664
672
 
@@ -1,6 +1,6 @@
1
1
  Summary: perl module for image data extraction
2
2
  Name: perl-Image-ExifTool
3
- Version: 11.52
3
+ Version: 11.53
4
4
  Release: 1
5
5
  License: Artistic/GPL
6
6
  Group: Development/Libraries/Perl
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module ExiftoolVendored
4
- VERSION = Gem::Version.new('11.52.0')
4
+ VERSION = Gem::Version.new('11.53.0')
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: exiftool_vendored
3
3
  version: !ruby/object:Gem::Version
4
- version: 11.52.0
4
+ version: 11.53.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Matthew McEachen
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2019-06-17 00:00:00.000000000 Z
12
+ date: 2019-06-24 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: exiftool