# Adding GPS data after image import



## harringg (Nov 16, 2010)

I discovered that I had some GPS data from images that were taken with my BlackBerry and clicking on the arrow next to them took me to a Google showing the actual location, and it was insanely accurate. Showed exactly where on the beach we were sitting, as I recognized the landmarks in Google Maps satellite view that were in my image I took. I realize it would be accurate, it was just cool to see it in action is all. 

I'm on a Mac and have seen some posts about Windows apps that will add GPS data to images in LR. Is this possible to add to an existing image on the Mac? I've got my images tagged with IPTC City/State so I could at least be in proximity with GPS. If I can add it, could this information be retained on export/upload?


----------



## Halfje-Bruin (Nov 16, 2010)

From LR I first import the images and save the XMP files (select the imported images and use Cmd-S). Next I use HoudahGeo to load the GPS track and match it with the imported images. Save the GPS data from HoudahGeo using XMP files; you can also write to the images directly but personally I want to keep my raw files untouched. And finally, in LR read the new metadata for the imported images.


----------



## johnbeardy (Nov 16, 2010)

The other thing about HoudahGeo is that if you don't have a tracklog you can apply GPS by dragging and dropping images onto a Google map.

John


----------



## johnbeardy (Nov 16, 2010)

Another point is that, as far as I can see, Lightroom behaves differently when the GPS data is added via a sidecar - you have to add that data before importing.

To test this, take some raw files which aren't in LR and add GPS data via a sidecar. Import them into LR and the GPS will show up. 

But import some more raw files which haven't had any GPS data added. Go now to the GPS program and add GPS data via a sidecar, then return to LR and try Metadata &gt; Read Metadata. It won't read the GPS data.

Repeat the same procedure but writing directly inside the raw file (or even better inside a DNG). In each case, LR will read the GPS data.

Why is this important? Well, for one thing you need to order your workflow if you want to use sidecars for importing GPS. For another, it's a pain if you need to update that GPS data (eg to correct your drag and drop). 

As usual, pulling out the pin and running for cover, embedded metadata trumps sidecars.... 

John


----------



## Jim Wilde (Nov 16, 2010)

[quote author=johnbeardy link=topic=11621.msg78'13#msg78'13 date=12899'185']

But import some more raw files which haven't had any GPS data added. Go now to the GPS program and add GPS data via a sidecar, then return to LR and try Metadata &gt; Read Metadata. It won't read the GPS data.

[/quote]

This is interesting, John. I did some limited testing using Geosetter (following your recommendation) on a few *existing* Lightroom-managed CR2s a month or so ago. I had Geosetter write the data to XMP sidecar, and when I then did the "Read Metadata from File" process, I found all the GPS data *was *imported, which is contrary to your findings. Different for NEF vs CR2?

However, one thing that also happened was that this metadata read also caused a "Reset Settings" to be applied to the develop history, so of course the preview reverted back to the original imported image. Easily corrected by stepping back one in the history panel, but a nuisance all the same....so I agree that if using this method to add geodata it's better to do it BEFORE importing into Lightroom. 

But as this would screw up my existing import workflow it's something I'll need to think about should I ever decide to start geotagging en masse.


----------



## harringg (Nov 16, 2010)

Thanks for the feedback. I should clarify my OP. I see how it's worded it's implying a different question than I intended. With images that already reside in my LR library, can I add GPS data manually to an image's metadata?

All the images I would like to do this with are family photos which are all .jpg.

Thanks


----------



## RikkFlohr (Nov 16, 2010)

You can, but I believe you have to use a third-party plugin like Jeffrey's Geoencoding Plugin. 

If memory serves, until LR detects coordinates in the field, it doesn't allow you access to enter/change them.


----------



## b_gossweiler (Nov 16, 2010)

[quote author=RikkFlohr link=topic=11621.msg78'21#msg78'21 date=1289929563]
You can, but I believe you have to use a third-party plugin like Jeffrey's Geoencoding Plugin. 

If memory serves, until LR detects coordinates in the field, it doesn't allow you access to enter/change them.
[/quote]

Jeffrey's Geoencoding Plugin won't let you write into the "proper" GPS data items in LR though, but will populate PlugIn variables with it. It will, however, include "real" GPS data upon export, and also let you save the PlugIn GPS data into XMP, so it can subsequently be reread into LR (subject to what John has noticed ...).

Beat


----------



## johnbeardy (Nov 16, 2010)

