exiftool-vendored.exe 13.31.0 → 13.32.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/bin/exiftool.exe CHANGED
Binary file
@@ -11,7 +11,7 @@ use strict;
11
11
  use warnings;
12
12
  require 5.004;
13
13
 
14
- my $version = '13.31';
14
+ my $version = '13.32';
15
15
 
16
16
  $^W = 1; # enable global warnings
17
17
 
@@ -93,9 +93,9 @@ my @csvFiles; # list of files when reading with CSV option (in ExifTool Ch
93
93
  my @csvTags; # order of tags for first file with CSV option (lower case)
94
94
  my @delFiles; # list of files to delete
95
95
  my @dynamicFiles; # list of -tagsFromFile files with dynamic names and -TAG<=FMT pairs
96
+ my (@echo3, @echo4);# stdout and stderr echo after processing is complete
96
97
  my @efile; # files for writing list of error/fail/same file names
97
98
  my @exclude; # list of excluded tags
98
- my (@echo3, @echo4);# stdout and stderr echo after processing is complete
99
99
  my @files; # list of files and directories to scan
100
100
  my @moreArgs; # more arguments to process after -stay_open -@
101
101
  my @newValues; # list of new tag values to set
@@ -110,7 +110,6 @@ my %csvTags; # lookup for all found tags with CSV option (lower case keys
110
110
  my %database; # lookup for database information based on file name (in ExifTool Charset)
111
111
  my %filterExt; # lookup for filtered extensions
112
112
  my %ignore; # directory names to ignore
113
- my $ignoreHidden; # flag to ignore hidden files
114
113
  my %outComma; # flag that output text file needs a comma
115
114
  my %outTrailer; # trailer for output text file
116
115
  my %preserveTime; # preserved timestamps for files
@@ -122,6 +121,7 @@ my %usedFileName; # lookup for file names we already used in TestName feature
122
121
  my %utf8FileName; # lookup for file names that are UTF-8 encoded
123
122
  my %warnedOnce; # lookup for once-only warnings
124
123
  my %wext; # -W extensions to write
124
+ my %wroteHEAD; # list of output txt files to which we wrote HEAD
125
125
  my $allGroup; # show group name for all tags
126
126
  my $altEnc; # alternate character encoding if not UTF-8
127
127
  my $argFormat; # use exiftool argument-format output
@@ -167,6 +167,7 @@ my $forcePrint; # string to use for missing tag values (undef to not print t
167
167
  my $geoOnly; # flag to extract Geolocation tags only
168
168
  my $helped; # flag to avoid printing help if no tags specified
169
169
  my $html; # flag for html-formatted output (2=html dump)
170
+ my $ignoreHidden; # flag to ignore hidden files
170
171
  my $interrupted; # flag set if CTRL-C is pressed during a critical process
171
172
  my $isBinary; # true if value is a SCALAR ref
172
173
  my $isWriting; # flag set if we are writing tags
@@ -219,7 +220,6 @@ my $validFile; # flag indicating we processed a valid file
219
220
  my $verbose; # verbose setting
220
221
  my $vout; # verbose output file reference (\*STDOUT or \*STDERR by default)
221
222
  my $windowTitle; # title for console window
222
- my %wroteHEAD; # list of output txt files to which we wrote HEAD
223
223
  my $xml; # flag for XML-formatted output
224
224
 
225
225
  # flag to keep the input -@ argfile open:
@@ -464,8 +464,10 @@ undef @efile;
464
464
  undef @exclude;
465
465
  undef @files;
466
466
  undef @newValues;
467
+ undef @requestTags;
467
468
  undef @srcFmt;
468
469
  undef @tags;
470
+ undef %altFile;
469
471
  undef %appended;
470
472
  undef %countLink;
471
473
  undef %created;
@@ -485,6 +487,7 @@ undef %usedFileName;
485
487
  undef %utf8FileName;
486
488
  undef %warnedOnce;
487
489
  undef %wext;
490
+ undef %wroteHEAD;
488
491
  undef $allGroup;
489
492
  undef $altEnc;
490
493
  undef $argFormat;
@@ -501,8 +504,8 @@ undef $doSetFileName;
501
504
  undef $doUnzip;
502
505
  undef $end;
