Filtering OpenStreetMap Data for use in Forsk Atoll

Taking a full extract from OpenStreetMap using the export tool on the website provides a .osm output file, which includes all the layers.

I’ve written about using GlobalMapper to convert this data into shapefiles for use in Forsk Atoll, but when I want roads, and building footprints, and an outline of the area, I need all of those as separate files.

Enter the osmfilter application, which does just that.

It’s a simple binary (Download from here) you can use to extract just the layers you need, for example:

osmfilter.exe map.osm --keep="natural=coastline" -o=coastline.osm

Gets me just the coastline outline in coastline.osm

osmfilter.exe map.osm --keep="building=" -o=buildings.osm

Gets me just the building footprints in buildings.osm.

osmfilter map.osm --keep="highway=" -o=roads.osm

Gets me all the roads.

I can the import this data using GlobalMapper, to export as a Shapefile that I import into Forsk Atoll, and style the Buildings, the roads, the whatever, however you want.

Leave a Reply

Your email address will not be published. Required fields are marked *