exiftool-vendored.pl 12.45.0 → 12.50.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (57) hide show
  1. package/bin/Changes +122 -6
  2. package/bin/MANIFEST +12 -0
  3. package/bin/META.json +1 -1
  4. package/bin/META.yml +1 -1
  5. package/bin/README +45 -44
  6. package/bin/config_files/acdsee.config +2 -1
  7. package/bin/config_files/frameCount.config +56 -0
  8. package/bin/config_files/tiff_version.config +1 -1
  9. package/bin/exiftool +89 -75
  10. package/bin/lib/Image/ExifTool/Apple.pm +6 -2
  11. package/bin/lib/Image/ExifTool/BuildTagLookup.pm +17 -9
  12. package/bin/lib/Image/ExifTool/Canon.pm +31 -14
  13. package/bin/lib/Image/ExifTool/CanonRaw.pm +8 -1
  14. package/bin/lib/Image/ExifTool/Exif.pm +13 -8
  15. package/bin/lib/Image/ExifTool/FLAC.pm +17 -3
  16. package/bin/lib/Image/ExifTool/FlashPix.pm +4 -2
  17. package/bin/lib/Image/ExifTool/FujiFilm.pm +31 -5
  18. package/bin/lib/Image/ExifTool/Geotag.pm +1 -1
  19. package/bin/lib/Image/ExifTool/ICC_Profile.pm +1 -1
  20. package/bin/lib/Image/ExifTool/ICO.pm +143 -0
  21. package/bin/lib/Image/ExifTool/ID3.pm +5 -5
  22. package/bin/lib/Image/ExifTool/IPTC.pm +5 -1
  23. package/bin/lib/Image/ExifTool/M2TS.pm +98 -8
  24. package/bin/lib/Image/ExifTool/MIE.pm +9 -3
  25. package/bin/lib/Image/ExifTool/MISB.pm +494 -0
  26. package/bin/lib/Image/ExifTool/MakerNotes.pm +3 -1
  27. package/bin/lib/Image/ExifTool/Nikon.pm +220 -109
  28. package/bin/lib/Image/ExifTool/NikonSettings.pm +5 -3
  29. package/bin/lib/Image/ExifTool/Olympus.pm +2 -1
  30. package/bin/lib/Image/ExifTool/Panasonic.pm +21 -4
  31. package/bin/lib/Image/ExifTool/PanasonicRaw.pm +12 -5
  32. package/bin/lib/Image/ExifTool/Pentax.pm +7 -2
  33. package/bin/lib/Image/ExifTool/Photoshop.pm +29 -3
  34. package/bin/lib/Image/ExifTool/QuickTime.pm +78 -10
  35. package/bin/lib/Image/ExifTool/QuickTimeStream.pl +76 -5
  36. package/bin/lib/Image/ExifTool/README +5 -1
  37. package/bin/lib/Image/ExifTool/RIFF.pm +106 -9
  38. package/bin/lib/Image/ExifTool/Samsung.pm +2 -2
  39. package/bin/lib/Image/ExifTool/Sigma.pm +27 -1
  40. package/bin/lib/Image/ExifTool/SigmaRaw.pm +37 -13
  41. package/bin/lib/Image/ExifTool/Sony.pm +35 -16
  42. package/bin/lib/Image/ExifTool/TagInfoXML.pm +3 -1
  43. package/bin/lib/Image/ExifTool/TagLookup.pm +4700 -4520
  44. package/bin/lib/Image/ExifTool/TagNames.pod +4796 -4463
  45. package/bin/lib/Image/ExifTool/Text.pm +3 -4
  46. package/bin/lib/Image/ExifTool/Torrent.pm +2 -3
  47. package/bin/lib/Image/ExifTool/WriteCanonRaw.pl +7 -0
  48. package/bin/lib/Image/ExifTool/WriteExif.pl +19 -1
  49. package/bin/lib/Image/ExifTool/WriteRIFF.pl +359 -0
  50. package/bin/lib/Image/ExifTool/Writer.pl +6 -2
  51. package/bin/lib/Image/ExifTool/XMP.pm +72 -57
  52. package/bin/lib/Image/ExifTool/XMP2.pl +9 -1
  53. package/bin/lib/Image/ExifTool.pm +81 -18
  54. package/bin/lib/Image/ExifTool.pod +64 -60
  55. package/bin/perl-Image-ExifTool.spec +43 -43
  56. package/bin/pp_build_exe.args +7 -4
  57. package/package.json +2 -2
package/bin/exiftool CHANGED
@@ -11,7 +11,7 @@ use strict;
11
11
  use warnings;
12
12
  require 5.004;
13
13
 
14
- my $version = '12.45';
14
+ my $version = '12.50';
15
15
 
16
16
  # add our 'lib' directory to the include list BEFORE 'use Image::ExifTool'
