ExifTool Forum

ExifTool => Newbies => Topic started by: Jossie on September 17, 2014, 01:53:46 PM

Title: How to delete all GPS information
Post by: Jossie on September 17, 2014, 01:53:46 PM
Good evening,

GeoSetter has written the wrong GPS data to some of my files. What is the cleanest and easiest way to delete ALL GPS-related information for an image? I have searched the forum but could not find an answer.

Many thanks in advance and best wishes

Hermann-Josef
Title: Re: How to delete all GPS information
Post by: Phil Harvey on September 17, 2014, 01:56:57 PM
Hi Hermann-Josef,

To delete all EXIF GPS, do this:

exiftool -gps:all= FILE

If it may also be stored in XMP, it is a bit trickier, but this command should handle both cases:

exiftool "-gps*=" FILE

where FILE is one or more file and/or directory names.

The first command does a block delete of the EXIF GPS directory (quick and clean).  The second command individually deletes all writable tags with names beginning with "gps" (slow and messy).

- Phil
Title: Re: How to delete all GPS information
Post by: StarGeek on September 17, 2014, 02:39:33 PM
They mention Geosetter and Geosetter does set the XMP-exif geo tags, so the second command will have to be used.
Title: Re: How to delete all GPS information
Post by: Jossie on September 18, 2014, 01:54:44 PM
Good evening,

thanks for both replies!

Yes, the second one has to be used. I first tried to remove the GPS information in EXIFtool GUI, but that was not the full story. With the second version Phil mentioned all gps-information is gone.

Best wishes

Hermann-Josef
Title: Re: How to delete all GPS information
Post by: jcnt on August 06, 2017, 10:38:46 AM
Quote from: Phil Harvey on September 17, 2014, 01:56:57 PM
Hi Hermann-Josef,

To delete all EXIF GPS, do this:

exiftool -gps:all= FILE

If it may also be stored in XMP, it is a bit trickier, but this command should handle both cases:

exiftool "-gps*=" FILE

where FILE is one or more file and/or directory names.


I am trying to delete GPS from a .mov file but nothing happens:

$ exiftool -gpsaltitude IMG_1234.MOV
GPS Altitude                    : 93.729 m

$ exiftool "-gps*="  IMG_1234.MOV
    0 image files updated
    1 image files unchanged

$ exiftool -gpsaltitude= IMG_1234.MOV
    0 image files updated
    1 image files unchanged

$ exiftool -gps:all= IMG_1234.MOV
    0 image files updated
    1 image files unchanged


Does anyone know what I am missing here?
Title: Re: How to delete all GPS information
Post by: Phil Harvey on August 06, 2017, 03:25:38 PM
ExifTool has only limited write ability in MOV videos, and currently can't write/delete these tags.

- Phil
Title: Re: How to delete all GPS information
Post by: StarGeek on August 06, 2017, 04:50:08 PM
You might try FFMpeg.  Here's a StackExchange (https://unix.stackexchange.com/questions/339119/how-to-strip-gps-location-data-from-an-mp4-video-file) question about removing GPS data from an MP4.  It should be the same procedure for a MOV file, though you should test it first.
Title: Re: How to delete all GPS information
Post by: jcnt on August 06, 2017, 09:55:21 PM
Quote from: Phil Harvey on August 06, 2017, 03:25:38 PM
ExifTool has only limited write ability in MOV videos, and currently can't write/delete these tags.
$ exiftool --help | grep MOV
      CRW   r/w   | HDP   r/w   | MOV   r/w   | PMP   r     | VSD   r

man page lists MOV as r/w with no restrictions.
Title: Re: How to delete all GPS information
Post by: StarGeek on August 06, 2017, 11:23:55 PM
But if you view the whole thing, there are restrictions on the types of metadata below that.

If the tag was XMP:GPSAltitude, exiftool would be able to edit it.  But odds are the tag you're looking at is Composite:GPSAltitude.  Add -G1 -a to your command to check.  That tag, in the case of a MOV file, is probably derived from either QuickTime:LocationInformation or QuickTime:GPSCoordinates (see Composite tags (https://exiftool.org/TagNames/Composite.html)).  And if you check under Quicktime tags (https://exiftool.org/TagNames/QuickTime.html), you'll see that both of those tags are not writable by Exiftool.