Missing GPS data tags

Started by macuser, September 13, 2021, 11:54:55 AM

Previous topic - Next topic

macuser

Hello,

I'm trying to add GPS data to some my MP4 files and am running into the following error:
./exiftool -GPSLatitude=40.25090199998273  -GPSLongitude=75.13265800002499 -GPSLatituderef=N -GPSLongituderef=W test.mp4

Error: No data reference for sample description 0 for Track2 - test.mp4
    0 image files updated
    1 files weren't updated due to errors


Upon closer inspection i noticed that "test.mp4" does not have any GPS tags yet (even empty ones):
./exiftool -a  "-gps*" test.mp4 gives no output

Is there a way to alter the above command such that the tags are created with the associated values? Any assistance would be much appreciated!

StarGeek

The first problem is the error.  The file isn't going to get updated due to that.  This error has popped up previously here and here.  In the latter case, it was due to Google Pixel 4a formatting the file incorrectly.  I don't know if a work around was made or not.  Make sure you're using a current version of exiftool but this may not be fixable by exiftool.

The second problem is with the tags you are trying to set.  A video file can have XMP or Quicktime GPS tags.  In the case of XMP, there is only the base tags, there is no reference tags.  The reference direction in included.  So you would set the tags like this
exiftool -GPSLatitude=40.25090199998273  -GPSLongitude=-75.13265800002499 test.mp4
But the thing about the XMP GPS tags in a video file is that Adobe programs are about the only program that will read those those tags.

The Quicktime tag is GPSCoordinates and that is a single tag that contains Latitude, Longitude, and Altitude.  This is the tag most likely to be read by apps.  You would set it like this
exiftool -GPSCoordinates="40.25090199998273, -75.13265800002499" test.mp4
* Did you read FAQ #3 and use the command listed there?
* Please use the Code button for exiftool code/output.
 
* Please include your OS, Exiftool version, and type of file you're processing (MP4, JPG, etc).