Agisoft Metashape

Agisoft Metashape => Python and Java API => Topic started by: geo_enth3 on April 21, 2022, 01:50:42 PM

Title: Reading camera GPS information from EXIF in Python
Post by: geo_enth3 on April 21, 2022, 01:50:42 PM
Hi,

I was wondering if there is a way to read the stored GPS coordinates from the EXIF data. My camera is equipped with a GNSS module and stores approximate camera in the EXIF data. I know it is possible to read EXIF data via this command:

Code: [Select]
camera.photo.meta["Exif/GPSLongitude"]
However, this only retuns a string of the rounded coordinates (e.g. '16,22.116E') while I need full precision (and preferably as float or double, but this is less important).

Thanks,

geo_enth
Title: Re: Reading camera GPS information from EXIF in Python
Post by: geo_enth3 on April 21, 2022, 02:02:07 PM
I solved this already myself. its as simple as this:

Code: [Select]
camera.reference.location