17
17
  BEGIN {
@@ -1009,8 +1009,12 @@ for (;;) {
1009
1009
  }
1010
1010
  if (/^if(\d*)$/i) {
1011
1011
  my $cond = shift;
1012
- $fastCondition = $1 if length $1;
1012
+ my $fast = length($1) ? $1 : undef;
1013
1013
  defined $cond or Error("Expecting expression for -if option\n"), $badCmd=1, next;
1014
+ # use lowest -fast setting if multiple conditions
1015
+ if (not @condition or not defined $fast or (defined $fastCondition and $fastCondition > $fast)) {
1016
+ $fastCondition = $fast;
1017
+ }
1014
1018
  # prevent processing file unnecessarily for simple case of failed '$ok' or 'not $ok'
1015
1019
  $cond =~ /^\s*(not\s*)\$ok\s*$/i and ($1 xor $rtnValPrev) and $failCondition=1;
1016
1020
  # add to list of requested tags
@@ -3254,7 +3258,7 @@ sub EncodeXML($)
3254
3258
  {
3255
3259
  my $strPt = shift;
3256
3260
  if ($$strPt =~ /[\0-\x08\x0b\x0c\x0e-\x1f]/ or
3257
- (not $altEnc and Image::ExifTool::XMP::IsUTF8($strPt) < 0))
3261
+ (not $altEnc and Image::ExifTool::IsUTF8($strPt) < 0))
3258
3262
  {
3259
3263
  # encode binary data and non-UTF8 with special characters as base64
3260
3264
  $$strPt = Image::ExifTool::XMP::EncodeBase64($$strPt);
@@ -3318,7 +3322,7 @@ sub EscapeJSON($;$)
3318
3322
  return $str if $str =~ /^-?(\d|[1-9]\d{1,14})(\.\d{1,16})?(e[-+]?\d{1,3})?$/i;
3319
3323
  }
3320
3324
  # encode JSON string in base64 if necessary
3321
- if ($json < 2 and defined $binaryOutput and Image::ExifTool::XMP::IsUTF8(\$str) < 0) {
3325
+ if ($json < 2 and defined $binaryOutput and Image::ExifTool::IsUTF8(\$str) < 0) {
3322
3326
  return '"base64:' . Image::ExifTool::XMP::EncodeBase64($str, 1) . '"';
3323
3327
  }
3324
3328
  # escape special characters
@@ -3394,7 +3398,7 @@ sub FormatCSV($)
3394
3398
  my $val = shift;
3395
3399
  # check for valid encoding if the Charset option was used
3396
3400
  if ($setCharset and ($val =~ /[^\x09\x0a\x0d\x20-\x7e\x80-\xff]/ or
3397
- ($setCharset eq 'UTF8' and Image::ExifTool::XMP::IsUTF8(\$val) < 0)))
3401
+ ($setCharset eq 'UTF8' and Image::ExifTool::IsUTF8(\$val) < 0)))
3398
3402
  {
3399
3403
  $val = 'base64:' . Image::ExifTool::XMP::EncodeBase64($val, 1);
3400
3404
  }
@@ -3481,7 +3485,7 @@ sub ConvertBinary($)
3481
3485
  $obj = $$obj;
3482
3486
  # encode in base64 if necessary (0xf7 allows for up to 21-bit UTF-8 code space)
3483
3487
  if ($json == 1 and ($obj =~ /[^\x09\x0a\x0d\x20-\x7e\x80-\xf7]/ or
3484
- Image::ExifTool::XMP::IsUTF8(\$obj) < 0))
3488
+ Image::ExifTool::IsUTF8(\$obj) < 0))
3485
3489
  {
3486
3490
  $obj = 'base64:' . Image::ExifTool::XMP::EncodeBase64($obj, 1);
3487
3491
  }
@@ -3615,8 +3619,7 @@ sub CheckUTF8($$)
3615
3619
  my ($file, $enc) = @_;
3616
3620
  my $isUTF8 = 0;