503
506
  undef $endDir;
504
- undef $escapeHTML;
505
507
  undef $escapeC;
508
+ undef $escapeHTML;
506
509
  undef $evalWarning;
507
510
  undef $executeID;
508
511
  undef $failCondition;
@@ -513,18 +516,22 @@ undef $fixLen;
513
516
  undef $forcePrint;
514
517
  undef $geoOnly;
515
518
  undef $ignoreHidden;
519
+ undef $isBinary;
516
520
  undef $joinLists;
517
521
  undef $langOpt;
522
+ undef $listDir;
518
523
  undef $listItem;
519
524
  undef $multiFile;
520
525
  undef $noBinary;
521
526
  undef $outOpt;
527
+ undef $plot;
522
528
  undef $preserveTime;
523
529
  undef $progress;
524
530
  undef $progressCount;
525
531
  undef $progressIncr;
526
532
  undef $progressMax;
527
533
  undef $progressNext;
534
+ undef $rafStdin;
528
535
  undef $recurse;
529
536
  undef $scanWritable;
530
537
  undef $sectHeader;
@@ -534,6 +541,7 @@ undef $showTagID;
534
541
  undef $structOpt;
535
542
  undef $tagOut;
536
543
  undef $textOut;
544
+ undef $textOut2;
537
545
  undef $textOverwrite;
538
546
  undef $tmpFile;
539
547
  undef $tmpText;
@@ -1483,8 +1491,7 @@ if (not @files and not $outOpt and not @newValues) {
1483
1491
  # print help
1484
1492
  unless ((@tags and not $outOpt) or @files or @newValues or $geoOnly) {
1485
1493
  if ($doGlob and $doGlob == 2) {
1486
- Warn "No matching files\n";
1487
- $rtnVal = 1;
1494
+ Error "No matching files\n";
1488
1495
  next;
1489
1496
  }
1490
1497
  if ($outOpt) {
@@ -271,11 +271,11 @@ tags remain.
271
271
 
272
272
  The table below lists all EXIF tags. Also listed are TIFF, DNG, HDP and
273
273
  other tags which are not part of the EXIF specification, but may co-exist
274
- with EXIF tags in some images. Tags which are part of the EXIF 2.32
274
+ with EXIF tags in some images. Tags which are part of the EXIF 3.0
275
275
  specification have an underlined B<Tag Name> in the HTML version of this
276
276
  documentation. See
277
- L<https://web.archive.org/web/20190624045241if_/http://www.cipa.jp:80/std/documents/e/DC-008-Translation-2019-E.pdf>
278
- for the official EXIF 2.32 specification.
277
+ L<https://www.cipa.jp/std/documents/download_e.html?CIPA_DC-008-2024-E>
278
+ for the official EXIF 3.0 specification.
279
279
  },
280
280
  GPS => q{
281
281
  These GPS tags are part of the EXIF standard, and are stored in a separate
@@ -88,7 +88,7 @@ sub ProcessCTMD($$$);
88
88
  sub ProcessExifInfo($$$);
89
89
  sub SwapWords($);
90
90
 
91
- $VERSION = '4.92';
91
+ $VERSION = '4.93';
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)
@@ -2628,6 +2628,10 @@ my %offOn = ( 0 => 'Off', 1 => 'On' );
2628
2628
  0x7fff => 'n/a',
2629
2629
  },
2630
2630
  },
2631
+ 52 => { #github336
2632
+ Name => 'HDR-PQ',
2633
+ PrintConv => { %offOn, -1 => 'n/a' },
2634
+ },
2631
2635
  );
2632
2636
 
2633
2637
  # focal length information (MakerNotes tag 0x02)
