exiftool_vendored 11.96.0 → 11.97.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 +4 -4
- data/bin/Changes +5 -0
- data/bin/META.json +1 -1
- data/bin/META.yml +1 -1
- data/bin/README +2 -2
- data/bin/exiftool +34 -2
- data/bin/lib/Image/ExifTool.pm +1 -1
- data/bin/lib/Image/ExifTool/QuickTimeStream.pl +90 -48
- data/bin/perl-Image-ExifTool.spec +1 -1
- data/lib/exiftool_vendored/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 7221434022aae95d2a68084a499a8b114bbec64edfb43daeefd3e3f33c8b4178
|
4
|
+
data.tar.gz: 51610e0fb64869f5c989ab9dca28ed73156893d2c5ec19b4374fee27fb9bc87b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 9b8bb1e623b568a39c28c6d9eda0b92a00730de352e48c1aa226624323c403a4a5a5b5b6358b247ae3604006f290c088ae64352be741e1206ff4fb938f55bdcb
|
7
|
+
data.tar.gz: 343021ad049d3d2443b0a29060ddad05f691f8ed77b5a175f0c6113a880b13ca86ec21b8cff62c24b95040ae28f0755b6f83acb6c388dbdf60510a5d68536ba1
|
data/bin/Changes
CHANGED
@@ -7,6 +7,11 @@ RSS feed: https://exiftool.org/rss.xml
|
|
7
7
|
Note: The most recent production release is Version 11.85. (Other versions are
|
8
8
|
considered development releases, and are not uploaded to CPAN.)
|
9
9
|
|
10
|
+
Apr. 27, 2020 - Version 11.97
|
11
|
+
|
12
|
+
- Added experimental -efile option (undocumented)
|
13
|
+
- Decode NMEA GGA sentence from streaming GPS of some dashcam videos
|
14
|
+
|
10
15
|
Apr. 24, 2020 - Version 11.96
|
11
16
|
|
12
17
|
- Decode streaming GPS from Lucas LK-7900 Ace AVI videos
|
data/bin/META.json
CHANGED
data/bin/META.yml
CHANGED
data/bin/README
CHANGED
@@ -105,8 +105,8 @@ your home directory, then you would type the following commands in a
|
|
105
105
|
terminal window to extract and run ExifTool:
|
106
106
|
|
107
107
|
cd ~/Desktop
|
108
|
-
gzip -dc Image-ExifTool-11.
|
109
|
-
cd Image-ExifTool-11.
|
108
|
+
gzip -dc Image-ExifTool-11.97.tar.gz | tar -xf -
|
109
|
+
cd Image-ExifTool-11.97
|
110
110
|
./exiftool t/images/ExifTool.jpg
|
111
111
|
|
112
112
|
Note: These commands extract meta information from one of the test images.
|
data/bin/exiftool
CHANGED
@@ -10,7 +10,7 @@
|
|
10
10
|
use strict;
|
11
11
|
require 5.004;
|
12
12
|
|
13
|
-
my $version = '11.
|
13
|
+
my $version = '11.97';
|
14
14
|
|
15
15
|
# add our 'lib' directory to the include list BEFORE 'use Image::ExifTool'
|
16
16
|
my $exeDir;
|
@@ -140,6 +140,8 @@ my $deleteOrig; # 0=restore original files, 1=delete originals, 2=delete w/o
|
|
140
140
|
my $disableOutput; # flag to disable normal output
|
141
141
|
my $doSetFileName; # flag set if FileName may be written
|
142
142
|
my $doUnzip; # flag to extract info from .gz and .bz2 files
|
143
|
+
my $efile; # file for writing list of error file names
|
144
|
+
my $efile2; # file for writing list of failed file names
|
143
145
|
my $escapeC; # C-style escape
|
144
146
|
my $escapeHTML; # flag to escape printed values for html
|
145
147
|
my $evalWarning; # warning from eval
|
@@ -240,6 +242,7 @@ my %optArgs = (
|
|
240
242
|
'-d' => 1, '-dateformat' => 1,
|
241
243
|
'-D' => 0, # necessary to avoid matching lower-case equivalent
|
242
244
|
'-echo' => 1, '-echo1' => 1, '-echo2' => 1, '-echo3' => 1, '-echo4' => 1,
|
245
|
+
'-efile' => 1, '-efile1' => 1, '-efile2' => 1,
|
243
246
|
'-ext' => 1, '--ext' => 1, '-ext+' => 1, '--ext+' => 1,
|
244
247
|
'-extension' => 1, '--extension' => 1, '-extension+' => 1, '--extension+' => 1,
|
245
248
|
'-fileorder' => 1,
|
@@ -439,6 +442,8 @@ undef $deleteOrig;
|
|
439
442
|
undef $disableOutput;
|
440
443
|
undef $doSetFileName;
|
441
444
|
undef $doUnzip;
|
445
|
+
undef $efile;
|
446
|
+
undef $efile2;
|
442
447
|
undef $escapeHTML;
|
443
448
|
undef $escapeC;
|
444
449
|
undef $evalWarning;
|
@@ -868,6 +873,15 @@ for (;;) {
|
|
868
873
|
$mt->Options(Duplicates => 1);
|
869
874
|
next;
|
870
875
|
}
|
876
|
+
if (/^efile([12])?$/i) {
|
877
|
+
@ARGV or Error("Expecting file name for -$_ option\n"), $badCmd=1, next;
|
878
|
+
if (defined $1 and $1 eq '2') {
|
879
|
+
$efile2 = shift;
|
880
|
+
} else {
|
881
|
+
$efile = shift;
|
882
|
+
}
|
883
|
+
next;
|
884
|
+
}
|
871
885
|
# (-execute handled at top of loop)
|
872
886
|
if (/^-?ext(ension)?(\+)?$/i) {
|
873
887
|
my $ext = shift;
|
@@ -1956,6 +1970,15 @@ sub GetImageInfo($$)
|
|
1956
1970
|
}
|
1957
1971
|
unless ($result) {
|
1958
1972
|
$verbose and print $vout "-------- $file (failed condition)$progStr\n";
|
1973
|
+
if ($efile2) {
|
1974
|
+
if ($et->Open(\*FAIL_FILE, $efile2, '>>')) {
|
1975
|
+
print FAIL_FILE $file, "\n" or Warn("Error writing to $efile2\n"), undef $efile2;
|
1976
|
+
close FAIL_FILE;
|
1977
|
+
} else {
|
1978
|
+
Warn("Error opening '${efile2}' for append\n");
|
1979
|
+
undef $efile2;
|
1980
|
+
}
|
1981
|
+
}
|
1959
1982
|
++$countFailed;
|
1960
1983
|
return;
|
1961
1984
|
}
|
@@ -4259,6 +4282,15 @@ sub PrintErrors($$$)
|
|
4259
4282
|
Warn "$tag: $info->{$key} - $file\n";
|
4260
4283
|
}
|
4261
4284
|
}
|
4285
|
+
if ($$info{Error} and $efile) {
|
4286
|
+
if ($et->Open(\*ERR_FILE, $efile, '>>')) {
|
4287
|
+
print ERR_FILE $file, "\n" or Warn("Error writing to $efile\n"), undef $efile;
|
4288
|
+
close ERR_FILE;
|
4289
|
+
} else {
|
4290
|
+
Warn("Error opening '${efile}' for append\n");
|
4291
|
+
undef $efile;
|
4292
|
+
}
|
4293
|
+
}
|
4262
4294
|
return $$info{Error};
|
4263
4295
|
}
|
4264
4296
|
|
@@ -5227,7 +5259,7 @@ with this command:
|
|
5227
5259
|
|
5228
5260
|
produces output like this:
|
5229
5261
|
|
5230
|
-
-- Generated by ExifTool 11.
|
5262
|
+
-- Generated by ExifTool 11.97 --
|
5231
5263
|
File: a.jpg - 2003:10:31 15:44:19
|
5232
5264
|
(f/5.6, 1/60s, ISO 100)
|
5233
5265
|
File: b.jpg - 2006:05:23 11:57:38
|
data/bin/lib/Image/ExifTool.pm
CHANGED
@@ -28,7 +28,7 @@ use vars qw($VERSION $RELEASE @ISA @EXPORT_OK %EXPORT_TAGS $AUTOLOAD @fileTypes
|
|
28
28
|
%mimeType $swapBytes $swapWords $currentByteOrder %unpackStd
|
29
29
|
%jpegMarker %specialTags %fileTypeLookup $testLen $exePath);
|
30
30
|
|
31
|
-
$VERSION = '11.
|
31
|
+
$VERSION = '11.97';
|
32
32
|
$RELEASE = '';
|
33
33
|
@ISA = qw(Exporter);
|
34
34
|
%EXPORT_TAGS = (
|
@@ -678,48 +678,89 @@ sub SetGPSDateTime($$$)
|
|
678
678
|
}
|
679
679
|
}
|
680
680
|
|
681
|
+
#------------------------------------------------------------------------------
|
682
|
+
# Handle tags that we found in the subtitle 'text'
|
683
|
+
# Inputs: 0) ExifTool ref, 1) tag table ref, 2) hash of tag names/values
|
684
|
+
sub HandleTextTags($$$)
|
685
|
+
{
|
686
|
+
my ($et, $tagTbl, $tags) = @_;
|
687
|
+
my $tag;
|
688
|
+
delete $$tags{done};
|
689
|
+
delete $$tags{GPSTimeStamp} if $$tags{GPSDateTime};
|
690
|
+
foreach $tag (sort keys %$tags) {
|
691
|
+
$et->HandleTag($tagTbl, $tag => $$tags{$tag});
|
692
|
+
}
|
693
|
+
$$et{UnknownTextCount} = 0;
|
694
|
+
undef %$tags; # clear the hash
|
695
|
+
}
|
696
|
+
|
681
697
|
#------------------------------------------------------------------------------
|
682
698
|
# Process subtitle 'text'
|
683
699
|
# Inputs: 0) ExifTool ref, 1) tag table ref, 2) data ref, 3) optional sample time
|
684
700
|
sub Process_text($$$)
|
685
701
|
{
|
686
702
|
my ($et, $tagTbl, $buffPt) = @_;
|
687
|
-
my
|
703
|
+
my %tags;
|
688
704
|
|
689
705
|
return if $$et{NoMoreTextDecoding};
|
690
706
|
|
691
707
|
while ($$buffPt =~ /\$(\w+)([^\$]*)/g) {
|
692
708
|
my ($tag, $dat) = ($1, $2);
|
693
|
-
if ($tag =~ /^[A-Z]{2}RMC$/ and $dat =~ /^,(\d{2})(\d{2})(\d+
|
694
|
-
my $
|
695
|
-
|
696
|
-
|
697
|
-
|
698
|
-
|
709
|
+
if ($tag =~ /^[A-Z]{2}RMC$/ and $dat =~ /^,(\d{2})(\d{2})(\d+(?:\.\d*)),A?,(\d*?)(\d{1,2}\.\d+),([NS]),(\d*?)(\d{1,2}\.\d+),([EW]),(\d*\.?\d*),(\d*\.?\d*),(\d{2})(\d{2})(\d+)/) {
|
710
|
+
my $time = "$1:$2:$3";
|
711
|
+
if ($$et{LastTime}) {
|
712
|
+
if ($$et{LastTime} eq $time) {
|
713
|
+
$$et{DOC_NUM} = $$et{LastDoc};
|
714
|
+
} elsif (%tags) {
|
715
|
+
HandleTextTags($et, $tagTbl, \%tags);
|
716
|
+
$$et{DOC_NUM} = ++$$et{DOC_COUNT};
|
717
|
+
}
|
718
|
+
}
|
719
|
+
$$et{LastTime} = $time;
|
720
|
+
$$et{LastDoc} = $$et{DOC_NUM};
|
721
|
+
my $year = $14 + ($14 >= 70 ? 1900 : 2000);
|
722
|
+
my $dateTime = sprintf('%.4d:%.2d:%.2d %sZ', $year, $13, $12, $time);
|
723
|
+
$tags{GPSDateTime} = $dateTime;
|
724
|
+
$tags{GPSLatitude} = (($4 || 0) + $5/60) * ($6 eq 'N' ? 1 : -1);
|
725
|
+
$tags{GPSLongitude} = (($7 || 0) + $8/60) * ($9 eq 'E' ? 1 : -1);
|
726
|
+
if (length $10) {
|
727
|
+
$tags{GPSSpeed} = $10 * $knotsToKph;
|
728
|
+
$tags{GPSSpeedRef} = 'K';
|
729
|
+
}
|
699
730
|
if (length $11) {
|
700
|
-
$
|
701
|
-
$
|
731
|
+
$tags{GPSTrack} = $11;
|
732
|
+
$tags{GPSTrackRef} = 'T';
|
702
733
|
}
|
703
|
-
|
704
|
-
|
705
|
-
|
734
|
+
} elsif ($tag =~ /^[A-Z]{2}GGA$/ and $dat =~ /^,(\d{2})(\d{2})(\d+(?:\.\d*)?),(\d*?)(\d{1,2}\.\d+),([NS]),(\d*?)(\d{1,2}\.\d+),([EW]),[1-6]?,(\d+)?,(\.\d+|\d+\.?\d*)?,(-?\d+\.?\d*)?,M?/s) {
|
735
|
+
my $time = "$1:$2:$3";
|
736
|
+
if ($$et{LastTime}) {
|
737
|
+
if ($$et{LastTime} eq $time) {
|
738
|
+
$$et{DOC_NUM} = $$et{LastDoc};
|
739
|
+
} elsif (%tags) {
|
740
|
+
HandleTextTags($et, $tagTbl, \%tags);
|
741
|
+
$$et{DOC_NUM} = ++$$et{DOC_COUNT};
|
742
|
+
}
|
706
743
|
}
|
707
|
-
|
744
|
+
$$et{LastTime} = $time;
|
745
|
+
$$et{LastDoc} = $$et{DOC_NUM};
|
746
|
+
$tags{GPSTimeStamp} = $time;
|
747
|
+
$tags{GPSLatitude} = (($4 || 0) + $5/60) * ($6 eq 'N' ? 1 : -1);
|
748
|
+
$tags{GPSLongitude} = (($7 || 0) + $8/60) * ($9 eq 'E' ? 1 : -1);
|
749
|
+
$tags{GPSSatellites} = $10 if defined $10;
|
750
|
+
$tags{GPSDOP} = $11 if defined $11;
|
751
|
+
$tags{GPSAltitude} = $12 if defined $12;
|
708
752
|
} elsif ($tag eq 'BEGINGSENSOR' and $dat =~ /^:([-+]\d+\.\d+):([-+]\d+\.\d+):([-+]\d+\.\d+)/) {
|
709
|
-
$
|
710
|
-
$found = 1;
|
753
|
+
$tags{Accelerometer} = "$1 $2 $3";
|
711
754
|
} elsif ($tag eq 'TIME' and $dat =~ /^:(\d+)/) {
|
712
|
-
$
|
713
|
-
$found = 1;
|
755
|
+
$tags{TimeCode} = $1 / ($$et{MediaTS} || 1);
|
714
756
|
} elsif ($tag eq 'BEGIN') {
|
715
|
-
$
|
716
|
-
$
|
757
|
+
$tags{Text} = $dat if length $dat;
|
758
|
+
$tags{done} = 1;
|
717
759
|
} elsif ($tag ne 'END') {
|
718
|
-
$
|
719
|
-
$found = 1;
|
760
|
+
$tags{Text} = "\$$tag$dat";
|
720
761
|
}
|
721
762
|
}
|
722
|
-
|
763
|
+
%tags and HandleTextTags($et, $tagTbl, \%tags), return;
|
723
764
|
|
724
765
|
# check for enciphered binary GPS data
|
725
766
|
# BlueSkySea:
|
@@ -755,7 +796,7 @@ sub Process_text($$$)
|
|
755
796
|
# 0120: 58 00 58 00 58 00 58 00 00 00 00 00 00 00 00 00 [X.X.X.X.........]
|
756
797
|
# 0130: 00 00 00 00 00 00 00 [.......]
|
757
798
|
if ($$buffPt =~ /^\0\0(..\xaa\xaa|\xf2\xe1\xf0\xee)/s and length $$buffPt >= 282) {
|
758
|
-
$val = pack('C*', map { $_ ^ 0xaa } unpack('C*', substr($$buffPt, 8, 14)));
|
799
|
+
my $val = pack('C*', map { $_ ^ 0xaa } unpack('C*', substr($$buffPt, 8, 14)));
|
759
800
|
if ($val =~ /^(\d{4})(\d{2})(\d{2})(\d{2})(\d{2})(\d{2})$/) {
|
760
801
|
$tags{GPSDateTime} = "$1:$2:$3 $4:$5:$6";
|
761
802
|
$val = pack('C*', map { $_ ^ 0xaa } unpack('C*', substr($$buffPt, 38, 9)));
|
@@ -792,12 +833,13 @@ sub Process_text($$$)
|
|
792
833
|
$tags{Accelerometer} = "@acc" if @acc;
|
793
834
|
}
|
794
835
|
}
|
836
|
+
%tags and HandleTextTags($et, $tagTbl, \%tags), return;
|
795
837
|
}
|
796
838
|
|
797
839
|
# check for DJI telemetry data, eg:
|
798
840
|
# "F/3.5, SS 1000, ISO 100, EV 0, GPS (8.6499, 53.1665, 18), D 24.26m,
|
799
841
|
# H 6.00m, H.S 2.10m/s, V.S 0.00m/s \n"
|
800
|
-
if (
|
842
|
+
if ($$buffPt =~ /GPS \(([-+]?\d*\.\d+),\s*([-+]?\d*\.\d+)/) {
|
801
843
|
$$et{CreateDateAtEnd} = 1; # set flag indicating the file creation date is at the end
|
802
844
|
$tags{GPSLatitude} = $2;
|
803
845
|
$tags{GPSLongitude} = $1;
|
@@ -812,11 +854,13 @@ sub Process_text($$$)
|
|
812
854
|
$tags{ExposureTime} = 1 / $1 if $$buffPt =~ /\bSS\s+(\d+\.?\d*)/;
|
813
855
|
$tags{ExposureCompensation} = ($1 / ($2 || 1)) if $$buffPt =~ /\bEV\s+([-+]?\d+\.?\d*)(\/\d+)?/;
|
814
856
|
$tags{ISO} = $1 if $$buffPt =~ /\bISO\s+(\d+\.?\d*)/;
|
857
|
+
HandleTextTags($et, $tagTbl, \%tags);
|
858
|
+
return;
|
815
859
|
}
|
816
860
|
|
817
861
|
# check for Mini 0806 dashcam GPS, eg:
|
818
862
|
# "A,270519,201555.000,3356.8925,N,08420.2071,W,000.0,331.0M,+01.84,-09.80,-00.61;\n"
|
819
|
-
if (
|
863
|
+
if ($$buffPt =~ /^A,(\d{2})(\d{2})(\d{2}),(\d{2})(\d{2})(\d{2}(\.\d+)?)/) {
|
820
864
|
$tags{GPSDateTime} = "20$3:$2:$1 $4:$5:$6Z";
|
821
865
|
if ($$buffPt =~ /^A,.*?,.*?,(\d{2})(\d+\.\d+),([NS])/) {
|
822
866
|
$tags{GPSLatitude} = ($1 + $2/60) * ($3 eq 'S' ? -1 : 1);
|
@@ -828,37 +872,35 @@ sub Process_text($$$)
|
|
828
872
|
$tags{GPSAltitude} = $a[8] if $a[8] and $a[8] =~ s/M$//;
|
829
873
|
$tags{GPSSpeed} = $a[7] if $a[7] and $a[7] =~ /^\d+\.\d+$/; # (NC)
|
830
874
|
$tags{Accelerometer} = "$a[9] $a[10] $a[11]" if $a[11] and $a[11] =~ s/;\s*$//;
|
875
|
+
HandleTextTags($et, $tagTbl, \%tags);
|
876
|
+
return;
|
831
877
|
}
|
832
878
|
|
833
879
|
# check for Thinkware format, eg:
|
834
880
|
# "gsensori,4,512,-67,-12,100;GNRMC,161313.00,A,4529.87489,N,07337.01215,W,6.225,35.34,310819,,,A*52..;
|
835
881
|
# CAR,0,0,0,0.0,0,0,0,0,0,0,0,0"
|
836
|
-
|
837
|
-
|
838
|
-
|
839
|
-
|
840
|
-
|
841
|
-
|
842
|
-
|
843
|
-
|
844
|
-
|
845
|
-
|
846
|
-
|
847
|
-
|
848
|
-
|
849
|
-
|
850
|
-
|
851
|
-
$tags{GPSTrackRef} = 'T';
|
852
|
-
}
|
882
|
+
if ($$buffPt =~ /[A-Z]{2}RMC,(\d{2})(\d{2})(\d+(\.\d*)?),A?,(\d*?)(\d{1,2}\.\d+),([NS]),(\d*?)(\d{1,2}\.\d+),([EW]),(\d*\.?\d*),(\d*\.?\d*),(\d{2})(\d{2})(\d+)/ and
|
883
|
+
# do some basic sanity checks on the date
|
884
|
+
$13 <= 31 and $14 <= 12 and $15 <= 99)
|
885
|
+
{
|
886
|
+
my $year = $15 + ($15 >= 70 ? 1900 : 2000);
|
887
|
+
$tags{GPSDateTime} = sprintf('%.4d:%.2d:%.2d %.2d:%.2d:%.2dZ', $year, $14, $13, $1, $2, $3);
|
888
|
+
$tags{GPSLatitude} = (($5 || 0) + $6/60) * ($7 eq 'N' ? 1 : -1);
|
889
|
+
$tags{GPSLongitude} = (($8 || 0) + $9/60) * ($10 eq 'E' ? 1 : -1);
|
890
|
+
if (length $11) {
|
891
|
+
$tags{GPSSpeed} = $11 * $knotsToKph;
|
892
|
+
$tags{GPSSpeedRef} = 'K';
|
893
|
+
}
|
894
|
+
if (length $12) {
|
895
|
+
$tags{GPSTrack} = $12;
|
896
|
+
$tags{GPSTrackRef} = 'T';
|
853
897
|
}
|
854
|
-
$tags{GSensor} = $1 if $$buffPt =~ /\bgsensori,(.*?)(;|$)/;
|
855
|
-
$tags{Car} = $1 if $$buffPt =~ /\bCAR,(.*?)(;|$)/;
|
856
898
|
}
|
899
|
+
$tags{GSensor} = $1 if $$buffPt =~ /\bgsensori,(.*?)(;|$)/;
|
900
|
+
$tags{Car} = $1 if $$buffPt =~ /\bCAR,(.*?)(;|$)/;
|
901
|
+
|
857
902
|
if (%tags) {
|
858
|
-
|
859
|
-
$et->HandleTag($tagTbl, $tag => $tags{$tag});
|
860
|
-
}
|
861
|
-
$$et{UnknownTextCount} = 0;
|
903
|
+
HandleTextTags($et, $tagTbl, \%tags);
|
862
904
|
} else {
|
863
905
|
$$et{UnknownTextCount} = ($$et{UnknownTextCount} || 0) + 1;
|
864
906
|
# give up trying to decode useful information if we haven't found anything for a while
|
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.
|
4
|
+
version: 11.97.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: 2020-04-
|
12
|
+
date: 2020-04-28 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: exiftool
|