Photo mapping

From OpenStreetMap Wiki
Jump to navigation Jump to search

broom

This article or section may contain out-of-date information. The information may no longer be correct, or may no longer have relevance.
If you know about the current state of affairs, please help keep everyone informed by updating this information. (Discussion)
For tracing aerial photos, see Using Imagery.
Mapping with photos.png

Photo mapping is a mapping technique that involves capturing and reviewing photos for the purpose of drawing a map.

Taking pictures with mapping in mind

Use your camera to help you remember stuff—it can be as simple as that!

This can be a great time saver—far quicker taking photos of street signs or points of interest than either writing them down, typing on a smartphone, or waypointing on a GPS gadget. What's more, most smartphones and many cameras embed GPS coordinates into photos' metadata, making it easy to match the photos with the locations where they were taken.

That said, you don't strictly need GPS or any of the other advanced tricks described on this page, especially if you have good memory or are mapping an area with good Bing coverage (makes it a lot easier to get things in the right place). You'll need to remember which paths you traversed and what directions you were facing when you took your photos. It's always a good idea to input map data as soon as possible after collecting it, while your memory is fresh. Also, the more photos you take, the better. For example, if an area of one photo is visible in another, it's much easier to orientate when you're looking back over them.

Orientation

Even if you have a GPS track, it can be difficult to determine the way you were facing when taking a photograph. You can develop your own tricks to solve these problems, but one approach is to simply rotate the camera: Landscape pictures for what's ahead, portrait for the way you just came from, and rotated +/- 45° for whatever is to the right or left—pretty low-tech, but sufficient most of the time. You can also work out orientation using the angle of the sunlight in the pictures.

Geo-located photos

Smartphones and some cameras come with in-built GPS (and some GPS units come with in-built camera) so these devices will typically write geolocation data to the image file's metadata (EXIF) each time the shutter is snapped. This is very easy with a smartphone, although you may need to enable it. It makes things much easier. Tools such as JOSM will generally use this geolocation metadata.

Time synchronizing

What if you're using a camera without GPS? You might work with two separate gadgets, a camera and GPS unit. Digital cameras add the date and time to each photo (in the EXIF data), and a GPS tracklog will allow you to correlate by time, matching up the photos to the exact position they were taken. See JOSM/Photomapping if you want the photos to display in the proper location in JOSM, or see Geotagging Source Photos if you want to add geo-tags to photos that don't have them.

Editor integration

JOSM Screenshot, showing the photo mapping feature.

Editor integration is available for Potlach (Potlatch/Photo-mapping; KML), JOSM (JOSM/Photomapping), and Vespucci ([1]). Since August 2023, iD also supports using your own georeferenced photos ([2]) and added support for Mapilio, in addition to mapillary and KartaView.

Tagging and storage