3617
3621
  if ($file =~ /[\x80-\xff]/) {
3618
- require Image::ExifTool::XMP;
3619
- $isUTF8 = Image::ExifTool::XMP::IsUTF8(\$file);
3622
+ $isUTF8 = Image::ExifTool::IsUTF8(\$file);
3620
3623
  if ($isUTF8 < 0) {
3621
3624
  if ($enc) {
3622
3625
  Warn("Invalid filename encoding for $file\n");
@@ -4529,48 +4532,48 @@ supported by ExifTool (r = read, w = write, c = create):
4529
4532
 
4530
4533
  File Types
4531
4534
  ------------+-------------+-------------+-------------+------------
4532
- 360 r/w | DR4 r/w/c | JNG r/w | O r | RAW r/w
4533
- 3FR r | DSS r | JP2 r/w | ODP r | RIFF r
4534
- 3G2 r/w | DV r | JPEG r/w | ODS r | RSRC r
4535
- 3GP r/w | DVB r/w | JSON r | ODT r | RTF r
4536
- A r | DVR-MS r | JXL r | OFR r | RW2 r/w
4537
- AA r | DYLIB r | K25 r | OGG r | RWL r/w
4538
- AAE r | EIP r | KDC r | OGV r | RWZ r
4539
- AAX r/w | EPS r/w | KEY r | ONP r | RM r
4540
- ACR r | EPUB r | LA r | OPUS r | SEQ r
4541
- AFM r | ERF r/w | LFP r | ORF r/w | SKETCH r
4542
- AI r/w | EXE r | LIF r | ORI r/w | SO r
4543
- AIFF r | EXIF r/w/c | LNK r | OTF r | SR2 r/w
4544
- APE r | EXR r | LRV r/w | PAC r | SRF r
4545
- ARQ r/w | EXV r/w/c | M2TS r | PAGES r | SRW r/w
4546
- ARW r/w | F4A/V r/w | M4A/V r/w | PBM r/w | SVG r
4547
- ASF r | FFF r/w | MACOS r | PCD r | SWF r
4548
- AVI r | FITS r | MAX r | PCX r | THM r/w
4549
- AVIF r/w | FLA r | MEF r/w | PDB r | TIFF r/w
4550
- AZW r | FLAC r | MIE r/w/ | PDF r/w | TORRENT r
4551
- BMP r | FLIF r/w | MIFF r c | PEF r/w | TTC r
4552
- BPG r | FLV r | MKA r | PFA r | TTF r
4553
- BTF r | FPF r | MKS r | PFB r | TXT r
4554
- CHM r | FPX r | MKV r | PFM r | VCF r
4555
- COS r | GIF r/w | MNG r/w | PGF r | VRD r/w/c
4556
- CR2 r/w | GPR r/w | MOBI r | PGM r/w | VSD r
4557
- CR3 r/w | GZ r | MODD r | PLIST r | WAV r
4558
- CRM r/w | HDP r/w | MOI r | PICT r | WDP r/w
4559
- CRW r/w | HDR r | MOS r/w | PMP r | WEBP r
4560
- CS1 r/w | HEIC r/w | MOV r/w | PNG r/w | WEBM r
4561
- CSV r | HEIF r/w | MP3 r | PPM r/w | WMA r
4562
- CZI r | HTML r | MP4 r/w | PPT r | WMV r
4563
- DCM r | ICC r/w/c | MPC r | PPTX r | WTV r
4564
- DCP r/w | ICS r | MPG r | PS r/w | WV r
4565
- DCR r | IDML r | MPO r/w | PSB r/w | X3F r/w
4566
- DFONT r | IIQ r/w | MQV r/w | PSD r/w | XCF r
4567
- DIVX r | IND r/w | MRC r | PSP r | XLS r
4568
- DJVU r | INSP r/w | MRW r/w | QTIF r/w | XLSX r
4569
- DLL r | INSV r | MXF r | R3D r | XMP r/w/c
4570
- DNG r/w | INX r | NEF r/w | RA r | ZIP r
4571
- DOC r | ISO r | NKSC r/w | RAF r/w |
4572
- DOCX r | ITC r | NRW r/w | RAM r |
4573
- DPX r | J2C r | NUMBERS r | RAR r |
4535
+ 360 r/w | DPX r | ITC r | NRW r/w | RAM r
4536
+ 3FR r | DR4 r/w/c | J2C r | NUMBERS r | RAR r
4537
+ 3G2 r/w | DSS r | JNG r/w | O r | RAW r/w
4538
+ 3GP r/w | DV r | JP2 r/w | ODP r | RIFF r
4539
+ A r | DVB r/w | JPEG r/w | ODS r | RSRC r
4540
+ AA r | DVR-MS r | JSON r | ODT r | RTF r
4541
+ AAE r | DYLIB r | JXL r | OFR r | RW2 r/w
4542
+ AAX r/w | EIP r | K25 r | OGG r | RWL r/w
4543
+ ACR r | EPS r/w | KDC r | OGV r | RWZ r
4544
+ AFM r | EPUB r | KEY r | ONP r | RM r
4545
+ AI r/w | ERF r/w | LA r | OPUS r | SEQ r
4546
+ AIFF r | EXE r | LFP r | ORF r/w | SKETCH r
4547
+ APE r | EXIF r/w/c | LIF r | ORI r/w | SO r
4548
+ ARQ r/w | EXR r | LNK r | OTF r | SR2 r/w
4549
+ ARW r/w | EXV r/w/c | LRV r/w | PAC r | SRF r
4550
+ ASF r | F4A/V r/w | M2TS r | PAGES r | SRW r/w
4551
+ AVI r | FFF r/w | M4A/V r/w | PBM r/w | SVG r
4552
+ AVIF r/w | FITS r | MACOS r | PCD r | SWF r
4553
+ AZW r | FLA r | MAX r | PCX r | THM r/w
4554
+ BMP r | FLAC r | MEF r/w | PDB r | TIFF r/w
4555
+ BPG r | FLIF r/w | MIE r/w/c | PDF r/w | TORRENT r
4556
+ BTF r | FLV r | MIFF r | PEF r/w | TTC r
4557
+ CHM r | FPF r | MKA r | PFA r | TTF r
4558
+ COS r | FPX r | MKS r | PFB r | TXT r
4559
+ CR2 r/w | GIF r/w | MKV r | PFM r | VCF r
4560
+ CR3 r/w | GPR r/w | MNG r/w | PGF r | VRD r/w/c
4561
+ CRM r/w | GZ r | MOBI r | PGM r/w | VSD r
4562
+ CRW r/w | HDP r/w | MODD r | PLIST r | WAV r
4563
+ CS1 r/w | HDR r | MOI r | PICT r | WDP r/w
4564
+ CSV r | HEIC r/w | MOS r/w | PMP r | WEBP r/w
4565
+ CUR r | HEIF r/w | MOV r/w | PNG r/w | WEBM r
4566
+ CZI r | HTML r | MP3 r | PPM r/w | WMA r
4567
+ DCM r | ICC r/w/c | MP4 r/w | PPT r | WMV r
4568
+ DCP r/w | ICO r | MPC r | PPTX r | WTV r
4569
+ DCR r | ICS r | MPG r | PS r/w | WV r
4570
+ DFONT r | IDML r | MPO r/w | PSB r/w | X3F r/w
4571
+ DIVX r | IIQ r/w | MQV r/w | PSD r/w | XCF r
4572
+ DJVU r | IND r/w | MRC r | PSP r | XLS r
4573
+ DLL r | INSP r/w | MRW r/w | QTIF r/w | XLSX r
4574
+ DNG r/w | INSV r | MXF r | R3D r | XMP r/w/c
4575
+ DOC r | INX r | NEF r/w | RA r | ZIP r
4576
+ DOCX r | ISO r | NKSC r/w | RAF r/w |
4574
4577
 
4575
4578
  Meta Information
4576
4579
  ----------------------+----------------------+---------------------
@@ -5059,8 +5062,8 @@ are in the default output. By default, list items are separated by a
5059
5062
  newline when extracted with the B<-b> option, but this may be changed (see
5060
5063
  the B<-sep> option for details). May be combined with B<-j>, B<-php> or
5061
5064
  B<-X> to extract binary data in JSON, PHP or XML format, but note that
5062
- "Unsafe" tags are not extracted as binary unless they are specified explicitly or
5063
- the API RequestAll option is set to 3 or higher.
5065
+ "Unsafe" tags are not extracted as binary unless they are specified
5066
+ explicitly or the API RequestAll option is set to 3 or higher.
5064
5067
 
5065
5068
  With a leading double dash (B<--b> or B<--binary>), tags which contain
5066
5069
  binary data are suppressed in the output when reading.
@@ -5225,7 +5228,8 @@ option has no effect on date-only or time-only tags and ignores timezone
5225
5228
  information if present. ExifTool adds a C<%f> format code to represent
5226
5229
  fractional seconds, and supports an optional width to specify the number of
5227
5230
  digits after the decimal point (eg. C<%3f> would give something like
5228
- C<.437>). Only one B<-d> option may be used per command. Requires
5231
+ C<.437>), and a minus sign to drop the decimal point (eg. C<%-3f> would give
5232
+ C<437>). Only one B<-d> option may be used per command. Requires
5229
5233
  POSIX::strptime or Time::Piece for the inversion conversion when writing.
5230
5234
 
5231
5235
  =item B<-D> (B<-decimal>)
@@ -5470,7 +5474,7 @@ with this command:
5470
5474
 
5471
5475
  produces output like this:
5472
5476
 
5473
- -- Generated by ExifTool 12.45 --
5477
+ -- Generated by ExifTool 12.50 --
5474
5478
  File: a.jpg - 2003:10:31 15:44:19
5475
5479
  (f/5.6, 1/60s, ISO 100)
5476
5480
  File: b.jpg - 2006:05:23 11:57:38
@@ -5492,7 +5496,12 @@ warnings and leave the missing values empty. Alternatively, B<-q -q> may be
5492
5496
  used to simply suppress the warning messages.
5493
5497
 
5494
5498
  The L</Advanced formatting feature> may be used to modify the values of
5495
- individual tags with the B<-p> option.
5499
+ individual tags within the B<-p> option string.
5500
+
5501
+ Note that the API RequestTags option is automatically set for all tags used
5502
+ in the I<FMTFILE> or I<STR>. This allows all other tags to be ignored using
5503
+ B<-API IgnoreTags=all>, resulting in reduced memory usage and increased
5504
+ speed.
5496
5505
 
5497
5506
  =item B<-php>
5498
5507
 
@@ -5884,12 +5893,14 @@ audio/video data in WAV/AVI files to search for additional metadata. These
5884
5893
  speed benefits are small when reading images directly from disk, but can be
5885
5894
  substantial if piping images through a network connection. For more
5886
5895
  substantial speed benefits, B<-fast2> also causes exiftool to avoid
5887
- extracting any EXIF MakerNote information. B<-fast3> avoids extracting
5888
- metadata from the file, and returns only pseudo System tags, but still reads
5889
- the file header to obtain an educated guess at FileType. B<-fast4> doesn't
5890
- even read the file header, and returns only System tags and a FileType based
5891
- on the file extension. B<-fast5> also disables generation of the Composite
5892
- tags (like B<-e>). Has no effect when writing.
5896
+ extracting any EXIF MakerNote information, and to stop processing at the
5897
+ IDAT chunk of PNG images and the mdat atom of QuickTime-format files (but
5898
+ note that some files may store metadata after this). B<-fast3> avoids
5899
+ extracting metadata from the file, and returns only pseudo System tags, but
5900
+ still reads the file header to obtain an educated guess at FileType.
5901
+ B<-fast4> doesn't even read the file header, and returns only System tags
5902
+ and a FileType based on the file extension. B<-fast5> also disables
5903
+ generation of the Composite tags (like B<-e>). Has no effect when writing.
5893
5904
 
5894
5905
  Note that a separate B<-fast> setting may be used for evaluation of a B<-if>
5895
5906
  condition, or when ordering files with the B<-fileOrder> option. See the
@@ -5909,14 +5920,13 @@ order may be reversed by prefixing the tag name with a C<-> (eg.
5909
5920
  C<-fileOrder -createdate>). Print conversion of the sorted values is
5910
5921
  disabled with the B<-n> option, or a C<#> appended to the tag name. Other
5911
5922
  formatting options (eg. B<-d>) have no effect on the sorted values. Note
5912
- that the B<-fileOrder> option can have a large performance impact since it
5913
- involves an additional processing pass of each file, but this impact may be
5914
- reduced by specifying a I<NUM> for the B<-fast> level used during the
5915
- metadata-extraction phase. For example, B<-fileOrder4> may be used if
5916
- I<TAG> is a pseudo System tag. If multiple B<-fileOrder> options are used,
5917
- the extraction is done at the lowest B<-fast> level. Note that files are
5918
- sorted across directory boundaries if multiple input directories are
5919
- specified.
5923
+ that the B<-fileOrder> option can incur large performance penalty since it
5924
+ involves an additional initial processing pass of all files, but this impact
5925
+ may be reduced by specifying a I<NUM> to effectively set the B<-fast> level
5926
+ for the initial pass. For example, B<-fileOrder4> may be used if I<TAG> is
5927
+ a pseudo System tag. If multiple B<-fileOrder> options are used, the
5928
+ extraction is done at the lowest B<-fast> level. Note that files are sorted
5929
+ across directory boundaries if multiple input directories are specified.
5920
5930
 
5921
5931
  =item B<-i> I<DIR> (B<-ignore>)
5922
5932
 
@@ -6003,6 +6013,9 @@ the values of duplicate tags are accessible only by specifying a group name
6003
6013
  command when B<-execute> was used, and may be used like any other tag in the
6004
6014
  condition (ie. "$OK").
6005
6015
 
6016
+ 7) The API RequestTags option is automatically set for all tags used in the
6017
+ B<-if> condition.
6018
+
6006
6019
  =item B<-m> (B<-ignoreMinorErrors>)
6007
6020
 
6008
6021
  Ignore minor errors and warnings. This enables writing to files with minor
@@ -6248,12 +6261,13 @@ are some examples:
6248
6261
 
6249
6262
  When combined with B<-listx>, the B<-s> option shortens the output by
6250
6263
  omitting the descriptions and values (as in the last example above), and
6251
- B<-f> adds a 'flags' attribute if applicable. The flags are formatted as a
6252
- comma-separated list of the following possible values: Avoid, Binary, List,
6253
- Mandatory, Permanent, Protected, Unknown and Unsafe (see the L<Tag Name
6254
- documentation|Image::ExifTool::TagNames>). For XMP List tags, the list type
6255
- (Alt, Bag or Seq) is added to the flags, and flattened structure tags are
6256
- indicated by a Flattened flag.
6264
+ B<-f> adds 'flags' and 'struct' attributes if applicable. The flags are
6265
+ formatted as a comma-separated list of the following possible values:
6266
+ Avoid, Binary, List, Mandatory, Permanent, Protected, Unknown and Unsafe
6267
+ (see the L<Tag Name documentation|Image::ExifTool::TagNames>). For XMP List
6268
+ tags, the list type (Alt, Bag or Seq) is added to the flags, and flattened
6269
+ structure tags are indicated by a Flattened flag with 'struct' giving the ID
6270
+ of the parent structure.
6257
6271
 
6258
6272
  Note that none of the B<-list> options require an input I<FILE>.
6259
6273
 
@@ -15,7 +15,7 @@ use vars qw($VERSION);
15
15
  use Image::ExifTool::Exif;
16
16
  use Image::ExifTool::PLIST;
17
17
 
18
- $VERSION = '1.06';
18
+ $VERSION = '1.07';
19
19
 
20
20
  # Apple iPhone metadata (ref PH)
21
21
  %Image::ExifTool::Apple::Main = (
@@ -80,7 +80,7 @@ $VERSION = '1.06';
80
80
  # 0x000e - int32s: 0,1,4,12 (Orientation? 0=landscape? 4=portrait? ref 1)
81
81
  # 0x000f - int32s: 2,3
82
82
  # 0x0010 - int32s: 1
83
- 0x0011 => {
83
+ 0x0011 => { # (if defined, there is a live photo associated with the video, #forum13565)
84
84
  Name => 'MediaGroupUUID', #NealKrawetz private communication
85
85
  # (changed in 12.19 from Name => 'ContentIdentifier', #forum8750)
86
86
  Writable => 'string',
@@ -91,6 +91,10 @@ $VERSION = '1.06';
91
91
  Writable => 'string',
92
92
  },
93
93
  # 0x0016 - string[29]: "AXZ6pMTOh2L+acSh4Kg630XCScoO\0"
94
+ 0x0017 => { #forum13565 (only valid if MediaGroupUUID exists)
95
+ Name => 'LivePhotoVideoIndex',
96
+ Notes => 'divide by RunTimeScale to get time in seconds',
97
+ },
94
98
  # 0x0017 - int32s: 0,8192
95
99
  # 0x0019 - int32s: 0,2,128
96
100
  # 0x001a - string[6]: "q825s\0"
@@ -35,7 +35,7 @@ use Image::ExifTool::Sony;
35
35
  use Image::ExifTool::Validate;
36
36
  use Image::ExifTool::MacOS;
37
37
 
38
- $VERSION = '3.48';
38
+ $VERSION = '3.50';
39
39
  @ISA = qw(Exporter);
40
40
 
41
41
  sub NumbersFirst($$);
@@ -501,11 +501,13 @@ been decoded. Use the L<Unknown|../ExifTool.html#Unknown> (-u) option to extrac
501
501
  },
502
502
  GeoTiff => q{
503
503
  ExifTool extracts the following tags from GeoTIFF images. See
504
- L<http://www.remotesensing.org/geotiff/spec/geotiffhome.html> for the
505
- complete GeoTIFF specification. Also included in the table below are
506
- ChartTIFF tags (see L<http://www.charttiff.com/whitepapers.shtml>). GeoTIFF
507
- tags are not writable individually, but they may be copied en mass via the
508
- block tags GeoTiffDirectory, GeoTiffDoubleParams and GeoTiffAsciiParams.
504
+ L<https://web.archive.org/web/20070820121549/http://www.remotesensing.org/geotiff/spec/geotiffhome.html>
505
+ for the complete GeoTIFF specification. Also included in the table below
506
+ are ChartTIFF tags (see
507
+ L<https://web.archive.org/web/20020828193928/http://www.charttiff.com/whitepapers.shtml>).
508
+ GeoTIFF tags are not writable individually, but they may be copied en mass
509
+ via the block tags GeoTiffDirectory, GeoTiffDoubleParams and
510
+ GeoTiffAsciiParams.
509
511
  },
510
512
  JFIF => q{
511
513
  The following information is extracted from the JPEG JFIF header. See
@@ -1289,16 +1291,19 @@ TagID: foreach $tagID (@keys) {
1289
1291
  $printConv = shift @printConvList;
1290
1292
  $index = shift @indexList;
1291
1293
  }
1292
- } elsif ($printConv and $printConv =~ /DecodeBits\(\$val,\s*(\{.*\})\s*\)/s) {
1294
+ # look inside scalar PrintConv for a bit/byte conversion
1295
+ # (see Photoshop:PrintFlags for use of "$byte" decoding)
1296
+ } elsif ($printConv and $printConv =~ /DecodeBits\(\$(val|byte),\s*(\\\%[\w:]+|\{.*\})\s*\)/s) {
1297
+ my $type = $1 eq 'byte' ? 'Byte' : 'Bit';
1293
1298
  $$self{Model} = ''; # needed for Nikon ShootingMode
1294
- my $bits = eval $1;
1299
+ my $bits = eval $2;
1295
1300
  delete $$self{Model};
1296
1301
  if ($@) {
1297
1302
  warn $@;
1298
1303
  } else {
1299
1304
  my @pk = sort { NumbersFirst($a,$b) } keys %$bits;
1300
1305
  foreach (@pk) {
1301
- push @values, "Bit $_ = " . $$bits{$_};
1306
+ push @values, "$type $_ = " . $$bits{$_};
1302
1307
  }
1303
1308
  }
1304
1309
  }
@@ -2573,6 +2578,9 @@ sub WriteTagNames($$)
2573
2578
  $tip = '';
2574
2579
  # use copyright symbol in QuickTime UserData tags
2575
2580
  $tagIDstr =~ s/^"\\xa9/"&copy;/;
2581
+ # escape necessary characters in html
2582
+ $tagIDstr =~ s/>/&gt;/g;
2583
+ $tagIDstr =~ s/</&lt;/g;
2576
2584
  }
2577
2585
  # add tooltip for special writable attributes
2578
2586
  my $wtip = '';
@@ -88,7 +88,7 @@ sub ProcessCTMD($$$);
88
88
  sub ProcessExifInfo($$$);
89
89
  sub SwapWords($);
90
90
 
91
- $VERSION = '4.60';
91
+ $VERSION = '4.63';
92
92
 
93
93
  # Note: Removed 'USM' from 'L' lenses since it is redundant - PH
94
94
  # (or is it? Ref 32 shows 5 non-USM L-type lenses)
@@ -480,6 +480,7 @@ $VERSION = '4.60';
480
480
  255 => 'Sigma 24-105mm f/4 DG OS HSM | A or Other Lens', #50
481
481
  255.1 => 'Sigma 180mm f/2.8 EX DG OS HSM APO Macro', #50
482
482
  255.2 => 'Tamron SP 70-200mm f/2.8 Di VC USD', #exiv issue 1202 (A009)
483
+ 255.3 => 'Yongnuo YN 50mm f/1.8', #50
483
484
  368 => 'Sigma 14-24mm f/2.8 DG HSM | A or other Sigma Lens', #IB (A018)
484
485
  368.1 => 'Sigma 20mm f/1.4 DG HSM | A', #50 (newer firmware)
485
486
  368.2 => 'Sigma 50mm f/1.4 DG HSM | A', #50
@@ -493,6 +494,7 @@ $VERSION = '4.60';
493
494
  '368.10' => 'Sigma 35mm f/1.4 DG HSM | A', #PH (012)
494
495
  '368.11' => 'Sigma 70mm f/2.8 DG Macro', #IB (A018)
495
496
  '368.12' => 'Sigma 18-35mm f/1.8 DC HSM | A', #50
497
+ '368.13' => 'Sigma 24-105mm f/4 DG OS HSM | A', #forum3833
496
498
  # Note: LensType 488 (0x1e8) is reported as 232 (0xe8) in 7D CameraSettings
497
499
  488 => 'Canon EF-S 15-85mm f/3.5-5.6 IS USM', #PH
498
500
  489 => 'Canon EF 70-300mm f/4-5.6L IS USM', #Gerald Kapounek
@@ -602,8 +604,8 @@ $VERSION = '4.60';
602
604
  '61182.24' => 'Canon RF 14-35mm F4L IS USM', #IB
603
605
  '61182.25' => 'Canon RF-S 18-45mm F4.5-6.3 IS STM', #42
604
606
  '61182.26' => 'Canon RF 100-400mm F5.6-8 IS USM', #42
605
- '61182.27' => 'Canon RF 100-400mm F5.6-8 IS USM + RF1.4x', #42 (NC)
606
- '61182.28' => 'Canon RF 100-400mm F5.6-8 IS USM + RF2x', #42 (NC)
607
+ '61182.27' => 'Canon RF 100-400mm F5.6-8 IS USM + RF1.4x', #42
608
+ '61182.28' => 'Canon RF 100-400mm F5.6-8 IS USM + RF2x', #42
607
609
  '61182.29' => 'Canon RF-S 18-150mm F3.5-6.3 IS STM', #42
608
610
  '61182.30' => 'Canon RF 24mm F1.8 MACRO IS STM', #42
609
611
  '61182.31' => 'Canon RF 16mm F2.8 STM', #42
@@ -612,10 +614,15 @@ $VERSION = '4.60';
612
614
  '61182.34' => 'Canon RF 400mm F2.8L IS USM + RF2x', #IB
613
615
  '61182.35' => 'Canon RF 600mm F4L IS USM', #GiaZopatti
614
616
  '61182.36' => 'Canon RF 15-30mm F4.5-6.3 IS STM', #42
617
+ '61182.37' => 'Canon RF 800mm F5.6L IS USM', #42
618
+ '61182.38' => 'Canon RF 800mm F5.6L IS USM + RF1.4x', #42
619
+ '61182.39' => 'Canon RF 800mm F5.6L IS USM + RF2x', #42
620
+ '61182.40' => 'Canon RF 1200mm F8L IS USM', #42
621
+ '61182.41' => 'Canon RF 1200mm F8L IS USM + RF1.4x', #42
622
+ '61182.42' => 'Canon RF 1200mm F8L IS USM + RF2x', #42
623
+ '61182.43' => 'Canon RF 135mm F1.8 L IS USM', #42
615
624
  # we need the RFLensType values for the following...
616
- '61182.37' => 'Canon RF 800mm F5.6L IS USM', #PH (NC)
617
- '61182.38' => 'Canon RF 1200mm F8L IS USM', #PH (NC)
618
- '61182.39' => 'Canon RF 5.2mm F2.8L Dual Fisheye 3D VR', #PH (NC)
625
+ '61182.44' => 'Canon RF 5.2mm F2.8L Dual Fisheye 3D VR', #PH (NC)
619
626
  65535 => 'n/a',
620
627
  );
621
628
 
@@ -976,6 +983,7 @@ $VERSION = '4.60';
976
983
  0x80000465 => 'EOS R10', #42
977
984
  0x80000467 => 'PowerShot ZOOM',
978
985
  0x80000468 => 'EOS M50 Mark II / Kiss M2', #IB
986
+ 0x80000481 => 'EOS R6 Mark II', #42
979
987
  0x80000520 => 'EOS D2000C', #IB
980
988
  0x80000560 => 'EOS D6000C', #PH (guess)
981
989
  );
@@ -1938,7 +1946,7 @@ my %offOn = ( 0 => 'Off', 1 => 'On' );
1938
1946
  SubDirectory => { TagTable => 'Image::ExifTool::Canon::ColorData10' },
1939
1947
  },
