exiftool_vendored 12.93.0 → 12.96.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.
- checksums.yaml +4 -4
- data/bin/Changes +28 -2
- data/bin/META.json +1 -1
- data/bin/META.yml +1 -1
- data/bin/README +2 -2
- data/bin/exiftool +15 -44
- data/bin/lib/Image/ExifTool/Canon.pm +128 -1
- data/bin/lib/Image/ExifTool/Font.pm +15 -4
- data/bin/lib/Image/ExifTool/Geotag.pm +19 -5
- data/bin/lib/Image/ExifTool/PostScript.pm +3 -12
- data/bin/lib/Image/ExifTool/QuickTime.pm +34 -20
- data/bin/lib/Image/ExifTool/QuickTimeStream.pl +14 -14
- data/bin/lib/Image/ExifTool/TagLookup.pm +6920 -6906
- data/bin/lib/Image/ExifTool/TagNames.pod +101 -5
- data/bin/lib/Image/ExifTool/WriteQuickTime.pl +48 -16
- data/bin/lib/Image/ExifTool/Writer.pl +4 -53
- data/bin/lib/Image/ExifTool.pm +66 -4
- data/bin/perl-Image-ExifTool.spec +1 -1
- data/lib/exiftool_vendored/version.rb +1 -1
- metadata +2 -2
@@ -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
|
15
|
+
They contain a total of 27985 tags, with 17475 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
|
@@ -9331,6 +9331,7 @@ Unknown only to reduce the volume of the normal output.
|
|
9331
9331
|
ColorData9 Canon ColorData9
|
9332
9332
|
ColorData10 Canon ColorData10
|
9333
9333
|
ColorData11 Canon ColorData11
|
9334
|
+
ColorData12 Canon ColorData12
|
9334
9335
|
ColorDataUnknown Canon ColorDataUnknown
|
9335
9336
|
0x4002 CRWParam? no
|
9336
9337
|
0x4003 ColorInfo Canon ColorInfo
|
@@ -11437,6 +11438,97 @@ These tags are used by the EOS R3, R7 and R6mkII
|
|
11437
11438
|
641 SpecularWhiteLevel int16u
|
11438
11439
|
642 LinearityUpperMargin int16u
|
11439
11440
|
|
11441
|
+
=head3 Canon ColorData12 Tags
|
11442
|
+
|
11443
|
+
These tags are used by the EOS R1 and R5mkII
|
11444
|
+
|
11445
|
+
Index2 Tag Name Writable
|
11446
|
+
------ -------- --------
|
11447
|
+
0 ColorDataVersion int16s
|
11448
|
+
105 WB_RGGBLevelsAsShot int16s[4]
|
11449
|
+
109 ColorTempAsShot int16s
|
11450
|
+
110 WB_RGGBLevelsDaylight int16s[4]
|
11451
|
+
114 ColorTempDaylight int16s
|
11452
|
+
115 WB_RGGBLevelsShade int16s[4]
|
11453
|
+
119 ColorTempShade int16s
|
11454
|
+
120 WB_RGGBLevelsCloudy int16s[4]
|
11455
|
+
124 ColorTempCloudy int16s
|
11456
|
+
125 WB_RGGBLevelsTungsten int16s[4]
|
11457
|
+
129 ColorTempTungsten int16s
|
11458
|
+
130 WB_RGGBLevelsFluorescent int16s[4]
|
11459
|
+
134 ColorTempFluorescent int16s
|
11460
|
+
135 WB_RGGBLevelsFlash int16s[4]
|
11461
|
+
139 ColorTempFlash int16s
|
11462
|
+
140 WB_RGGBLevelsUnknown2? int16s[4]
|
11463
|
+
144 ColorTempUnknown2? int16s
|
11464
|
+
145 WB_RGGBLevelsUnknown3? int16s[4]
|
11465
|
+
149 ColorTempUnknown3? int16s
|
11466
|
+
150 WB_RGGBLevelsUnknown4? int16s[4]
|
11467
|
+
154 ColorTempUnknown4? int16s
|
11468
|
+
155 WB_RGGBLevelsUnknown5? int16s[4]
|
11469
|
+
159 ColorTempUnknown5? int16s
|
11470
|
+
160 WB_RGGBLevelsUnknown6? int16s[4]
|
11471
|
+
164 ColorTempUnknown6? int16s
|
11472
|
+
165 WB_RGGBLevelsUnknown7? int16s[4]
|
11473
|
+
169 ColorTempUnknown7? int16s
|
11474
|
+
170 WB_RGGBLevelsUnknown8? int16s[4]
|
11475
|
+
174 ColorTempUnknown8? int16s
|
11476
|
+
175 WB_RGGBLevelsUnknown9? int16s[4]
|
11477
|
+
179 ColorTempUnknown9? int16s
|
11478
|
+
180 WB_RGGBLevelsUnknown10? int16s[4]
|
11479
|
+
184 ColorTempUnknown10? int16s
|
11480
|
+
185 WB_RGGBLevelsUnknown11? int16s[4]
|
11481
|
+
189 ColorTempUnknown11? int16s
|
11482
|
+
190 WB_RGGBLevelsUnknown12? int16s[4]
|
11483
|
+
194 ColorTempUnknown12? int16s
|
11484
|
+
195 WB_RGGBLevelsUnknown13? int16s[4]
|
11485
|
+
199 ColorTempUnknown13? int16s
|
11486
|
+
200 WB_RGGBLevelsUnknown14? int16s[4]
|
11487
|
+
204 ColorTempUnknown14? int16s
|
11488
|
+
205 WB_RGGBLevelsUnknown15? int16s[4]
|
11489
|
+
209 ColorTempUnknown15? int16s
|
11490
|
+
210 WB_RGGBLevelsUnknown16? int16s[4]
|
11491
|
+
214 ColorTempUnknown16? int16s
|
11492
|
+
215 WB_RGGBLevelsUnknown17? int16s[4]
|
11493
|
+
219 ColorTempUnknown17? int16s
|
11494
|
+
220 WB_RGGBLevelsUnknown18? int16s[4]
|
11495
|
+
224 ColorTempUnknown18? int16s
|
11496
|
+
225 WB_RGGBLevelsUnknown19? int16s[4]
|
11497
|
+
229 ColorTempUnknown19? int16s
|
11498
|
+
230 WB_RGGBLevelsUnknown20? int16s[4]
|
11499
|
+
234 ColorTempUnknown20? int16s
|
11500
|
+
235 WB_RGGBLevelsUnknown21? int16s[4]
|
11501
|
+
239 ColorTempUnknown21? int16s
|
11502
|
+
240 WB_RGGBLevelsUnknown22? int16s[4]
|
11503
|
+
244 ColorTempUnknown22? int16s
|
11504
|
+
245 WB_RGGBLevelsUnknown23? int16s[4]
|
11505
|
+
249 ColorTempUnknown23? int16s
|
11506
|
+
250 WB_RGGBLevelsUnknown24? int16s[4]
|
11507
|
+
254 ColorTempUnknown24? int16s
|
11508
|
+
255 WB_RGGBLevelsUnknown25? int16s[4]
|
11509
|
+
259 ColorTempUnknown25? int16s
|
11510
|
+
260 WB_RGGBLevelsUnknown26? int16s[4]
|
11511
|
+
264 ColorTempUnknown26? int16s
|
11512
|
+
265 WB_RGGBLevelsUnknown27? int16s[4]
|
11513
|
+
269 ColorTempUnknown27? int16s
|
11514
|
+
270 WB_RGGBLevelsUnknown28? int16s[4]
|
11515
|
+
274 ColorTempUnknown28? int16s
|
11516
|
+
275 WB_RGGBLevelsUnknown29? int16s[4]
|
11517
|
+
279 ColorTempUnknown29? int16s
|
11518
|
+
280 WB_RGGBLevelsUnknown30? int16s[4]
|
11519
|
+
284 ColorTempUnknown30? int16s
|
11520
|
+
285 WB_RGGBLevelsUnknown31? int16s[4]
|
11521
|
+
289 ColorTempUnknown31? int16s
|
11522
|
+
290 WB_RGGBLevelsUnknown32? int16s[4]
|
11523
|
+
294 ColorTempUnknown32? int16s
|
11524
|
+
295 WB_RGGBLevelsUnknown33? int16s[4]
|
11525
|
+
299 ColorTempUnknown33? int16s
|
11526
|
+
320 ColorCalib? Canon ColorCalib
|
11527
|
+
383 PerChannelBlackLevel int16u[4]
|
11528
|
+
660 NormalWhiteLevel int16u
|
11529
|
+
661 SpecularWhiteLevel int16u
|
11530
|
+
662 LinearityUpperMargin int16u
|
11531
|
+
|
11440
11532
|
=head3 Canon ColorDataUnknown Tags
|
11441
11533
|
|
11442
11534
|
Index2 Tag Name Writable
|
@@ -29818,16 +29910,18 @@ changed via the config file.
|
|
29818
29910
|
'artist' Artist yes
|
29819
29911
|
'artwork' Artwork yes
|
29820
29912
|
'author' Author yes
|
29821
|
-
'camera.focal_length.35mm_equivalent'
|
29822
|
-
FocalLengthIn35mmFormat yes
|
29823
29913
|
'camera.framereadouttimeinmicroseconds'
|
29824
29914
|
FrameReadoutTime yes
|
29825
29915
|
'camera.identifier' CameraIdentifier yes
|
29826
|
-
'camera.lens_model' LensModel yes
|
29827
29916
|
'collection.user' UserCollection yes
|
29828
|
-
'com.android.capture.fps' AndroidCaptureFPS
|
29917
|
+
'com.android.capture.fps' AndroidCaptureFPS float
|
29918
|
+
'com.android.manufacturer' AndroidMake yes
|
29919
|
+
'com.android.model' AndroidModel yes
|
29829
29920
|
'com.android.version' AndroidVersion yes
|
29830
29921
|
'com.apple.photos.captureMode' CaptureMode yes
|
29922
|
+
'com.xiaomi.hdr10' XiaomiHDR10 int32s
|
29923
|
+
'com.xiaomi.preview_video_cover'
|
29924
|
+
XiaomiPreviewVideoCover int32s
|
29831
29925
|
'comment' Comment yes
|
29832
29926
|
'compatible_brands' CompatibleBrands yes/
|
29833
29927
|
'content.identifier' ContentIdentifier yes
|
@@ -29887,6 +29981,7 @@ changed via the config file.
|
|
29887
29981
|
'title' Title yes
|
29888
29982
|
'version' Version yes
|
29889
29983
|
'video-orientation' VideoOrientation no
|
29984
|
+
'xiaomi.exifInfo.videoinfo' XiaomiExifInfo yes
|
29890
29985
|
'year' Year yes
|
29891
29986
|
|
29892
29987
|
=head3 QuickTime FaceInfo Tags
|
@@ -39366,6 +39461,7 @@ AFM, ACFM and AMFM font files.
|
|
39366
39461
|
Tag ID Tag Name Writable
|
39367
39462
|
------ -------- --------
|
39368
39463
|
'AFM' AFM Font AFM
|
39464
|
+
'C2PA' C2PA Jpeg2000
|
39369
39465
|
'PFM' PFMHeader Font PFM
|
39370
39466
|
'PSInfo' PSFontInfo Font PSInfo
|
39371
39467
|
'fontname' FontName no
|
@@ -847,7 +847,7 @@ sub WriteQuickTime($$$)
|
|
847
847
|
$et or return 1; # allow dummy access to autoload this package
|
848
848
|
my ($mdat, @mdat, @mdatEdit, $edit, $track, $outBuff, $co, $term, $delCount);
|
849
849
|
my (%langTags, $canCreate, $delGrp, %boxPos, %didDir, $writeLast, $err, $atomCount);
|
850
|
-
my ($tag, $lastTag, $errStr);
|
850
|
+
my ($tag, $lastTag, $lastPos, $errStr, $trailer, $buf2);
|
851
851
|
my $outfile = $$dirInfo{OutFile} || return 0;
|
852
852
|
my $raf = $$dirInfo{RAF}; # (will be null for lower-level atoms)
|
853
853
|
my $dataPt = $$dirInfo{DataPt}; # (will be null for top-level atoms)
|
@@ -860,6 +860,16 @@ sub WriteQuickTime($$$)
|
|
860
860
|
my $createKeys = 0;
|
861
861
|
my ($rtnVal, $rtnErr) = $dataPt ? (undef, undef) : (1, 0);
|
862
862
|
|
863
|
+
# check for Insta360 trailer at top level
|
864
|
+
if ($raf) {
|
865
|
+
my $pos = $raf->Tell();
|
866
|
+
if ($raf->Seek(-40, 2) and $raf->Read($buf2, 40) == 40 and
|
867
|
+
substr($buf2, 8) eq '8db42d694ccc418790edff439fe026bf')
|
868
|
+
{
|
869
|
+
$trailer = [ 'Insta360', $raf->Tell() - unpack('V',$buf2) ];
|
870
|
+
}
|
871
|
+
$raf->Seek($pos, 0) or return 0;
|
872
|
+
}
|
863
873
|
if ($dataPt) {
|
864
874
|
$raf = File::RandomAccess->new($dataPt);
|
865
875
|
} else {
|
@@ -923,6 +933,12 @@ sub WriteQuickTime($$$)
|
|
923
933
|
$tag = $lastTag = '';
|
924
934
|
|
925
935
|
for (;;) { # loop through all atoms at this level
|
936
|
+
$lastPos = $raf->Tell();
|
937
|
+
# stop processing if we reached a known trailer
|
938
|
+
if ($trailer and $lastPos >= $$trailer[1]) {
|
939
|
+
$errStr = "Corrupted $$trailer[0] trailer" if $lastPos != $$trailer[1];
|
940
|
+
last;
|
941
|
+
}
|
926
942
|
$lastTag = $tag if $$tagTablePtr{$tag}; # keep track of last known tag
|
927
943
|
if (defined $atomCount and --$atomCount < 0 and $dataPt) {
|
928
944
|
# stop processing now and just copy the rest of the atom
|
@@ -1526,13 +1542,15 @@ sub WriteQuickTime($$$)
|
|
1526
1542
|
if (($lastTag eq 'mdat' or $lastTag eq 'moov') and not $dataPt and (not $$tagTablePtr{$tag} or
|
1527
1543
|
ref $$tagTablePtr{$tag} eq 'HASH' and $$tagTablePtr{$tag}{Unknown}))
|
1528
1544
|
{
|
1529
|
-
|
1530
|
-
|
1531
|
-
|
1532
|
-
|
1545
|
+
# identify other known trailers
|
1546
|
+
$buf2 = '';
|
1547
|
+
$raf->Seek($lastPos,0) and $raf->Read($buf2,8);
|
1548
|
+
if ($buf2 eq 'CCCCCCCC') {
|
1549
|
+
$trailer = [ 'Kenwood', $lastPos ];
|
1550
|
+
} elsif ($buf2 =~ /^(gpsa|gps0|gsen|gsea)...\0/s) {
|
1551
|
+
$trailer = [ 'RIFF', $lastPos ];
|
1533
1552
|
} else {
|
1534
|
-
$
|
1535
|
-
$et->Error('Use "-trailer=" to delete unknown trailer');
|
1553
|
+
$trailer = [ 'Unknown', $lastPos ];
|
1536
1554
|
}
|
1537
1555
|
} else {
|
1538
1556
|
$et->Error($errStr);
|
@@ -1645,27 +1663,26 @@ sub WriteQuickTime($$$)
|
|
1645
1663
|
}
|
1646
1664
|
my $subName = $$subdir{DirName} || $$tagInfo{Name};
|
1647
1665
|
# QuickTime hierarchy is complex, so check full directory path before adding
|
1648
|
-
my $buff;
|
1649
1666
|
if ($createKeys and $curPath eq 'MOV-Movie' and $subName eq 'Meta') {
|
1650
1667
|
$et->VPrint(0, " Creating Meta with mdta Handler and Keys\n");
|
1651
1668
|
# init Meta box for Keys tags with mdta Handler and empty Keys+ItemList
|
1652
|
-
$
|
1669
|
+
$buf2 = "\0\0\0\x20hdlr\0\0\0\0\0\0\0\0mdta\0\0\0\0\0\0\0\0\0\0\0\0" .
|
1653
1670
|
"\0\0\0\x10keys\0\0\0\0\0\0\0\0" .
|
1654
1671
|
"\0\0\0\x08ilst";
|
1655
1672
|
} elsif ($createKeys and $curPath eq 'MOV-Movie-Meta') {
|
1656
|
-
$
|
1673
|
+
$buf2 = ($subName eq 'Keys' ? "\0\0\0\0\0\0\0\0" : '');
|
1657
1674
|
} elsif ($subName eq 'Meta' and $$et{OPTIONS}{QuickTimeHandler}) {
|
1658
1675
|
$et->VPrint(0, " Creating Meta with mdir Handler\n");
|
1659
1676
|
# init Meta box for ItemList tags with mdir Handler
|
1660
|
-
$
|
1677
|
+
$buf2 = "\0\0\0\x20hdlr\0\0\0\0\0\0\0\0mdir\0\0\0\0\0\0\0\0\0\0\0\0";
|
1661
1678
|
} else {
|
1662
1679
|
next unless $curPath eq $writePath and $$addDirs{$subName} and $$addDirs{$subName} eq $dirName;
|
1663
|
-
$
|
1680
|
+
$buf2 = ''; # write from scratch
|
1664
1681
|
}
|
1665
1682
|
my %subdirInfo = (
|
1666
1683
|
Parent => $dirName,
|
1667
1684
|
DirName => $subName,
|
1668
|
-
DataPt => \$
|
1685
|
+
DataPt => \$buf2,
|
1669
1686
|
DirStart => 0,
|
1670
1687
|
HasData => $$subdir{HasData},
|
1671
1688
|
OutFile => $outfile,
|
@@ -1978,9 +1995,8 @@ sub WriteQuickTime($$$)
|
|
1978
1995
|
$result or $et->Error("Truncated mdat atom"), last;
|
1979
1996
|
} else {
|
1980
1997
|
# mdat continues to end of file
|
1981
|
-
|
1982
|
-
|
1983
|
-
Write($outfile, $buff) or $rtnVal = 0, last;
|
1998
|
+
while ($raf->Read($buf2, 65536)) {
|
1999
|
+
Write($outfile, $buf2) or $rtnVal = 0, last;
|
1984
2000
|
}
|
1985
2001
|
}
|
1986
2002
|
}
|
@@ -1989,6 +2005,22 @@ sub WriteQuickTime($$$)
|
|
1989
2005
|
# write the stuff that must come last
|
1990
2006
|
Write($outfile, $writeLast) or $rtnVal = 0 if $writeLast;
|
1991
2007
|
|
2008
|
+
# copy trailer if necessary
|
2009
|
+
if ($rtnVal and $trailer) {
|
2010
|
+
# are we deleting the trailer?
|
2011
|
+
my $nvTrail = $et->GetNewValueHash($Image::ExifTool::Extra{Trailer});
|
2012
|
+
if ($$et{DEL_GROUP}{Trailer} or ($nvTrail and not ($$nvTrail{Value} and $$nvTrail{Value}[0]))) {
|
2013
|
+
$et->Warn("Deleted $$trailer[0] trailer", 1);
|
2014
|
+
} elsif ($raf->Seek($$trailer[1])) {
|
2015
|
+
$et->Warn(sprintf('Copying %s trailer from offset 0x%x', @$trailer), 1);
|
2016
|
+
while ($raf->Read($buf2, 65536)) {
|
2017
|
+
Write($outfile, $buf2) or $rtnVal = 0, last;
|
2018
|
+
}
|
2019
|
+
} else {
|
2020
|
+
$rtnVal = 0;
|
2021
|
+
}
|
2022
|
+
$rtnVal or $et->Error("Error copying $$trailer[0] trailer");
|
2023
|
+
}
|
1992
2024
|
return $rtnVal;
|
1993
2025
|
}
|
1994
2026
|
|
@@ -19,7 +19,6 @@ use Image::ExifTool::Fixup;
|
|
19
19
|
|
20
20
|
sub AssembleRational($$@);
|
21
21
|
sub LastInList($);
|
22
|
-
sub CreateDirectory($$);
|
23
22
|
sub NextFreeTagKey($$);
|
24
23
|
sub RemoveNewValueHash($$$);
|
25
24
|
sub RemoveNewValuesForGroup($$);
|
@@ -2085,9 +2084,10 @@ sub SetFileName($$;$$$)
|
|
2085
2084
|
return 1;
|
2086
2085
|
}
|
2087
2086
|
# create directory for new file if necessary
|
2088
|
-
my $
|
2089
|
-
if (
|
2090
|
-
if ($
|
2087
|
+
my $err = $self->CreateDirectory($newName);
|
2088
|
+
if (defined $err) {
|
2089
|
+
if ($err) {
|
2090
|
+
$self->Warn($err) unless $err =~ /^Error creating/;
|
2091
2091
|
$self->Warn("Error creating directory for '${newName}'");
|
2092
2092
|
return -1;
|
2093
2093
|
}
|
@@ -3554,55 +3554,6 @@ sub IsRawType($)
|
|
3554
3554
|
return $rawType{$$self{FileType}};
|
3555
3555
|
}
|
3556
3556
|
|
3557
|
-
#------------------------------------------------------------------------------
|
3558
|
-
# Create directory for specified file
|
3559
|
-
# Inputs: 0) ExifTool ref, 1) complete file name including path
|
3560
|
-
# Returns: 1 = directory created, 0 = nothing done, -1 = error
|
3561
|
-
my $k32CreateDir;
|
3562
|
-
sub CreateDirectory($$)
|
3563
|
-
{
|
3564
|
-
local $_;
|
3565
|
-
my ($self, $file) = @_;
|
3566
|
-
my $rtnVal = 0;
|
3567
|
-
my $enc = $$self{OPTIONS}{CharsetFileName};
|
3568
|
-
my $dir;
|
3569
|
-
($dir = $file) =~ s/[^\/]*$//; # remove filename from path specification
|
3570
|
-
# recode as UTF-8 if necessary
|
3571
|
-
if ($dir and not $self->IsDirectory($dir)) {
|
3572
|
-
my @parts = split /\//, $dir;
|
3573
|
-
$dir = '';
|
3574
|
-
foreach (@parts) {
|
3575
|
-
$dir .= $_;
|
3576
|
-
if (length $dir and not $self->IsDirectory($dir)) {
|
3577
|
-
# create directory since it doesn't exist
|
3578
|
-
my $d2 = $dir; # (must make a copy in case EncodeFileName recodes it)
|
3579
|
-
if ($self->EncodeFileName($d2)) {
|
3580
|
-
# handle Windows Unicode directory names
|
3581
|
-
unless (eval { require Win32::API }) {
|
3582
|
-
$self->Warn('Install Win32::API to create directories with Unicode names');
|
3583
|
-
return -1;
|
3584
|
-
}
|
3585
|
-
unless ($k32CreateDir) {
|
3586
|
-
return -1 if defined $k32CreateDir;
|
3587
|
-
$k32CreateDir = Win32::API->new('KERNEL32', 'CreateDirectoryW', 'PP', 'I');
|
3588
|
-
unless ($k32CreateDir) {
|
3589
|
-
$self->Warn('Error calling Win32::API::CreateDirectoryW');
|
3590
|
-
$k32CreateDir = 0;
|
3591
|
-
return -1;
|
3592
|
-
}
|
3593
|
-
}
|
3594
|
-
$k32CreateDir->Call($d2, 0) or return -1;
|
3595
|
-
} else {
|
3596
|
-
mkdir($d2, 0777) or return -1;
|
3597
|
-
}
|
3598
|
-
$rtnVal = 1;
|
3599
|
-
}
|
3600
|
-
$dir .= '/';
|
3601
|
-
}
|
3602
|
-
}
|
3603
|
-
return $rtnVal;
|
3604
|
-
}
|
3605
|
-
|
3606
3557
|
#------------------------------------------------------------------------------
|
3607
3558
|
# Copy file attributes from one file to another
|
3608
3559
|
# Inputs: 0) ExifTool ref, 1) source file name, 2) destination file name
|
data/bin/lib/Image/ExifTool.pm
CHANGED
@@ -29,7 +29,7 @@ use vars qw($VERSION $RELEASE @ISA @EXPORT_OK %EXPORT_TAGS $AUTOLOAD @fileTypes
|
|
29
29
|
%jpegMarker %specialTags %fileTypeLookup $testLen $exeDir
|
30
30
|
%static_vars $advFmtSelf);
|
31
31
|
|
32
|
-
$VERSION = '12.
|
32
|
+
$VERSION = '12.96';
|
33
33
|
$RELEASE = '';
|
34
34
|
@ISA = qw(Exporter);
|
35
35
|
%EXPORT_TAGS = (
|
@@ -1873,9 +1873,10 @@ my %systemTagsNotes = (
|
|
1873
1873
|
this write-only tag is used to define the GPS track log data or track log
|
1874
1874
|
file name. Currently supported track log formats are GPX, NMEA RMC/GGA/GLL,
|
1875
1875
|
KML, IGC, Garmin XML and TCX, Magellan PMGNTRK, Honeywell PTNTHPR, Winplus
|
1876
|
-
Beacon text,
|
1877
|
-
"DATETIMEONLY" (all caps) to set GPS date/time tags
|
1878
|
-
are available. See L<geotag.html|../geotag.html>
|
1876
|
+
Beacon text, Bramor gEO, Google Takeout JSON, and CSV log files. May be set
|
1877
|
+
to the special value of "DATETIMEONLY" (all caps) to set GPS date/time tags
|
1878
|
+
if no input track points are available. See L<geotag.html|../geotag.html>
|
1879
|
+
for details
|
1879
1880
|
},
|
1880
1881
|
DelCheck => q{
|
1881
1882
|
require Image::ExifTool::Geotag;
|
@@ -4734,6 +4735,56 @@ sub IsDirectory($$)
|
|
4734
4735
|
return 0;
|
4735
4736
|
}
|
4736
4737
|
|
4738
|
+
#------------------------------------------------------------------------------
|
4739
|
+
# Create directory for specified file
|
4740
|
+
# Inputs: 0) ExifTool ref, 1) complete file name including path
|
4741
|
+
# Returns: '' = directory created, undef = nothing done, otherwise error string
|
4742
|
+
my $k32CreateDir;
|
4743
|
+
sub CreateDirectory($$)
|
4744
|
+
{
|
4745
|
+
local $_;
|
4746
|
+
my ($self, $file) = @_;
|
4747
|
+
my ($err, $dir);
|
4748
|
+
($dir = $file) =~ s/[^\/]*$//; # remove filename from path specification
|
4749
|
+
if ($dir and not $self->IsDirectory($dir)) {
|
4750
|
+
my @parts = split /\//, $dir;
|
4751
|
+
$dir = '';
|
4752
|
+
foreach (@parts) {
|
4753
|
+
$dir .= $_;
|
4754
|
+
if (length and not $self->IsDirectory($dir) and
|
4755
|
+
# don't try to create a network drive root directory
|
4756
|
+
not (IsPC() and $dir =~ m{^//[^/]*$}))
|
4757
|
+
{
|
4758
|
+
my $success;
|
4759
|
+
# create directory since it doesn't exist
|
4760
|
+
my $d2 = $dir; # (must make a copy in case EncodeFileName recodes it)
|
4761
|
+
if ($self->EncodeFileName($d2)) {
|
4762
|
+
# handle Windows Unicode directory names
|
4763
|
+
unless (eval { require Win32::API }) {
|
4764
|
+
$err = 'Install Win32::API to create directories with Unicode names';
|
4765
|
+
last;
|
4766
|
+
}
|
4767
|
+
unless (defined $k32CreateDir) {
|
4768
|
+
$k32CreateDir = Win32::API->new('KERNEL32', 'CreateDirectoryW', 'PP', 'I');
|
4769
|
+
unless ($k32CreateDir) {
|
4770
|
+
$k32CreateDir = 0;
|
4771
|
+
# give this error once, then just "Error creating" for subsequent attempts
|
4772
|
+
return 'Error accessing Win32::API::CreateDirectoryW';
|
4773
|
+
}
|
4774
|
+
}
|
4775
|
+
$success = $k32CreateDir->Call($d2, 0) if $k32CreateDir;
|
4776
|
+
} else {
|
4777
|
+
$success = mkdir($d2, 0777);
|
4778
|
+
}
|
4779
|
+
$success or $err = "Error creating directory $dir", last;
|
4780
|
+
$err = '';
|
4781
|
+
}
|
4782
|
+
$dir .= '/';
|
4783
|
+
}
|
4784
|
+
}
|
4785
|
+
return $err;
|
4786
|
+
}
|
4787
|
+
|
4737
4788
|
#------------------------------------------------------------------------------
|
4738
4789
|
# Get file times (Unix seconds since the epoch)
|
4739
4790
|
# Inputs: 0) ExifTool ref, 1) file name or ref
|
@@ -5648,6 +5699,17 @@ sub SetupTagTable($)
|
|
5648
5699
|
}
|
5649
5700
|
}
|
5650
5701
|
|
5702
|
+
#------------------------------------------------------------------------------
|
5703
|
+
# Is this a PC system?
|
5704
|
+
# Returns: true for PC systems
|
5705
|
+
# uses lookup for O/S names which may use a backslash as a directory separator
|
5706
|
+
# (ref File::Spec of PathTools-3.2701)
|
5707
|
+
my %isPC = (MSWin32 => 1, os2 => 1, dos => 1, NetWare => 1, symbian => 1, cygwin => 1);
|
5708
|
+
sub IsPC()
|
5709
|
+
{
|
5710
|
+
return $isPC{$^O};
|
5711
|
+
}
|
5712
|
+
|
5651
5713
|
#------------------------------------------------------------------------------
|
5652
5714
|
# Utilities to check for numerical types
|
5653
5715
|
# Inputs: 0) value; Returns: true if value is a numerical type
|
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: 12.
|
4
|
+
version: 12.96.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: 2024-
|
12
|
+
date: 2024-09-09 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: exiftool
|