If you want to tag an object (node, way etc) to show that you positioned it using a photograph and not GPS data (perhaps a fence you didn't walk along running directly between two places already on the map), use source=photograph. If, more commonly, it's the name of the object that you got from the photo (e.g. a street name), use source:name=photograph. Similarly, for road numbers (e.g. ref=A305), use source:ref=photograph.

There's nowhere within the OSM project for the photos themselves to be stored. If you upload them to a website such as Flickr, you can use e.g. source_ref=http://example.com/123.jpg (or source_ref:name=* or source_ref:ref=*) to link the photo to the object.

If you're using the Annotation Presets with JOSM, it'll suggest the right tag at the right time, and you won't need to worry about which one is which!

You should add the GPS positions to your photos, see Geotagging Source Photos.

See source=* for more source-tagging options

Other Software

EXIF data showing creation time
  • Geosetter (no stable release since 2019, but a beta from 2023 is available) can display photos on a variety of map backgrounds (Google, OSM, Mapbox) for an individual image or a folder of photos using a GPS tracklog and a GPS time calibration photograph for correlation. It uses ExifTool to write the corrected times and coordinates to the EXIF header. It can also look up locations (country, county, city, etc.) and optionally write that data to the EXIF header.
  • OJW's image locator PERL script (possibly outdated information) can combine a directory full of JPEG images, with a GPX tracklog, to produce a list of latitude/longitudes for each photo.
  • Seth Golub's geocoding scripts (version from 2017, live page is gone now) do pretty much the same thing, but write the data into the EXIF section of the JPEGs using exiv2. The scripts also provide a more usable command line interface to exiv2 for reading and writing geographic data to/from EXIF headers. (Uses the Google Maps API which is now defunct.)
  • For Linux users there is GPSCorrelate (version from 2012, live page is gone now) which has command line and GUI apps and is available in most repositories.
  • GpsPrune, a java-based cross-platform application which can correlate photos manually or automatically using timestamps (from GPX, KML or text files). It can output the photos in a KMZ file or it can use ExifTool to write the coordinates to the JPEG files.
  • A Photo Manager Android app to manage local photos including show photos in a map and edit exif geo-data.
  • A little tool to compute the -geosync parameter for ExifTool given a photo of an accurate time source.

More software and information about writing location in the pictures' metadata can be found on the Geotagging Source Photos wiki page.

Some Nokia camera phones do not include date information in EXIF headers, causing JOSM and other tools to fail. The date and time can be copied from the file creation time using the useful Perl library and command-line application ExifTool : $ exiftool -P '-FileModifyDate>DateTimeOriginal' *.jpg

Websites/projects about geolocating photos

Websites/projects as (free) services:

  • Flickr, the photo sharing site, supports special OSM "machine tags". If it's a photo of an OSM object you can add tags such as osm:way=123456 or osm:node=654321 and Flickr will link to the data browser page. We also have a normal 'openstreetmap' tag and a group.
  • Google Photos will show you a map of your geo-tagged images.
  • KartaView, formerly OpenStreetCam and OpenStreetView, project to upload geotagged images and put them on openstreetmap layers. Even if you don't have any images yourself, you can help by moderating existing images!
  • Mapillary - Crowdsourced Street Level Photos
  • Mapknitter (defunct), Public Lab's browser-based image stitching program, supports automatic or manual placement of aerial photos and exports them as GeoTIFF, TMS, or a basic JPG.
  • Pic4Carto, an efficient street pictures viewer for mapping. It combines pictures from several sources (Wikimedia Commons, Flickr, Mapillary, OpenStreetCam) and shows them all in a simple user interface. Website.
  • Pic4Review, an easy editor for OSM using street-level pictures, make wide use of free-licensed geolocated pictures in order to contribute simply to OSM.
  • Wikimedia Commons is the media repository created for the Wikimedia Foundation's wikis (including Wikipedia), and is integrated into some mapping tools. Images on Wikimedia Commons can be attached to OSM entities using the wikimedia_commons=* key.

Miscellaneous (local tools or software repositories):

  • CycleStreets (cyclestreets.net) has a Photomap for street photos of cycling facilities (No geographical restriction, though routing is UK-only). CycleStreets for iPhone has direct addition of photos, and the app code is GPL
  • Show Your Places (syp.renevier.net) is a CMS specifically designed for showing geolocalizated photos and add. A software repository with demo page. It requires PHP and MySQL.
  • phpMyGPX (phpmygpx.tuxfamily.org) is an open source web based application showing photos and GPX tracks on different OSM layers. A software repository with demo page. It requires PHP and MySQL.
  • Viking (viking.sf.net), local program allows you to create and edit tracks and waypoints.
  • digiKam has a map view of all your geo-tagged photos.

Abandoned or merged projects:

  • MapPIN'on OSM, introducing system of geotagged photos. The website is designed as very simple in order to introduce millions of photos. This server doesn't hold any photos. Those photos are uploaded on each author's blogs and just linked to "MapPIN'on OSM" by RSSes. Seems to be defunct (except for the Ads?).
  • OpenStreetPhoto. (inactive) Somewhat misnamed project. Mostly working on various ideas for gathering aerial imagery (quadcopters) but some work on OCRing of street-level imagery. Seemed more active in 2009, then merged to OpenStreetView (which became KartaView).
  • Geolocation.ws - geotagged Creative Commons photos taken from Panoramio, Flickr, Geograph, 500px and Wikimedia Commons websites. Supports direct photo and GPX trace file upload

Other photography

If you get any better sunny weather / picturesque photos (not just pictures of a street sign) while you're out mapping...

Table of some top level categories for photo upload to Wikimedia Commons
Photo Type WikiCommons Category
Bridges Category:Bridges by location
Buildings Category:Buildings by location
Commemorative Plaques Category:Commemorative plaques
Cultural Heritage Monuments Category:Cultural heritage monuments
Hiking and footpath signs Category:Hiking and footpath signs by country
Historic Markers Category:Historical markers and information signs
Monuments and memorials Category:Monuments and memorials by location
Public Art Category:Public art
Street Art Category:Street art
Trailheads Category:Trailheads by country

See also