1940
1948
  { # (int16u[3973]) - R3 ref IB
1941
- Condition => '$count == 3973',
1949
+ Condition => '$count == 3973 or $count == 3778',
1942
1950
  Name => 'ColorData11',
1943
1951
  SubDirectory => { TagTable => 'Image::ExifTool::Canon::ColorData11' },
1944
1952
  },
@@ -6371,10 +6379,11 @@ my %ciMaxFocal = (
6371
6379
  1 => {
6372
6380
  Name => 'TimeZone',
6373
6381
  PrintConv => 'Image::ExifTool::TimeZoneString($val)',
6374
- PrintConvInv => sub {
6375
- my $val = shift;
6376
- $val =~ /^([-+]?)(\d{1,2}):?(\d{2})$/ or return undef;
6377
- return(($1 eq '-' ? -1 : 1) * ($2 * 60 + $3));
6382
+ PrintConvInv => q{
6383
+ $val =~ /Z$/ and return 0;
6384
+ $val =~ /([-+])(\d{1,2}):?(\d{2})$/ and return $1 . ($2 * 60 + $3);
6385
+ $val =~ /^(\d{2})(\d{2})$/ and return $1 * 60 + $2;
6386
+ return undef;
6378
6387
  },
6379
6388
  },
6380
6389
  2 => {
@@ -6814,8 +6823,8 @@ my %ciMaxFocal = (
6814
6823
  281 => 'Canon RF 14-35mm F4L IS USM', #42/IB
6815
6824
  282 => 'Canon RF-S 18-45mm F4.5-6.3 IS STM', #42
6816
6825
  283 => 'Canon RF 100-400mm F5.6-8 IS USM', #42
6817
- 284 => 'Canon RF 100-400mm F5.6-8 IS USM + RF1.4x', #42 (NC)
6818
- 285 => 'Canon RF 100-400mm F5.6-8 IS USM + RF2x', #42 (NC)
6826
+ 284 => 'Canon RF 100-400mm F5.6-8 IS USM + RF1.4x', #42
6827
+ 285 => 'Canon RF 100-400mm F5.6-8 IS USM + RF2x', #42
6819
6828
  286 => 'Canon RF-S 18-150mm F3.5-6.3 IS STM', #42
6820
6829
  287 => 'Canon RF 24mm F1.8 MACRO IS STM', #42
6821
6830
  288 => 'Canon RF 16mm F2.8 STM', #42
@@ -6823,7 +6832,14 @@ my %ciMaxFocal = (
6823
6832
  290 => 'Canon RF 400mm F2.8L IS USM + RF1.4x', #IB
6824
6833
  291 => 'Canon RF 400mm F2.8L IS USM + RF2x', #IB
6825
6834
  292 => 'Canon RF 600mm F4L IS USM', #GiaZopatti
6835
+ 295 => 'Canon RF 800mm F5.6L IS USM', #42
6836
+ 296 => 'Canon RF 800mm F5.6L IS USM + RF1.4x', #42
6837
+ 297 => 'Canon RF 800mm F5.6L IS USM + RF2x', #42
6838
+ 298 => 'Canon RF 1200mm F8L IS USM', #42
6839
+ 299 => 'Canon RF 1200mm F8L IS USM + RF1.4x', #42
6840
+ 300 => 'Canon RF 1200mm F8L IS USM + RF2x', #42
6826
6841
  302 => 'Canon RF 15-30mm F4.5-6.3 IS STM', #42
6842
+ 303 => 'Canon RF 135mm F1.8 L IS USM', #42
6827
6843
  # Note: add new RF lenses to %canonLensTypes with ID 61182
6828
6844
  },
6829
6845
  },
@@ -8321,7 +8337,7 @@ my %ciMaxFocal = (
8321
8337
  # Color data (MakerNotes tag 0x4001, count=3973, ref IB)
8322
8338
  %Image::ExifTool::Canon::ColorData11 = (
8323
8339
  %binaryDataAttrs,
8324
- NOTES => 'These tags are used by the EOS R3',
8340
+ NOTES => 'These tags are used by the EOS R3, R7 and R6mkII',
8325
8341
  FORMAT => 'int16s',
8326
8342
  FIRST_ENTRY => 0,
8327
8343
  GROUPS => { 0 => 'MakerNotes', 2 => 'Camera' },
@@ -8333,6 +8349,7 @@ my %ciMaxFocal = (
8333
8349
  RawConv => '$$self{ColorDataVersion} = $val',
8334
8350
  PrintConv => {
8335
8351
  34 => '34 (R3)', #IB
8352
+ 48 => '48 (R7, R10, R6 Mark II)', #IB
8336
8353
  },
8337
8354
  },
8338
8355
  0x69 => { Name => 'WB_RGGBLevelsAsShot', Format => 'int16s[4]' },
@@ -21,7 +21,7 @@ use Image::ExifTool qw(:DataAccess :Utils);
21
21
  use Image::ExifTool::Exif;
22
22
  use Image::ExifTool::Canon;
23
23
 
24
- $VERSION = '1.58';
24
+ $VERSION = '1.59';
25
25
 
26
26
  sub WriteCRW($$);
27
27
  sub ProcessCanonRaw($$$);
@@ -625,6 +625,13 @@ sub ProcessCanonRaw($$$)
625
625
  $raf->Seek($blockStart+$blockSize-4, 0) or return 0;
626
626
  $raf->Read($buff, 4) == 4 or return 0;
627
627
  my $dirOffset = Get32u(\$buff,0) + $blockStart;
628
+ # avoid infinite recursion
629
+ $$et{ProcessedCanonRaw} or $$et{ProcessedCanonRaw} = { };
630
+ if ($$et{ProcessedCanonRaw}{$dirOffset}) {
631
+ $et->Warn("Not processing double-referenced $$dirInfo{DirName} directory");
632
+ return 0;
633
+ }
634
+ $$et{ProcessedCanonRaw}{$dirOffset} = 1;
628
635
  $raf->Seek($dirOffset, 0) or return 0;
629
636
  $raf->Read($buff, 2) == 2 or return 0;
630
637
  my $entries = Get16u(\$buff,0); # get number of entries in directory
@@ -56,7 +56,7 @@ use vars qw($VERSION $AUTOLOAD @formatSize @formatName %formatNumber %intFormat
56
56
  use Image::ExifTool qw(:DataAccess :Utils);
57
57
  use Image::ExifTool::MakerNotes;
58
58
 
59
- $VERSION = '4.41';
59
+ $VERSION = '4.42';
60
60
 
61
61
  sub ProcessExif($$$);
62
62
  sub WriteExif($$$);
@@ -1084,11 +1084,11 @@ my %opcodeInfo = (
1084
1084
  {
1085
1085
  Name => 'ThumbnailOffset',
1086
1086
  Notes => q{
1087
- ThumbnailOffset in IFD1 of JPEG and some TIFF-based images, IFD0 of MRW
1088
- images and AVI and MOV videos, and the SubIFD in IFD1 of SRW images;
1089
- PreviewImageStart in MakerNotes and IFD0 of ARW and SR2 images;
1090
- JpgFromRawStart in SubIFD of NEF images and IFD2 of PEF images; and
1091
- OtherImageStart in everything else
1087
+ called JPEGInterchangeFormat in the specification, this is ThumbnailOffset
1088
+ in IFD1 of JPEG and some TIFF-based images, IFD0 of MRW images and AVI and
1089
+ MOV videos, and the SubIFD in IFD1 of SRW images; PreviewImageStart in
1090
+ MakerNotes and IFD0 of ARW and SR2 images; JpgFromRawStart in SubIFD of NEF
1091
+ images and IFD2 of PEF images; and OtherImageStart in everything else
1092
1092
  },
1093
1093
  # thumbnail is found in IFD1 of JPEG and TIFF images, and
1094
1094
  # IFD0 of EXIF information in FujiFilm AVI (RIFF) and MOV videos
@@ -1225,6 +1225,7 @@ my %opcodeInfo = (
1225
1225
  {
1226
1226
  Name => 'ThumbnailLength',
1227
1227
  Notes => q{
1228
+ called JPEGInterchangeFormatLength in the specification, this is
1228
1229
  ThumbnailLength in IFD1 of JPEG and some TIFF-based images, IFD0 of MRW
1229
1230
  images and AVI and MOV videos, and the SubIFD in IFD1 of SRW images;
1230
1231
  PreviewImageLength in MakerNotes and IFD0 of ARW and SR2 images;
@@ -2080,6 +2081,7 @@ my %opcodeInfo = (
2080
2081
  Groups => { 2 => 'Time' },
2081
2082
  Notes => 'time zone for ModifyDate',
2082
2083
  Writable => 'string',
2084
+ Shift => 'Time',
2083
2085
  PrintConvInv => q{
2084
2086
  return "+00:00" if $val =~ /\d{2}Z$/;
2085
2087
  return sprintf("%s%.2d:%.2d",$1,$2,$3) if $val =~ /([-+])(\d{1,2}):(\d{2})/;
@@ -2091,6 +2093,7 @@ my %opcodeInfo = (
2091
2093
  Groups => { 2 => 'Time' },
2092
2094
  Notes => 'time zone for DateTimeOriginal',
2093
2095
  Writable => 'string',
2096
+ Shift => 'Time',
2094
2097
  PrintConvInv => q{
2095
2098
  return "+00:00" if $val =~ /\d{2}Z$/;
2096
2099
  return sprintf("%s%.2d:%.2d",$1,$2,$3) if $val =~ /([-+])(\d{1,2}):(\d{2})/;
@@ -2102,6 +2105,7 @@ my %opcodeInfo = (
2102
2105
  Groups => { 2 => 'Time' },
2103
2106
  Notes => 'time zone for CreateDate',
2104
2107
  Writable => 'string',
2108
+ Shift => 'Time',
2105
2109
  PrintConvInv => q{
2106
2110
  return "+00:00" if $val =~ /\d{2}Z$/;
2107
2111
  return sprintf("%s%.2d:%.2d",$1,$2,$3) if $val =~ /([-+])(\d{1,2}):(\d{2})/;
@@ -4080,7 +4084,7 @@ my %opcodeInfo = (
4080
4084
  WriteGroup => 'SubIFD' #? (NC) Semantic Mask IFD (only for Validate)
4081
4085
  },
4082
4086
  0xcd30 => { # DNG 1.6
4083
- Name => 'SemanticInstanceIFD',
4087
+ Name => 'SemanticInstanceID',
4084
4088
  # Writable => 'string',
4085
4089
  WriteGroup => 'SubIFD' #? (NC) Semantic Mask IFD (only for Validate)
4086
4090
  },
@@ -6012,7 +6016,8 @@ sub ProcessExif($$$)
6012
6016
  my $tagID = Get16u($dataPt, $entry);
6013
6017
  my $format = Get16u($dataPt, $entry+2);
6014
6018
  my $count = Get32u($dataPt, $entry+4);
6015
- if ($format < 1 or $format > 13) {
6019
+ # (Apple uses the BigTIFF format code 16 in the maker notes of their ProRaw DNG files)
6020
+ if (($format < 1 or $format > 13) and not ($format == 16 and $$et{Make} eq 'Apple' and $inMakerNotes)) {
6016
6021
  if ($mapFmt and $$mapFmt{$format}) {
6017
6022
  $format = $$mapFmt{$format};
6018
6023
  } else {
@@ -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.08';
17
+ $VERSION = '1.09';
18
18
 
19
19
  sub ProcessBitStream($$$);
20
20
 
@@ -29,7 +29,19 @@ sub ProcessBitStream($$$);
29
29
  SubDirectory => { TagTable => 'Image::ExifTool::FLAC::StreamInfo' },
30
30
  },
31
31
  1 => { Name => 'Padding', Binary => 1, Unknown => 1 },
32
- 2 => { Name => 'Application', Binary => 1, Unknown => 1 },
32
+ 2 => [{ # (see forum14064)
33
+ Name => 'Application_riff',
34
+ Condition => '$$valPt =~ /^riff(?!RIFF)/', # (all "riff" blocks but header)
35
+ SubDirectory => {
36
+ TagTable => 'Image::ExifTool::RIFF::Main',
37
+ ByteOrder => 'LittleEndian',
38
+ Start => 4,
39
+ },
40
+ },{
41
+ Name => 'ApplicationUnknown',
42
+ Binary => 1,
43
+ Unknown => 1,
44
+ }],
33
45
  3 => { Name => 'SeekTable', Binary => 1, Unknown => 1 },
34
46
  4 => {
35
47
  Name => 'VorbisComment',
@@ -255,9 +267,11 @@ sub ProcessFLAC($$)
255
267
  print $out "FLAC metadata block, type $tag:\n";
256
268
  $et->VerboseDump(\$buff, DataPos => $raf->Tell() - $size);
257
269
  }
258
- $et->HandleTag($tagTablePtr, $tag, undef,
270
+ $et->HandleTag($tagTablePtr, $tag, $buff,
259
271
  DataPt => \$buff,
260
272
  DataPos => $raf->Tell() - $size,
273
+ Start => 0,
274
+ Size => $size,
261
275
  );
262
276
  last if $last; # all done if is set
263
277
  }