ExifTool Forum

ExifTool => Bug Reports / Feature Requests => Topic started by: Marsu42 on April 20, 2024, 05:28:36 AM

Title: Feature Request: geolocated distance (and/or gps coordinates of geolocated location)
Post by: Marsu42 on April 20, 2024, 05:28:36 AM
I'm hoping you won't reget touching geolocation because it's another can of worms like video metatdata :-), but I'll risk it:

[...]

=> Could you implement a feature that adds the distance to wherever the geolocation is, and/or make the gps coordinates of the geolocated location available somehow?


Title: Re: Feature Request: geolocated distance (and/or gps coordinates of geolocated location)
Post by: Phil Harvey on April 20, 2024, 07:07:13 AM
I'm not sure I understand your lengthy description, but I think that ExifTool may already do what you want.  For example, the distance/direction from a GPS point to a known feature is given in the last 2 tags returned:

> exiftool -api geolocation="3.12345,-42.43536,New York City"
Geolocation City                : New York City
Geolocation Region              : New York
Geolocation Country Code        : US
Geolocation Country             : United States
Geolocation Time Zone           : America/New_York
Geolocation Feature Code        : PPL
Geolocation Population          : 8800000
Geolocation Position            : 40.7143, -74.0060
Geolocation Distance            : 5240.33 km
Geolocation Bearing             : 326

- Phil
Title: Re: Feature Request: geolocated distance (and/or gps coordinates of geolocated location)
Post by: Marsu42 on April 20, 2024, 08:14:17 AM
Quote from: Phil Harvey on April 20, 2024, 07:07:13 AMI'm not sure I understand your lengthy description, but I think that ExifTool may already do what you want.  For example, the distance/direction from a GPS point to a known feature is given in the last 2 tags returned:

I'm sorry for the length, I just wanted to legitimize my feature request.

Thanks for your command line that outputs the distance - I didn't see exiftool -api geolocation "-geolocation*" https://exiftool.org/geolocation.html ... will to to do better next time.
Title: Re: Feature Request: geolocated distance (and/or gps coordinates of geolocated location)
Post by: Phil Harvey on April 20, 2024, 08:29:05 AM
Great.  The Geolocation feature was indeed a lot of work, but rewarding because this is a fun feature that I will use myself.

- Phil

Edit: Also, browsing the documentation I don't think I have explained this feature very well.  I've got some more work to do there...

Edit2: I've added an example to demonstrate this feature on the Geolocation page (https://exiftool.org/geolocation.html#DefInput).
Title: Re: Feature Request: geolocated distance (and/or gps coordinates of geolocated location)
Post by: Phil Harvey on April 21, 2024, 09:33:34 PM
Version 12.84 will have a cool new ability that will allow you to find the nearest N features from a given GPS point (not just the closest).  For example, this command finds the nearest 4 features:

exiftool -a -api geolocation=49.48,6.37,num=4

I can imagine this feature being used in a GUI to present the user with a set of choices for the location name they prefer.

- Phil
Title: Re: Feature Request: geolocated distance (and/or gps coordinates of geolocated location)
Post by: Marsu42 on April 21, 2024, 10:36:58 PM
Quote from: Phil Harvey on April 21, 2024, 09:33:34 PMVersion 12.84 will have a cool new ability

Great, and it'is really appreciated.

It didn't take me too long to write a windows shell script that really enhances my Lightroom experience:

1. add the distance and the direction (like in N, NNW, NW, ...) to a City tag,
2. add a tag that contains the distance and direction to my home town from the shooting location.

This is only possible because of your work and the flexibility of exiftool,