@@ -57,7 +57,7 @@ use vars qw($VERSION $AUTOLOAD @formatSize @formatName %formatNumber %intFormat
57
57
  use Image::ExifTool qw(:DataAccess :Utils);
58
58
  use Image::ExifTool::MakerNotes;
59
59
 
60
- $VERSION = '4.58';
60
+ $VERSION = '4.59';
61
61
 
62
62
  sub ProcessExif($$$);
63
63
  sub WriteExif($$$);
@@ -2029,7 +2029,7 @@ my %opcodeInfo = (
2029
2029
  OffsetPair => -1,
2030
2030
  },
2031
2031
  0x8782 => 'T88Options', #20
2032
- 0x87ac => 'ImageLayer',
2032
+ 0x87ac => 'ImageLayer', # Defined in the Mixed Raster Content part of RFC 2301
2033
2033
  0x87af => { #30
2034
2034
  Name => 'GeoTiffDirectory',
2035
2035
  Format => 'undef',
@@ -4209,6 +4209,8 @@ my %opcodeInfo = (
4209
4209
  },
4210
4210
  },
4211
4211
  # 0xc7d6 - int8u: 1 (SubIFD1 of Nikon Z6/Z7 NEF)
4212
+ 0xc7d7 => { Name => 'ZIFMetadata', Binary => 1 },
4213
+ 0xc7d8 => { Name => 'ZIFAnnotations', Binary => 1 },
4212
4214
  0xc7e9 => { # DNG 1.5
4213
4215
  Name => 'DepthFormat',
4214
4216
  Writable => 'int16u',
@@ -65,7 +65,7 @@ use Image::ExifTool::Exif;
65
65
  use Image::ExifTool::GPS;
66
66
  use Image::ExifTool::XMP;
67
67
 
68
- $VERSION = '4.47';
68
+ $VERSION = '4.48';
69
69
 
70
70
  sub LensIDConv($$$);
71
71
  sub ProcessNikonAVI($$$);
@@ -1691,14 +1691,15 @@ my %cropHiSpeed = ( #IB
1691
1691
  4 => '3:2 Crop', # (1.2x, ref 36)
1692
1692
  6 => '16:9 Crop',
1693
1693
  8 => '2.7x Crop', #36 (D4/D500)
1694
- 9 => 'DX Movie Crop', # (DX during movie recording, Large)
1694
+ 9 => 'DX Movie 16:9 Crop', # (DX during movie recording, Large)
1695
1695
  10 => '1.3x Movie Crop', #36 (D4/D500)
1696
1696
  11 => 'FX Uncropped',
1697
1697
  12 => 'DX Uncropped',
1698
1698
  13 => '2.8x Movie Crop', #28 (D5/D6) 5584/1936
1699
1699
  14 => '1.4x Movie Crop', #28 (D5/D6) 5584/3856
1700
1700
  15 => '1.5x Movie Crop', #36 (D4/D500) 5600/3872
1701
- 17 => '1:1 Crop',
1701
+ 17 => 'FX 1:1 Crop',
1702
+ 18 => 'DX 1:1 Crop',
1702
1703
  OTHER => sub {
1703
1704
  my ($val, $inv, $conv) = @_;
1704
1705
  return undef if $inv;
@@ -40,7 +40,7 @@ use Image::ExifTool qw(:DataAccess :Utils);
40
40
  use Image::ExifTool::Exif;
41
41
  use Image::ExifTool::APP12;
42
42
 
43
- $VERSION = '2.86';
43
+ $VERSION = '2.87';
44
44
 
45
45
  sub PrintLensInfo($$$);
46
46
 
@@ -447,6 +447,7 @@ my %olympusCameraTypes = (
447
447
  S0101 => 'OM-5', #IB
448
448
  S0121 => 'OM-1MarkII', #forum15652
449
449
  S0123 => 'OM-3', #forum17208
450
+ S0130 => 'OM-5MarkII', #forum17465
450
451
  SR45 => 'D220',
451
452
  SR55 => 'D320L',
452
453
  SR83 => 'D340L',
@@ -46,6 +46,7 @@
46
46
  # IB) Iliah Borg private communication (LibRaw)
47
47
  # JD) Jens Duttke private communication
48
48
  # NJ) Niels Kristian Bech Jensen private communication
49
+ # KG) Karsten Gieselmann private communication
49
50
  #
50
51
  # Notes: See POD documentation at the bottom of this file
51
52
  #------------------------------------------------------------------------------
@@ -58,11 +59,14 @@ use Image::ExifTool::Exif;
58
59
  use Image::ExifTool::GPS;
59
60
  use Image::ExifTool::HP;
60
61
 
61
- $VERSION = '3.52';
62
+ $VERSION = '3.53';
62
63
 
63
64
  sub CryptShutterCount($$);
64
65
  sub PrintFilter($$$);
65
66
  sub DecodeAFPoints($$$$;$);
67
+ sub AFPointNamesK3III($$;$);
68
+ sub AFPointValuesK3III($$);
69
+ sub AFAreasK3III($$);
66
70
 
67
71
  # pentax lens type codes (ref 4)
68
72
  # The first number gives the lens series, and the 2nd gives the model number
@@ -1148,31 +1152,38 @@ my %binaryDataAttrs = (
1148
1152
  Notes => 'Pentax models',
1149
1153
  Writable => 'int16u',
1150
1154
  PrintConvColumns => 2,
1155
+ PrintHex => 1,
1151
1156
  PrintConv => { #PH
1152
- 0 => 'Normal',
1153
- 1 => 'Macro',
1154
- 2 => 'Infinity',
1155
- 3 => 'Manual',
1156
- 4 => 'Super Macro', #JD
1157
- 5 => 'Pan Focus',
1158
- 6 => 'Auto-area', # (GR III)
1159
- 8 => 'Select', # (GR III)
1160
- 9 => 'Pinpoint', # (GR III)
1161
- 10 => 'Tracking', # (GR III)
1162
- 11 => 'Continuous', # (GR III)
1163
- 12 => 'Snap', # (GR III)
1164
- 16 => 'AF-S (Focus-priority)', #17
1165
- 17 => 'AF-C (Focus-priority)', #17
1166
- 18 => 'AF-A (Focus-priority)', #PH (educated guess)
1167
- 32 => 'Contrast-detect (Focus-priority)', #PH (K-5)
1168
- 33 => 'Tracking Contrast-detect (Focus-priority)', #PH (K-5)
1157
+ 0x00 => 'Normal',
1158
+ 0x01 => 'Macro',
1159
+ 0x02 => 'Infinity',
1160
+ 0x03 => 'Manual',
1161
+ 0x04 => 'Super Macro', #JD
1162
+ 0x05 => 'Pan Focus',
1163
+ 0x06 => 'Auto-area', # (GR III)
1164
+ 0x07 => 'Zone Select', # (GR III)
1165
+ 0x08 => 'Select', # (GR III)
1166
+ 0x09 => 'Pinpoint', # (GR III)
1167
+ 0x0a => 'Tracking', # (GR III)
1168
+ 0x0b => 'Continuous', # (GR III)
1169
+ 0x0c => 'Snap', # (GR III)
1170
+ 0x10 => 'AF-S (Focus-priority)', #17
1171
+ 0x11 => 'AF-C (Focus-priority)', #17
1172
+ 0x12 => 'AF-A (Focus-priority)', #PH (educated guess)
1173
+ 0x20 => 'Contrast-detect (Focus-priority)', #PH (K-5)
1174
+ 0x21 => 'Tracking Contrast-detect (Focus-priority)', #PH (K-5)
1169
1175
  # bit 8 indicates release priority
1170
- 272 => 'AF-S (Release-priority)', #PH (K-5,K-3)
1171
- 273 => 'AF-C (Release-priority)', #PH (K-5,K-3)
1172
- 274 => 'AF-A (Release-priority)', #PH (K-3)
1173
- 288 => 'Contrast-detect (Release-priority)', #PH (K-01)
1174
- # 32777 (0x8009) - seen for Ricoh GR III
1175
- # 32779 (0x800b) - seen for Ricoh GR III
1176
+ 0x110 => 'AF-S (Release-priority)', #PH (K-5,K-3)
1177
+ 0x111 => 'AF-C (Release-priority)', #PH (K-5,K-3)
1178
+ 0x112 => 'AF-A (Release-priority)', #PH (K-3)
1179
+ 0x120 => 'Contrast-detect (Release-priority)', #PH (K-01)
1180
+ # bit 15 indicates macro mode (disabled for MF, and defaults to Select for Snap, Infinity)
1181
+ 0x8006 => 'Auto-area (Macro)', # (GR III)
1182
+ 0x8007 => 'Zone Select (Macro)', # (GR III)
1183
+ 0x8008 => 'Select (Macro)', # (GR III)
1184
+ 0x8009 => 'Pinpoint (Macro)', # (GR III)
1185
+ 0x800a => 'Tracking (Macro)', # (GR III)
1186
+ 0x800b => 'Continuous (Macro)', # (GR III)
1176
1187
  },
1177
1188
  },{
1178
1189
  Name => 'FocusMode',
@@ -1188,7 +1199,7 @@ my %binaryDataAttrs = (
1188
1199
  ],
1189
1200
  0x000e => [{ #29
1190
1201
  Name => 'AFPointSelected',
1191
- Condition => '$$self{Model} =~ /K-1\b/',
1202
+ Condition => '$$self{Model} =~ /(K-1|645Z)\b/', # (NC for 645Z)
1192
1203
  Writable => 'int16u',
1193
1204
  Notes => 'K-1',
1194
1205
  PrintConvColumns => 2,
@@ -1367,16 +1378,20 @@ my %binaryDataAttrs = (
1367
1378
  9 => 'Lower-left',
1368
1379
  10 => 'Bottom',
1369
1380
  11 => 'Lower-right',
1370
- },
1381
+ },{
1371
1382
  # (second number exists for K-5II(s) is usually 0, but is 1 for AF.C with
1372
1383
  # AFPointMode=='Select' and extended tracking focus points are enabled in the settings)
1373
- ],
1384
+ # -----
1385
+ #KG: for K-70 and older models with 11 PDAF points (K-S2, K-S1, K-50, K-500, K-30, K-5II(s) )
1386
+ 0 => 'Single Point', # Select AF (1-point) in both PDAF and CAF modes
1387
+ 1 => 'Expanded Area', # Expanded Area AF in AF-C
1388
+ }],
1374
1389
  }],
1375
1390
  0x000f => [{ #PH
1376
1391
  Name => 'AFPointsInFocus',
1377
- Condition => '$$self{Model} =~ /K-3\b/',
1392
+ Condition => '$$self{Model} =~ /K-(3|S1|S2)\b/', #KG: valid also for K-S1/S2
1378
1393
  Writable => 'int32u',
1379
- Notes => 'K-3 only',
1394
+ Notes => 'K-3, K-S1 and K-S2 only',
1380
1395
  PrintHex => 1,
1381
1396
  PrintConv => {
1382
1397
  0 => '(none)',
@@ -2169,7 +2184,7 @@ my %binaryDataAttrs = (
2169
2184
  11 => 'Flat', #31 (K-70)
2170
2185
  # the following values from GR III
2171
2186
  256 => 'Standard',
2172
- 257 => 'Vivid',
2187
+ 257 => 'Vivid',
2173
2188
  258 => 'Monotone',
2174
2189
  259 => 'Soft Monotone',
2175
2190
  260 => 'Hard Monotone',
@@ -3097,13 +3112,15 @@ my %binaryDataAttrs = (
3097
3112
  # 0x0406 - undef[4116] (K-5)
3098
3113
  # 0x0407 - undef[3072] (Q DNG)
3099
3114
  # 0x0408 - undef[1024] (Q DNG)
3115
+ 0x040c => {
3116
+ Name => 'AFInfoK3III',
3117
+ SubDirectory => { TagTable => 'Image::ExifTool::Pentax::AFInfoK3III' },
3118
+ },
3100
3119
  0x0e00 => {
3101
3120
  Name => 'PrintIM',
3102
3121
  Description => 'Print Image Matching',
3103
3122
  Writable => 0,
3104
- SubDirectory => {
3105
- TagTable => 'Image::ExifTool::PrintIM::Main',
3106
- },
3123
+ SubDirectory => { TagTable => 'Image::ExifTool::PrintIM::Main' },
3107
3124
  },
3108
3125
  );
3109
3126
 
@@ -5006,11 +5023,11 @@ my %binaryDataAttrs = (
5006
5023
  # 0x0a - values: 00,05,0d,15,86,8e,a6,ae
5007
5024
  0x0b => { #JD
5008
5025
  Name => 'AFPointsInFocus',
5009
- Condition => '$$self{Model} !~ /(K-(1|3|70)|KP)\b/',
5026
+ Condition => '$$self{Model} !~ /(K-(1|3|70|S1|S2)|KP)\b/', #KG: valid also for K-S1/S2
5010
5027
  Notes => q{
5011
- models other than the K-1, K-3, K-70 and KP. May report two points in focus
5012
- even though a single AFPoint has been selected, in which case the selected
5013
- AFPoint is the first reported
5028
+ models other than the K-1, K-3, K-70, KP and K-S1/S2. May report two points
5029
+ in focus even though a single AFPoint has been selected, in which case the
5030
+ selected AFPoint is the first reported
5014
5031
  },
5015
5032
  PrintConvColumns => 2,
5016
5033
  PrintConv => {
@@ -5043,34 +5060,34 @@ my %binaryDataAttrs = (
5043
5060
  Format => 'int16uRev[69]',
5044
5061
  Unknown => 1,
5045
5062
  Notes => 'some unknown values related to each AFPoint',
5046
- # order is the same as AFPoints below, but there is an additional value for
5063
+ # order is the same as AFPointsSelected below, but there is an additional value for
5047
5064
  # each AF point starting at offset 28 in the array (yes, the range overlaps
5048
5065
  # with the 1st values)
5049
5066
  # (values are int16s stored in reversed byte order)
5050
5067
  ValueConv => 'my @a=split " ",$val;$_>32767 and $_-=65536 foreach @a;join " ",@a',
5051
- PrintConv => \&AFPointValues,
5068
+ PrintConv => \&AFPointValuesK3III,
5052
5069
  },
5053
5070
  0x12a => { # byte has a value of 2 if corresponding AF point is selected
5054
- Name => 'AFPointsSelected',
5071
+ Name => 'AFPointsSelected', # (should probably be "AFPointSelected", but the bitmask allows multiple points)
5055
5072
  Condition => '$$self{Model} eq "PENTAX K-3 Mark III"', # any other models?
5056
5073
  Notes => q{
5057
5074
  K-3III only. 41 selectable AF points from a total of 101 available in a 13x9
5058
5075
  grid. Columns are labelled A-M and rows are 1-9. The center point is G5
5059
5076
  },
5060
5077
  Format => 'int8u[41]',
5061
- PrintConv => 'Image::ExifTool::Pentax::AFPointsK3iii($val,$self,2)',
5078
+ PrintConv => 'Image::ExifTool::Pentax::AFPointNamesK3III($val,$self,2)',
5062
5079
  },
5063
5080
  #
5064
5081
  # (maybe not coincidentally, there are 60 unknown bytes
5065
5082
  # here, and there are also 60 non-selectable AF points)
5066
5083
  #
5067
5084
  0x18f => { # byte has a value of 1 if corresponding AF point is ... in focus maybe?
5068
- # usually the same points as AFPoints above, but not always
5085
+ # usually the same points as AFPointsSelected above, but not always
5069
5086
  Name => 'AFPointsUnknown',
5070
5087
  Condition => '$$self{Model} eq "PENTAX K-3 Mark III"', # any other models?
5071
5088
  Unknown => 1,
5072
5089
  Format => 'int8u[41]',
5073
- PrintConv => \&AFPointsK3iii,
5090
+ PrintConv => \&AFPointNamesK3III,
5074
5091
  },
5075
5092
  0x1fa => {
5076
5093
  Name => 'LiveView',
@@ -5097,7 +5114,7 @@ my %binaryDataAttrs = (
5097
5114
  Name => 'NumCAFPoints',
5098
5115
  RawConv => '$$self{NumCAFPoints} = ($val & 0x0f) * ($val >> 4); $val',
5099
5116
  ValueConv => '($val >> 4) * ($val & 0x0f)',
5100
- },
5117
+ },
5101
5118
  1.1 => {
5102
5119
  Name => 'CAFGridSize',
5103
5120
  ValueConv => '($val >> 4) . " " . ($val & 0x0f)', # (width x height)
@@ -5687,6 +5704,95 @@ my %binaryDataAttrs = (
5687
5704
  ValueConvInv => '-$val * 2',
5688
5705
  },
5689
5706
  );
5707
+
5708
+ %Image::ExifTool::Pentax::AFInfoK3III = (
5709
+ %binaryDataAttrs,
5710
+ GROUPS => { 0 => 'MakerNotes', 2 => 'Camera' },
5711
+ FORMAT => 'int16u',
5712
+ DATAMEMBER => [ 3 ],
5713
+ NOTES => 'AF tags written by the K-3 Mark III, GR III and GR IIIx.',
5714
+ 0 => {
5715
+ Name => 'AFInfo',
5716
+ Format => 'int16u[$size/2]',
5717
+ Notes => q{
5718
+ entire AFInfoK3III structure. Provides access to raw numerical values and
5719
+ facilitates the writing of the whole structure
5720
+ },
5721
+ Unknown => 1,
5722
+ },
5723
+ 0.1 => {
5724
+ Name => 'AFMode',
5725
+ PrintConv => {
5726
+ 0 => 'Phase Detect',
5727
+ 2 => 'Contrast Detect',
5728
+ 255 => 'Manual Focus',
5729
+ },
5730
+ },
5731
+ 1 => {
5732
+ Name => 'AFSelectionMode',
5733
+ PrintHex => 1,
5734
+ PrintConv => {
5735
+ 0 => 'Manual Focus',
5736
+ 1 => 'Spot',
5737
+ 2 => 'Select (5-points)',
5738
+ 3 => 'Expanded Area (S)',
5739
+ 4 => 'Expanded Area (M)',
5740
+ 5 => 'Expanded Area (L)',
5741
+ 6 => 'Select (S)',
5742
+ 7 => 'Zone Select (21-point)',
5743
+ 8 => 'Select XS',
5744
+ 0xff => 'Auto Area',
5745
+ # Contrast-detect modes
5746
+ 0x2001 => 'Contrast-detect Auto Area',
5747
+ 0x2002 => 'Contrast-detect Select', # (GR III)
5748
+ 0x2003 => 'Pinpoint', # (GR III)
5749
+ 0x2004 => 'Tracking',
5750
+ 0x2005 => 'Continuous', # (GR III)
5751
+ 0x2006 => 'Face Detection',
5752
+ 0x2007 => 'Contrast-detect Select (S)',
5753
+ 0x2008 => 'Contrast-detect Select (M)',
5754
+ 0x2009 => 'Contrast-detect Select (L)',
5755
+ 0x200a => 'Contrast-detect Zone Select', # (GR III)
5756
+ 0x200b => 'Contrast-detect Spot',
5757
+ },
5758
+ },
5759
+ 3 => {
5760
+ Name => 'NumAFPoints',
5761
+ RawConv => '$$self{NumAFPoints} = $val',
5762
+ },
5763
+ # the data for each AF point consists of 7 int16u values:
5764
+ # the frame width/height, the X/Y position of the focus area,
5765
+ # width/height of the focus area (0/0 for phase-detect modes),
5766
+ # followed by a flags word
5767
+ 7 => { # (the same for all areas in my samples, so only extract the first)
5768
+ Name => 'AFFrameSize',
5769
+ Condition => '$$self{NumAFPoints} > 0',
5770
+ Format => 'int16u[2]',
5771
+ Writable => 0,
5772
+ PrintConv => '$val=~s/ /x/; $val',
5773
+ },
5774
+ 7.1 => {
5775
+ Name => 'AFAreas',
5776
+ Format => 'int16u[7 * $val{3}]',
5777
+ Notes => q{
5778
+ X,Y position of each AF area, width, with "in-focus" for points in focus,
5779
+ "central" for the center of the selected area, or "peripheral" for points
5780
+ outside the selected area
5781
+ },
5782
+ Writable => 0,
5783
+ List => 1, # (for documentation purposes only)
5784
+ PrintConv => \&AFAreasK3III,
5785
+ },
5786
+ 11 => { # (the same for all areas in my samples, so only extract the first)
5787
+ Name => 'AFAreaSize',
5788
+ Condition => '$$self{NumAFPoints} > 0 and $$valPt !~ /^\0\0\0\0/',
5789
+ Notes => 'only for contrast-detect modes',
5790
+ Format => 'int16u[2]',
5791
+ Writable => 0,
5792
+ PrintConv => '$val=~s/ /x/; $val',
5793
+ },
5794
+ );
5795
+
5690
5796
  # white balance RGGB levels (ref 28)
5691
5797
  %Image::ExifTool::Pentax::WBLevels = (
5692
5798
  %binaryDataAttrs,
@@ -5750,7 +5856,7 @@ my %binaryDataAttrs = (
5750
5856
  },
5751
5857
  );
5752
5858
 
5753
- # lens information for Penax Q (ref PH)
5859
+ # lens information for Pentax Q (ref PH)
5754
5860
  # (306 bytes long, I wonder if this contains vignetting information too?)
5755
5861
  %Image::ExifTool::Pentax::LensInfoQ = (
5756
5862
  %binaryDataAttrs,
@@ -6461,9 +6567,9 @@ sub DecodeAFPoints($$$$;$)
6461
6567
  }
6462
6568
 
6463
6569
  #------------------------------------------------------------------------------
6464
- # Print AF Point names for K-3III (ref PH)
6570
+ # Print K-3III AF Point names (ref PH)
6465
6571
  # Inputs: 0) value, 1) ExifTool ref, 2) optional value to match
6466
- sub AFPointsK3iii($$;$)
6572
+ sub AFPointNamesK3III($$;$)
6467
6573
  {
6468
6574
  my @a = split ' ', $_[0];
6469
6575
  my $match = $_[2];
@@ -6477,10 +6583,10 @@ sub AFPointsK3iii($$;$)
6477
6583
  }
6478
6584
 
6479
6585
  #------------------------------------------------------------------------------
6480
- # Print AF point values for K-3III (ref PH)
6586
+ # Print K-3III AF point values (ref PH)
6481
6587
  # Inputs: 0) value, 1) ExifTool ref
6482
6588
  # Notes: this is experimental and not well understood
6483
- sub AFPointValues($$)
6589
+ sub AFPointValuesK3III($$)
6484
6590
  {
6485
6591
  my @a = split ' ', shift;
6486
6592
  my @vals;
@@ -6499,6 +6605,25 @@ sub AFPointValues($$)
6499
6605
  return @vals ? join ',', sort @vals : '(none)';
6500
6606
  }
6501
6607
 
6608
+ #------------------------------------------------------------------------------
6609
+ # Print K-3III AF point positions from tag 0x040c (ref KG)
6610
+ # Inputs: 0) raw value, 1) ExifTool ref
6611
+ sub AFAreasK3III($$)
6612
+ {
6613
+ my ($val, $et) = @_;
6614
+ return '(none)' unless $val;
6615
+ my @vals = split ' ', $val;
6616
+ # flags bits: [mask, value, description]
6617
+ my @flags = ([0x10,0x10,'central'],[0x08,0,'peripheral'],[0x04,0x04,'in-focus']);
6618
+ my ($i, @strs);
6619
+ for ($i=0; $i+7<=@vals; $i+=7) {
6620
+ my @a;
6621
+ ($vals[$i+6] & $$_[0]) == $$_[1] and push @a, $$_[2] foreach @flags;
6622
+ push @strs, $vals[$i+2] . ',' . $vals[$i+3] . (@a ? '(' . join(',',@a) . ')' : '');
6623
+ }
6624
+ return \@strs;
6625
+ }
6626
+
6502
6627
  #------------------------------------------------------------------------------
6503
6628
  # Convert Pentax hex-based EV (modulo 8) to real number
6504
6629
  # Inputs: 0) value to convert
@@ -34,7 +34,7 @@ use Image::ExifTool qw(:DataAccess :Utils);
34
34
  use Image::ExifTool::Exif;
35
35
  use Image::ExifTool::Minolta;
36
36
 
37
- $VERSION = '3.73';
37
+ $VERSION = '3.74';
38
38
 
39
39
  sub ProcessSRF($$$);
40
40
  sub ProcessSR2($$$);
@@ -176,6 +176,7 @@ sub PrintInvLensSpec($;$$);
176
176
  32888 => 'Sony FE 85mm F1.4 GM II', #JR
177
177
  32889 => 'Sony FE 28-70mm F2 GM',
178
178
  32890 => 'Sony FE 400-800mm F6.3-8 G OSS', #JR
179
+ 32891 => 'Sony FE 50-150mm F2 GM', #github335
179
180
 
180
181
  # (comment this out so LensID will report the LensModel, which is more useful)
181
182
  # 32952 => 'Metabones Canon EF Speed Booster Ultra', #JR (corresponds to 184, but 'Advanced' mode, LensMount reported as E-mount)