exiftool compared to gdalinfo output

Started by Tom OReilly, August 06, 2020, 06:18:10 PM

Previous topic - Next topic

Tom OReilly

I'd like to better understand the relation between metadata displayed by exiftool versus gdalinfo. I have a geotiff (not created by me). The gdalinfo tool output includes this information:

Corner Coordinates:
Upper Left  (-12249462.600, 4629559.795) (110d 2'19.66"W, 38d21'14.51"N)
Lower Left  (-12249462.600, 4592360.683) (110d 2'19.66"W, 38d 5'29.42"N)
Upper Right (-12212267.400, 4629559.795) (109d42'16.79"W, 38d21'14.51"N)
Lower Right (-12212267.400, 4592360.683) (109d42'16.79"W, 38d 5'29.42"N)
Center      (-12230865.000, 4610960.239) (109d52'18.23"W, 38d13'22.39"N)


exiftool displays just the upper left corner coordinate:
ModelTiePoint                   : 0 0 0 -12249462.6 4629559.79486095 0


Why does exiftool show just one of the ground control points for the image while gdalinfo shows five?
I assume that gdalinfo is somehow deriving the additional points from other metadata in the file - is that right? Does exiftool display *all* of the metadata utilized by gdalinfo?

Here is the 'exiftool -s' output:

ExifToolVersion                 : 10.80
FileName                        : CANYrelief1-geo.tif
Directory                       : .
FileSize                        : 6.5 MB
FileModifyDate                  : 2020:08:06 13:47:19-07:00
FileAccessDate                  : 2020:08:06 13:47:32-07:00
FileInodeChangeDate             : 2020:08:06 13:47:19-07:00
FilePermissions                 : rw-r--r--
FileType                        : TIFF
FileTypeExtension               : tif
MIMEType                        : image/tiff
ExifByteOrder                   : Big-endian (Motorola, MM)
SubfileType                     : Full-resolution Image
ImageWidth                      : 2800
ImageHeight                     : 2800
BitsPerSample                   : 8 8 8
Compression                     : LZW
PhotometricInterpretation       : RGB
StripOffsets                    : (Binary data 710 bytes, use -b option to extract)
Orientation                     : Horizontal (normal)
SamplesPerPixel                 : 3
RowsPerStrip                    : 31
StripByteCounts                 : (Binary data 545 bytes, use -b option to extract)
XResolution                     : 72
YResolution                     : 72
PlanarConfiguration             : Chunky
ResolutionUnit                  : inches
Software                        : Adobe Photoshop CC (Macintosh)
ModifyDate                      : 2017:04:01 20:24:57
Predictor                       : Horizontal differencing
XMPToolkit                      : Adobe XMP Core 5.5-c021 79.154911, 2013/10/29-11:47:16
CreateDate                      : 2014:12:08 14:45:47-05:00
MetadataDate                    : 2017:04:01 20:24:57-07:00
CreatorTool                     : Adobe Photoshop CC 2014 (Macintosh)
Format                          : image/tiff
ColorMode                       : RGB
InstanceID                      : xmp.iid:df0f9cc6-5f7d-4562-b1b4-740fcd041d2b
DocumentID                      : xmp.did:c8b37324-f370-4079-9fdd-66b42f168471
OriginalDocumentID              : xmp.did:1e043f18-449d-43a8-91c1-3d32f8ad718a
HistoryAction                   : created, converted, saved, saved, converted, derived, saved, saved
HistoryInstanceID               : xmp.iid:1e043f18-449d-43a8-91c1-3d32f8ad718a, xmp.iid:a2b74c79-3c8f-4e39-b789-00d03026a96c, xmp.iid:6fcf95dc-953f-4670-bd98-44da1a8c224c, xmp.iid:c8b37324-f370-4079-9fdd-66b42f168471, xmp.iid:df0f9cc6-5f7d-4562-b1b4-740fcd041d2b
HistoryWhen                     : 2014:12:08 14:45:47-05:00, 2014:12:08 14:54:05-05:00, 2017:04:01 20:23:39-07:00, 2017:04:01 20:23:39-07:00, 2017:04:01 20:24:57-07:00
HistorySoftwareAgent            : Adobe Photoshop CC 2014 (Macintosh), Adobe Photoshop CC 2014 (Macintosh), Adobe Photoshop CC (Macintosh), Adobe Photoshop CC (Macintosh), Adobe Photoshop CC (Macintosh)
HistoryParameters               : from image/tiff to application/vnd.adobe.photoshop, from application/vnd.adobe.photoshop to image/tiff, converted from application/vnd.adobe.photoshop to image/tiff
HistoryChanged                  : /, /, /, /
DerivedFromInstanceID           : xmp.iid:6fcf95dc-953f-4670-bd98-44da1a8c224c
DerivedFromDocumentID           : adobe:docid:photoshop:e2ca2aa4-566a-1178-a43c-817eebace311
DerivedFromOriginalDocumentID   : xmp.did:1e043f18-449d-43a8-91c1-3d32f8ad718a
PixelScale                      : 13.284 13.285397060379 0
ModelTiePoint                   : 0 0 0 -12249462.6 4629559.79486095 0
IPTCDigest                      : c75d17e574b56ef5dbbe3994c0e9795c
DisplayedUnitsX                 : inches
DisplayedUnitsY                 : inches
PrintStyle                      : Centered
PrintPosition                   : 0 0
PrintScale                      : 1
GlobalAngle                     : 30
GlobalAltitude                  : 30
URL_List                        :
SlicesGroupName                 :
NumSlices                       : 1
PixelAspectRatio                : 1
PhotoshopThumbnail              : (Binary data 5505 bytes, use -b option to extract)
HasRealMergedData               : Yes
WriterName                      : Adobe Photoshop
ReaderName                      : Adobe Photoshop CC
ColorSpace                      : Uncalibrated
ExifImageWidth                  : 2800
ExifImageHeight                 : 2800
GeoTiffVersion                  : 1.1.0
GTModelType                     : Projected
GTRasterType                    : Pixel Is Area
GTCitation                      : WGS 84 / Pseudo-Mercator
GeogCitation                    : WGS 84
GeogAngularUnits                : Angular Degree
ProjectedCSType                 : Unknown (3857)
ProjLinearUnits                 : Linear Meter
ImageSize                       : 2800x2800
Megapixels                      : 7.8

Thanks!

Phil Harvey

Hi Tom,

Quote from: Tom OReilly on August 06, 2020, 06:18:10 PM
I assume that gdalinfo is somehow deriving the additional points from other metadata in the file - is that right?

A reasonable assumption.

QuoteDoes exiftool display *all* of the metadata utilized by gdalinfo?

I don't know about what gdalinfo uses, but ExifTool should be extracting all of the metadata in the file (but you can add -u just in case to see any unknown EXIF information that may exist).

- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).