exiftool-vendored.exe 12.96.0 → 12.97.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.
package/README.md CHANGED
@@ -3,8 +3,7 @@
3
3
  Provides the win32 distribution of [ExifTool](http://www.sno.phy.queensu.ca/~phil/exiftool/) to [node](https://nodejs.org/en/).
4
4
 
5
5
  [![npm version](https://img.shields.io/npm/v/exiftool-vendored.exe.svg)](https://www.npmjs.com/package/exiftool-vendored.exe)
6
- [![CI](https://github.com/photostructure/exiftool-vendored.exe/workflows/Node.js%20CI/badge.svg?branch=main)](https://github.com/photostructure/exiftool-vendored.exe/actions?query=workflow%3A%22Node.js+CI%22)
7
-
6
+ [![Node.js CI](https://github.com/photostructure/exiftool-vendored.exe/actions/workflows/node.js.yml/badge.svg?branch=main)](https://github.com/photostructure/exiftool-vendored.exe/actions/workflows/node.js.yml)
8
7
 
9
8
  ## Usage
10
9
 
@@ -11,7 +11,7 @@ use strict;
11
11
  use warnings;
12
12
  require 5.004;
13
13
 
14
- my $version = '12.96';
14
+ my $version = '12.97';
15
15
 
16
16
  # add our 'lib' directory to the include list BEFORE 'use Image::ExifTool'
17
17
  my $exePath;
@@ -4298,17 +4298,20 @@ sub Num2Alpha($)
4298
4298
  sub NextUnusedFilename($;$)
4299
4299
  {
4300
4300
  my ($fmt, $okfile) = @_;
4301
- return $fmt unless $fmt =~ /%[-+]?\d*\.?\d*[lun]?[cC]/;
4301
+ return $fmt unless $fmt =~ /%[-+]?\d*[.:]?\d*[lun]?[cC]/;
4302
4302
  my %sep = ( '-' => '-', '+' => '_' );
4303
4303
  my ($copy, $alpha) = (0, 'a');
4304
+ my $lastFile;
4304
4305
  for (;;) {
4305
4306
  my ($filename, $pos) = ('', 0);
4306
- while ($fmt =~ /(%([-+]?)(\d*)(\.?)(\d*)([lun]?)([cC]))/g) {
4307
+ while ($fmt =~ /(%([-+]?)(\d*)([.:]?)(\d*)([lun]?)([cC]))/g) {
4307
4308
  $filename .= substr($fmt, $pos, pos($fmt) - $pos - length($1));
4308
4309
  $pos = pos($fmt);
4309
4310
  my ($sign, $wid, $dec, $wid2, $mod, $tok) = ($2, $3 || 0, $4, $5 || 0, $6, $7);
4310
4311
  my $seq;
4311
4312
  if ($tok eq 'C') {
4313
+ # increment sequence number for %C on collision if ':' is used
4314
+ $sign eq '-' ? ++$seqFileDir : ++$seqFileNum if $copy and $dec eq ':';
4312
4315
  $seq = $wid + ($sign eq '-' ? $seqFileDir : $seqFileNum) - 1;
4313
4316
  $wid = $wid2;
4314
4317
  } else {
@@ -4337,6 +4340,8 @@ sub NextUnusedFilename($;$)
4337
4340
  my ($fn, $ok) = (AbsPath($filename), AbsPath($okfile));
4338
4341
  return $okfile if defined $fn and defined $ok and $fn eq $ok;
4339
4342
  }
4343
+ return $filename if defined $lastFile and $lastFile eq $filename;
4344
+ $lastFile = $filename;
4340
4345
  ++$copy;
4341
4346
  ++$alpha;
4342
4347
  }
@@ -6999,6 +6999,7 @@ my %ciMaxFocal = (
6999
6999
  314 => 'Canon RF 24-105mm F2.8 L IS USM Z', #42
7000
7000
  315 => 'Canon RF-S 10-18mm F4.5-6.3 IS STM', #42
7001
7001
  316 => 'Canon RF 35mm F1.4 L VCM', #42
7002
+ 318 => 'Canon RF 28-70mm F2.8 IS STM', #42
7002
7003
  # Note: add new RF lenses to %canonLensTypes with ID 61182
7003
7004
  },
7004
7005
  },
@@ -31,7 +31,7 @@ use vars qw($VERSION);
31
31
  use Image::ExifTool qw(:DataAccess :Utils);
32
32
  use Image::ExifTool::Exif;
33
33
 
34
- $VERSION = '1.95';
34
+ $VERSION = '1.96';
35
35
 
36
36
  sub ProcessFujiDir($$$);
37
37
  sub ProcessFaceRec($$$);
@@ -1252,6 +1252,28 @@ my %faceCategories = (
1252
1252
  ValueConv => 'my @v=reverse split(" ",$val);"@v"', # reverse to show width first
1253
1253
  PrintConv => '$val=~tr/ /:/; $val',
1254
1254
  },
1255
+ 0x117 => {
1256
+ Name => 'RawZoomActive',
1257
+ Format => 'int32u',
1258
+ Count => 1,
1259
+ PrintConv => { 0 => 'No', 1 => 'Yes' },
1260
+ },
1261
+ 0x118 => {
1262
+ Name => 'RawZoomTopLeft',
1263
+ Format => 'int16u',
1264
+ Count => 2,
1265
+ Notes => 'relative to RawCroppedImageSize',
1266
+ ValueConv => 'my @v=reverse split(" ",$val);"@v"', # reverse to show width first
1267
+ PrintConv => '$val=~tr/ /x/; $val',
1268
+ },
1269
+ 0x119 => {
1270
+ Name => 'RawZoomSize',
1271
+ Format => 'int16u',
1272
+ Count => 2,
1273
+ Notes => 'relative to RawCroppedImageSize',
1274
+ ValueConv => 'my @v=reverse split(" ",$val);"@v"', # reverse to show width first
1275
+ PrintConv => '$val=~tr/ /x/; $val',
1276
+ },
1255
1277
  0x121 => [
1256
1278
  {
1257
1279
  Name => 'RawImageSize',
@@ -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.07';
17
+ $VERSION = '1.08';
18
18
 
19
19
  # map for writing metadata to InDesign files (currently only write XMP)
20
20
  my %indMap = (
@@ -101,8 +101,22 @@ sub ProcessIND($$)
101
101
  for (;;) {
102
102
  $raf->Read($hdr, 32) or last;
103
103
  unless (length($hdr) == 32 and $hdr =~ /^\Q$objectHeaderGUID/) {
104
- # this must be null padding or we have an error
105
- $hdr =~ /^\0+$/ or $err = 'Corrupt file or unsupported InDesign version';
104
+ # this must be null padding or we have a possible error
105
+ last if $hdr =~ /^\0+$/;
106
+ # (could be up to 4095 bytes of non-null garbage plus 4095 null bytes from ExifTool)
107
+ $raf->Read($buff, 8196) and $hdr .= $buff;
108
+ $hdr =~ s/\0+$//; # remove trailing nulls
109
+ if (length($hdr) > 4095) {
110
+ $err = 'Corrupt file or unsupported InDesign version';
111
+ last;
112
+ }
113
+ my $non = 'Non-null padding at end of file';
114
+ if (not $outfile) {
115
+ $et->Warn($non, 1);
116
+ } elsif (not $et->Error($non, 1)) {
117
+ Write($outfile, $hdr) or $err = 1;
118
+ $writeLen += length $hdr;
119
+ }
106
120
  last;
107
121
  }
108
122
  my $len = Get32u(\$hdr, 24);
@@ -1543,7 +1543,7 @@ sub ProcessJP2($$)
1543
1543
 
1544
1544
  # check to be sure this is a valid JPG2000 file
1545
1545
  return 0 unless $raf->Read($hdr,12) == 12;
1546
- unless ($hdr eq "\0\0\0\x0cjP \x0d\x0a\x87\x0a" or # (ref 1)
1546
+ unless ($hdr eq "\0\0\0\x0cjP \x0d\x0a\x87\x0a" or # (ref 1)
1547
1547
  $hdr eq "\0\0\0\x0cjP\x1a\x1a\x0d\x0a\x87\x0a" or # (ref 2)
1548
1548
  $$et{IsJXL})
1549
1549
  {