[quote author=harringg link=topic=11621.msg78'19#msg78'19 date=128991'514]
Thanks for the feedback. I should clarify my OP. I see how it's worded it's implying a different question than I intended. With images that already reside in my LR library, can I add GPS data manually to an image's metadata?

All the images I would like to do this with are family photos which are all .jpg.

Thanks
[/quote]
Yes, and using HoudahGeo. It will update the EXIF in the file, and you then use Metadata &gt; Read Metadata to update the catalogue.

John


----------



## Kesswicklimey (Nov 16, 2010)

I also use a mac.
I geotag my photos before putting into Lightroom using PhotoLinker which is a great product. I am sure you could use that on the photos and then refresh the metadata from the photos within Lightroom.


----------



## harringg (Nov 18, 2010)

[quote author=johnbeardy link=topic=11621.msg78'25#msg78'25 date=1289934384]
[quote author=harringg link=topic=11621.msg78'19#msg78'19 date=128991'514]
Thanks for the feedback. I should clarify my OP. I see how it's worded it's implying a different question than I intended. With images that already reside in my LR library, can I add GPS data manually to an image's metadata?

All the images I would like to do this with are family photos which are all .jpg.

Thanks
[/quote]
Yes, and using HoudahGeo. It will update the EXIF in the file, and you then use Metadata &gt; Read Metadata to update the catalogue.

John
[/quote]

I took 5 images that were set to IPTC&gt;Image&gt;Sublocation, City, State in LR Ie. 123 1st street, anytown, ST and resided in LR. I then selected view in Finder, drag-dropped to HoudahGeo, chose Geocode using a map, set everything correctly, chose Export&gt;Write EXIF tags, settings were Geocoded images only as the choice on the top, and the rest of the settings were all checked on the bottom.

I then went to LR&gt;Metadata&gt;Read Metadata from file
It warned about overwriting the images metadata, I said, OK and there is no IPTC&gt;Image information of any kind (existing was over written) and I don't have any GPS coordinates in LR.

Am I missing something in my workflow? It's a demo of HoudahGeo, but I only tried it on 5 images, which is the demo limit.


----------



## johnbeardy (Nov 18, 2010)

If the images are already in LR and you have applied metadata, Cmd S to save it back into the files, then do the HoudahGeo step.

John


----------



## harringg (Nov 18, 2010)

Off on a bit of a tangent, but even though I add metadata in LR, it's not actually a part of the image? That's good to know. I should go back and select any image I've worked with and Save metadata?

Also, that still didn't work. LR metadata added, LR&gt;Metadata&gt;Save Metadata to File, add Geotag in HoudaGeo and Export EXIF, back in LR, LR&gt;Metadata&gt;Read Metadata from file, and there is no GPS data in that image. Is it a limitation of the HoudaGPS app and it's not actually saving it in demo mode?


----------



## johnbeardy (Nov 18, 2010)

It should have worked. So, with an image in LR:

1. Save keywords and other metadata back to image (Cmd S)
2. Over to HoudahGeo and add the geotag, saving it to the files
3. Maybe test step 2 by re-opening HoudahGeo and seeing if those file have still got the GPS
4. Back in LR, LR&gt;Metadata&gt;Read Metadata from file 

On your tangent, I see no great reason to save the metadata back to the image if you're backing up your LR catalogue and if you only ever open those pictures from LR, not directly in another program. Save or don't save back if you want, and then make sure you think through the backup implications (ie exclude modified files from backup).


----------



## harringg (Nov 18, 2010)

1. check
2. check
3. check
4. check (Was looking at IPTC not EXIF, oops)

Gotta run, but have some followup ?'s for later.

Thanks


----------



## edgley (Nov 21, 2010)

I thought that I would have a go at this, now that I have keyworded my whole collection I need some more data to add  
Got it all working for RAWs, but the JPG are not showing the data; I have posted on their site asking for information.

What I thought I would be able to do, in LR, would be to sync the metadata. I choose the option, then select all data, but it doesn't seem to copy the GPS co-ordinates from the RAW to the JPG; any ideas why please?


----------



## Jim Wilde (Nov 26, 2010)

Have just splashed out a whopping £1.19 ($1.99) on a new iPhone app called gps4cam (see www.gps4cam.com). It's rather clunky (well, what do you expect for that price? ), but first impressions are that it does what it says on the tin!

Basic concept:

1. When about to start shooting on your field trip, start a new 'Trip' on the iPhone, which uses the inbuilt GPS capability to record a 'trip log' (there are various options as to how frequently the location data is recorded in the log to help minimise battery usage).
2. When done shooting, press "Export" in the app and the trip data is presented as a single screen "bar-code" which you take a picture of.
3. A free desktop app (Mac or Windows) is then used to read the pictures from your shoot and the picture from the iPhone app and updates the Exif data in the pictures with the appropriate GPS data (using the pukka Exif fields apparently).
4. Import pictures and viola, GPS data now in the metadata fields (accurate so far! ).

The thing I don't like is that it doesn't (when shooting RAW) write an XMP sidecar....it generates a new version of the file. In fact you can have it update the original file (by specifying the same input and output directory), and furthermore it will even do this by reading from, and writing back to, the files on the flash card. Yep, it actually works, though writing back to the card takes forever, so that's not something I'll do....but that then means messing with my import workflow which I'd be unhappy about (though probably easily adapted).

Verdict: cheap and cheerful, a very inexpensive solution for geotagging, plenty of scope for improvement (especially re RAW/XMP), as I said very clunky......but it seems to work so no doubt plenty of iPhone users will be trying it.

Apologies if this is old news, but I only came across it this evening.


----------



## Victoria Bampton (Nov 26, 2010)

Neat idea, thanks Jim, I'll take a look!


----------



## valeryn (Feb 23, 2011)

Hi all!

I can't get through a problem with geo tagging and would really appreciate any help.

My LR version is 3.3, camera is - Canon 30d and I'm shooting in RAW (CR2 extension for Canon).

All my photos already have keywords and some LR metadata (like labels & ratings). Some of then have adjustments made from within LR.

Now I decided to start geotagging (using PhotoLinker for example).

The problem is - if I press "Read metadata from file" button LR delete all my adjustments and metadata! But after that it actually sees the GPS-related info, such as coords, city and so on.

Tried to write GPS metadata into sidecars and RAW files, it doesn't seem any different.

One interesting note - after LR reads GPS info and reset all previous metadata the image history (in Develop mode) is still available. So, I can go a step back and it restores the adjustments I've made, but not rating/labels and keywords.

Any help wil be appreciated.

Valery


----------



## Charlie Choc (Feb 23, 2011)

You need to write metadata to file in LR, use photolinker to add GPS data, and then read metadata from file in LR. The first will save your settings, the last will read them back in along with the GPS data. That's what I do and it works fine.


----------



## valeryn (Feb 23, 2011)

Charlie Choc said:


> You need to write metadata to file, use photolinker to add GPS data, and then read metadata from file. The first will save your settings, the last will read them back in along with the GPS data. That's what I do and it works fine.


 
Thanks for your quick reply Charlie!

Forgot to mention - I'm saving metadata in LR before using any GPS software.
To be exact here is my test case:


Make any Canon RAW image black and white (just because it's going to be easier to check if adjustments are lost or not).
Assign any keyword to image and rate it.
Press CMD+S or Save metadata to file in LR (and in LR preferences I've specified - Automatically write changes into XMP). Any way, press CMD+S and click the menu item just to be sure 
Open any geo tagging software (I use PhotoLinker) and drag&drop the image to it.
Select any location. Check what City/State/Country are filled to.
Press write changes (my preference is - write metadata to photo only, so PhotoLinker modifies original CR2 file, i've checked - sidecar stays the same).
Press "Metadata > Read metadata from file"

*Excepted result* - in Metadata panel you see geo information you've specified in an external geo data software. For example City, Country & State in IPTC metadata. AND you adjustments, ratings & keywords stays the same.

*Actual result* - IPTC data updates immediately and all adjustments with KWs & ratings goes away.

Might be it is an issue with my specific camera RAW format.. But I don't think so. Just in case here is a RAW image from my Canon 30d - http://cl.ly/4n3W.

Could you please try to pass my test case on your computer?

Thanks!

Valery


----------



## Charlie Choc (Feb 23, 2011)

Valery,

I downloaded your raw file and imported it in LR. I then changed it to B&W and saved metadata to file (I have it set to do that automatically too). I don't have a GPS track for that photo, so I just manually tagged it to my address in photolinker. I then read metadata from file and the image was still B&W and was also geotagged. My photolinker preference is set to the default, write to sidecar if exists, photo otherwise - so maybe that is your issue.


----------



## valeryn (Feb 23, 2011)

Charlie Choc said:


> Valery,
> 
> I downloaded your raw file and imported it in LR. I then changed it to B&W and saved metadata to file (I have it set to do that automatically too). I don't have a GPS track for that photo, so I just manually tagged it to my address in photolinker. I then read metadata from file and the image was still B&W and was also geotagged. My photolinker preference is set to the default, write to sidecar if exists, photo otherwise - so maybe that is your issue.


 
Yes, it is! :hail:

It works like a charm with sidecars..

The reason I preferred writing to RAW directly - it is more interoperable way in case you use many apps.

Any ideas how I can copy GEO information from already tagged RAW files to its' sidecars?

*PS*. Bought LR today! Now I can use Jeffrey's plugins!


----------



## Charlie Choc (Feb 23, 2011)

Good news. I don't know how to copy GPS data from raw to sidecar, but if you still have the track files you could always just retag them with the save to sidecar option.


----------



## valeryn (Feb 23, 2011)

Thanks anyway! You helped a lot.

I don't have a track for most of those images. Tagged manually.

Here is a way, how to convert GPS data from RAW to sidecar:
1) Change PhotoLinker preferences to - Write GPS info to sidecar if exists.
2) Drag&Drop your previously georagged photos to PhotoLinker
3) Select all (CMD+A) and right click them.
4) Choose "Synchronize Metadata" submenu.
5) Push the button! (Write Changed Tags)
6) Re-read metadata in LR.

