ExifTool Forum

ExifTool => The "exiftool" Application => Topic started by: trymeout on May 19, 2021, 08:59:59 PM

Title: User Data xyz & GPS/LocationInformation Metadata
Post by: trymeout on May 19, 2021, 08:59:59 PM
it will appear there are two ways to embed the latitude, longitude and altitude in a MP4 video file.

One way is to embed "User Data xyz" and another is by doing GPS/LocationInformation.

For whatever reason using version 12.25, the following command will write the latitude and longitude to the "User Data xyz" but when using version 11.88 it will write to the GPS/LocationInformation. I am using 12.25 on Windows and 11.88 on Linux Mint. Is there a way to choose weather to write to "User Data xyz" or GPS/LocationInformation with the latest version of exiftool and with exiftools going forward?

exiftool -overwrite_original -gpscoordinates="45.1234, -100.1234, 55" "file.mp4"
Title: Re: User Data xyz & GPS/LocationInformation Metadata
Post by: Phil Harvey on May 20, 2021, 06:14:23 AM
ExifTool will never write a tag called "LocationInformation" if you tell it to write "GPSCoordinates".

But GPSCoordinates may exist in either the UserData or the Keys locations.  You can specify where you want it like this:

exiftool -userdata:gpscoordinates="45.1234, -100.1234, 55" FILE

- Phil
Title: Re: User Data xyz & GPS/LocationInformation Metadata
Post by: StarGeek on May 20, 2021, 11:41:58 AM
Quote from: trymeout on May 19, 2021, 08:59:59 PM
For whatever reason using version 12.25, the following command will write the latitude and longitude to the "User Data xyz" but when using version 11.88 it will write to the GPS/LocationInformation.

Version 11.88 cannot write to the LocationInformation because, as I've already said (https://exiftool.org/forum/index.php?topic=12442.msg67312#msg67312), the ability to write that tag was only recently added with version 12.25.

The GPSCoordinates can appear in the Quicktime ItemList, UserData, and Keys locations.  See the second paragraph on the Quicktime tag page (https://exiftool.org/TagNames/QuickTime.html) for the priority in which exiftool will write the information when you don't give an exact group.
Title: Re: User Data xyz & GPS/LocationInformation Metadata
Post by: trymeout on May 20, 2021, 02:11:59 PM
What is the UserData metadata anyways besides it being able to hold GPS data?

And is UserData for storing GPS popular method for video files which many software will support reading?
Title: Re: User Data xyz & GPS/LocationInformation Metadata
Post by: StarGeek on May 20, 2021, 03:29:03 PM
Userdata, ItemList, and Keys are all sub-groups of the Quicktime tags (see link above).  Similar to how EXIF has IFD0/ExifIFD sub-groups and XMP has XMP-mwg-rs/XMP-dc sub-groups.

As for which is best to use for GPS?  It all depends upon the program reading the data.  Video metadata is a complete mess and all you can do is test each program to see what works.
Title: Re: User Data xyz & GPS/LocationInformation Metadata
Post by: trymeout on May 21, 2021, 12:03:28 PM
To my understanding UserData has been around for years though correct compared to LocationInformation?
Title: Re: User Data xyz & GPS/LocationInformation Metadata
Post by: StarGeek on May 21, 2021, 05:18:38 PM
They've both been around for a long time.  Exiftool has only recently gained the ability to write LocationInformation.