OJW's magic organ grinder

From OpenStreetMap Wiki
Jump to: navigation, search

A set of scripts for turning OSM data into something usable


(optional - or just start with planet.osm)

  • create download filter
  • download area from xapi



  • nodes,segments stored in memory, used for (todo:whatstheword)
  • creates a textfile with interesting ways
  • creates a textfile with interesting nodes

'interesting' means that it contains tags, where 'boring' tags like id, lat, created_by, etc. are ignored


  • choose view definitions
  • choose searchable items
  • create object filter from union of those
  • allocate type IDs to objects used
  • creates new textfiles for ways and nodes

creates a textfile where each object has an enumerated type. e.g. 'highway=cycleway' => 'type 35'


  • define a tilesize
  • for each tile
    • copy ways which intersect
    • copy areas which surround or intersect
    • copy nodes which are within
      • (TODO: or if a specified bounding box around the node intersects?)
  • creates a load of textfiles where each one contains enough data to draw the area within it


  • iterate based on layer/level (to order result)
  • pack into binary format
  • create meta-info file
  • create strings file


All in http://svn.openstreetmap.org/applications/utils/export/osm2stuff/

Other similar projects