Obtaining the coordenates from a .CR2 Raw file

Started by evilaro, October 22, 2012, 11:26:50 AM

Previous topic - Next topic

evilaro

Hi:

I got a program that Geotags my .CR2 RAWs
but it puts the coordinates on the .XMP
If I look at the exif it shows no coordinates at all

If the files are .JPG it puts them directelly in the JPG file

and with something like this I got the coordinates.
exiftool.exe -GPSposition "&DIR" > resultado2.CSV 

So in this format Exiftools also gets the coordenates of the .XMP

Is there a way to get the coordenates for the .CR2 but from its corresponding .xmp ?

Thanks

Emilio

www.evilfoto.eu
*************

Phil Harvey

The answer is "yes", but I'm not clear about the question.

To read information from XMP files, specify the directory and add -ext xmp to the exiftool command.

- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).

evilaro

Phil:

"The answer is "yes", but I'm not clear about the question."
I am really glad I will have the solution ;)


Okay:

This is what I obtain from a folder where there are 4 .CR2 and it corresponding .xmp
It does not indicate that the .CR2 has a coordinate.

Since the data of the .xmp corresponds to the .CR2, I just wondered if
there was a way that directelly pases this coordinates to the .CR2 file.
   

Well, if not I will program a bit more to do it.

Thanks

Emilio

======== E:/IM/RAW_XMP/EVIL0370.CR2
AF Area Mode                    : Single-point AF
======== E:/IM/RAW_XMP/EVIL0370.xmp
GPS Position                    : 39 deg 21' 47.61" N, 0 deg 18' 59.51" W
======== E:/IM/RAW_XMP/EVIL0371.CR2
AF Area Mode                    : Single-point AF
======== E:/IM/RAW_XMP/EVIL0371.xmp
GPS Position                    : 39 deg 21' 46.76" N, 0 deg 19' 1.09" W
======== E:/IM/RAW_XMP/EVIL0372.CR2
AF Area Mode                    : Single-point AF
======== E:/IM/RAW_XMP/EVIL0372.xmp
GPS Position                    : 39 deg 21' 46.52" N, 0 deg 19' 1.40" W
======== E:/IM/RAW_XMP/EVIL0373.CR2
AF Area Mode                    : Single-point AF
======== E:/IM/RAW_XMP/EVIL0373.xmp
GPS Position                    : 39 deg 21' 46.65" N, 0 deg 19' 0.88" W


Quote from: Phil Harvey on October 22, 2012, 11:34:32 AM
The answer is "yes", but I'm not clear about the question.

To read information from XMP files, specify the directory and add -ext xmp to the exiftool command.

- Phil
www.evilfoto.eu
*************

Phil Harvey

Hi Emilio,

To copy the GPS information from sidecar XMP files to the CR2, use this command:

exiftool -tagsfromfile %d%f.xmp -@ xmp2gps.args FILE

Where FILE is one or more file or directory names.  The "xmp2gps.args" file is included in the full ExifTool distribution package, and contains the following arguments:

-GPS:all < XMP-exif:all
-GPS:GPSLatitudeRef < Composite:GPSLatitudeRef
-GPS:GPSLongitudeRef < Composite:GPSLongitudeRef
-GPS:GPSDateStamp < XMP-exif:GPSDateTime
-GPS:GPSTimeStamp < XMP-exif:GPSDateTime


- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).

evilaro

Hi Phil:


I feel this will do the job.

Thanks

Emilio


Quote from: Phil Harvey on October 22, 2012, 12:01:24 PM
Hi Emilio,

To copy the GPS information from sidecar XMP files to the CR2, use this command:

exiftool -tagsfromfile %d%f.xmp -@ xmp2gps.args FILE

Where FILE is one or more file or directory names.  The "xmp2gps.args" file is included in the full ExifTool distribution package, and contains the following arguments:

-GPS:all < XMP-exif:all
-GPS:GPSLatitudeRef < Composite:GPSLatitudeRef
-GPS:GPSLongitudeRef < Composite:GPSLongitudeRef
-GPS:GPSDateStamp < XMP-exif:GPSDateTime
-GPS:GPSTimeStamp < XMP-exif:GPSDateTime


- Phil
www.evilfoto.eu
*************