In case synchronize metadata doesn't make the WRITE button available - modify any empty editable field in PhotoLinker and write changes. After you can clear the temp field exactly the same way.


----------



## harringg (Nov 16, 2010)

I discovered that I had some GPS data from images that were taken with my BlackBerry and clicking on the arrow next to them took me to a Google showing the actual location, and it was insanely accurate. Showed exactly where on the beach we were sitting, as I recognized the landmarks in Google Maps satellite view that were in my image I took. I realize it would be accurate, it was just cool to see it in action is all. 

I'm on a Mac and have seen some posts about Windows apps that will add GPS data to images in LR. Is this possible to add to an existing image on the Mac? I've got my images tagged with IPTC City/State so I could at least be in proximity with GPS. If I can add it, could this information be retained on export/upload?


----------



## Charlie Choc (Feb 23, 2011)

Glad you found a solution, I'll have to remember that one.


----------



## Roscoe17 (Feb 24, 2011)

I found though that the edit history will be lost.  For small numbers of files I created virtual copies, read in the metadata, then copied the edits from the virtual copies back to the original files.  Works, but clunky and not practical for large numbers of files.  I want the GPS data in the raw file in the off chance that LR and I part ways.. Jeffrey's plugin stores the info externally to the file.  I had a ton of vacation photos that the GPS data was ratty, so I went back to ViewNX2 and fixed them.  Then I reimported them before I did the edits.


----------



## Roscoe17 (Feb 24, 2011)

TNG said:


> Have just splashed out a whopping £1.19 ($1.99) on a new iPhone app called gps4cam (see www.gps4cam.com). It's rather clunky (well, what do you expect for that price? ), but first impressions are that it does what it says on the tin!


 
Try GeotagPhotos.  Similar in recording but it uploads the data to the web, where you then download it to a gpx file.  I then use GPSphotolinker to tag my already downloaded raw files.  I think it works quite well.  I just have to make sure I do it before I import the files into LR.


----------



## valeryn (Feb 24, 2011)

Roscoe17 said:


> I found though that the edit history will be lost.  For small numbers of files I created virtual copies, read in the metadata, then copied the edits from the virtual copies back to the original files.  Works, but clunky and not practical for large numbers of files.  I want the GPS data in the raw file in the off chance that LR and I part ways.. Jeffrey's plugin stores the info externally to the file.  I had a ton of vacation photos that the GPS data was ratty, so I went back to ViewNX2 and fixed them.  Then I reimported them before I did the edits.


 
Hi Roscoe17!

Yesterday, I have updated about 1000 photos using the method above (Save metadata in LR + PhotoLinker writing to sidecars + Read metadata from file in LR).

I have virtual copies as well and all images has about 3-10 items in history.

So, checked about 10 random images including some virtual copies and all seems fine. History is ok, copies are ok and rating/KW/labels are ok.

The only thing I can mention here - GPS info won't populate to virtual copies using this method. You have to copy it manually (Alt+Shift+CMD+C: check filled and Alt+Shift+CMD+V for example).


----------



## incagraphy (Jul 6, 2011)

has anyone tried to use "metadata> update DNG Preview and Metadata" instead of "read metadata from file"?  That seems to do the trick for me for grabbing the GPS data from the file without removing my "develop" changes on the photo.   also, could someone mention more details about the software called PhotoLinker? I have this application on my Mac, but i cannot see any of the preferences you are talking about ("write to sidecar if it exists" or the "write" button appearing somewhere).  lastly, PhotoEditor or PhotoLinker (the one I have) seems to be able to EDIT GPS data, but can we REMOVE this data from the RAW file (not talking about excluding it from the export file using Jeffrey Friedel's plugin)? Any disadvantages of having GPS directly on RAW rather than sidecars?


----------



## Victoria Bampton (Jul 7, 2011)

Hi incagraphy, welcome to the forum!

Update DNG Preview & Metadata should be doing the same as "WRITE metadata to file", rather than read, except it also rebuilds the embedded preview at the same time.  It would be interesting to figure out what's going on there, if you can still replicate it.


----------

