flight-planning-and-navigation
How to Use Openstreetmap Data for Custom Airport and Terrain Creation
Table of Contents
Unlock the Power of OpenStreetMap for Custom Airport and Terrain Creation
OpenStreetMap (OSM) is far more than a free alternative to commercial mapping services. It is a living, breathing geospatial database built by a global community of mappers. For developers, sim pilots, and 3D artists, OSM represents an unparalleled resource for generating highly detailed, custom airport layouts and terrain models. Whether you are building scenery for Microsoft Flight Simulator, X-Plane, or a bespoke simulation environment, OSM data provides the raw geographic intelligence needed to create accurate and visually rich environments.
This guide walks you through the entire workflow—from sourcing the right OSM extracts to processing them into ready-to-use 3D assets. You will learn which tools to use for different scales of project, how to filter for aviation-relevant features, and how to handle common pitfalls like data completeness and coordinate system conversion. By the end, you will have a production-ready pipeline for turning open geographic data into custom airports and terrain.
Why OpenStreetMap for Airport and Terrain Modeling?
Commercial datasets often come with restrictive licenses or high costs. OSM is offered under the Open Database License (ODbL), meaning you can freely use, share, and adapt the data for any purpose, including commercial simulators, as long as you attribute the contributors. The level of detail varies: many airports in OSM have runway polygons, taxiway lines, apron areas, building footprints for terminals, hangars, and even runway lighting markers. Terrain features such as elevation contours, water bodies, and landcover types allow you to combine airport geometry with its surrounding landscape for a seamless result.
The community actively maintains airport data. As real-world airports expand or renovate, OSM often reflects those changes within weeks. For custom creation, this means your virtual environment can mirror current conditions without waiting for a commercial update cycle.
What Makes OSM Suitable for Custom Creation?
- Vector richness: Elements like runways (tagged as
aeroway=runway) have precise coordinates, widths, and surfaces defined as tags. - Building detail: 3D attributes such as height, number of levels, and roof shape are available for many structures, aiding realistic terminal modeling.
- Terrain context: OSM includes coastlines, forests, parks, and water features that integrate into ground texturing and mesh generation.
- Global coverage: From major international hubs to small airstrips in remote regions, OSM has data you can use.
Step 1: Sourcing the Right OSM Extract
The first decision is scale. Exporting all of North America as a single OSM file would be enormous. You need to choose a download method based on the size of your intended project.
Small Areas: Direct Export from OpenStreetMap.org
For a single airport or a small radius (e.g., 5 km around a field), the OSM website provides a built-in export tool. Zoom to your area of interest, click the “Export” button, and you can download data as XML (.osm) or run an Overpass API query. This works well when you only need a few megabytes of data.
Recommendation: Use the “Overpass API” option for better control. For example, to get only airport-related features, you can write a query that filters by aeroway tag. Overpass Turbo is a great interactive frontend for this.
Medium to Large Areas: Geofabrik Downloads
When you need a region (like a state, province, or whole country), Geofabrik provides regularly updated extracts in both .osm.pbf (Protocolbuffer Binary Format) and .osm.bz2 formats. PBF is much more compact and faster to process. Visit Geofabrik’s download server and pick the region that covers your airport or terrain zone.
Tip for airports near borders: Download the extract that covers the majority of the airport. If the runway straddles a border, you may need to merge two extracts using Osmium or Osmosis.
Custom Bounding Box Extracts: BBBike or OSM Extracts
Services like BBBike let you define a custom rectangular bounding box and download that exact area in several formats. This is ideal when you want to cover a specific valley or coastline for terrain, without downloading the entire country. BBBike also offers time-series extracts if you need historical data versions.
Step 2: Essential Tools for Processing OSM Data
Raw OSM data contains thousands of tags and nodes. You need tools to filter, convert, and export only the elements relevant to airport and terrain creation. Below are the most effective open-source and free tools, each serving a specific role in the pipeline.
Osmosis – Command-Line Power
Osmosis is a Java-based tool for splitting, filtering, and converting OSM files. It can read PBF and OSM XML. To extract only aeroway features:
osmosis --read-pbf yourfile.osm.pbf --tag-filter accept-ways aeroway=* --used-node --write-xml airport_extract.osm
This creates a lightweight file containing only ways with aeroway tags and the nodes they reference. You can also filter for buildings, roads, or landuse.
Osmium – Faster Alternative
Osmium (the C++ library and osmium-tool) is often faster than Osmosis for large files. It supports flexible expression-based filtering. For example, to extract all runways and taxiways:
osmium tags-filter input.osm.pbf aeroway/runway aeroway/taxiway -o airport_features.osm.pbf
QGIS – Visual Data Inspection and Export
QGIS is indispensable for visually checking data quality, aligning with satellite imagery, and converting OSM layers into shapefile, GeoJSON, or DXF formats that can be imported into 3D software. Use the QuickOSM plugin to fetch OSM data directly within QGIS. You can then symbolize runway polygons, check for missing taxiway connections, and validate positions against a background map.
Blender with BlenderGIS – 3D Generation
Blender combined with the BlenderGIS add-on allows you to import OSM data and automatically generate buildings with heights, roads, and terrain grids. For airports, you can extrude runway surfaces to a thin slab, create apron meshes, and model terminal buildings from footprint outlines. BlenderGIS can also download SRTM elevation data to create a base terrain mesh.
Processing Terrain Data
OSM does not contain elevation data itself—you need to combine it with digital elevation models (DEMs). NASA’s SRTM (Shuttle Radar Topography Mission) provides 30-meter resolution global elevation, while higher-resolution data is available from national surveys. Tools like GDAL can reproject and clip DEMs to your bounding box. In BlenderGIS, you can load a DEM as a heightmap and overlay OSM vector features on top.
Step 3: Filtering and Preparing Airport Features
Airports in OSM are modeled using several key tags. Understanding these will help you extract exactly what you need and avoid clutter from nearby roads, parks, or buildings.
| Feature | OSM Tag Example | Geometry |
|---|---|---|
| Runway | aeroway=runway, also surface=asphalt | Way (linear) or area (polygon when drawn as a closed way) |
| Taxiway | aeroway=taxiway | Way or area |
| Apron | aeroway=apron | Area |
| Helipad | aeroway=helipad | Way or node |
| Airport Terminal | aeroway=terminal | Area (building outline) |
| Control Tower | aeroway=control_tower | Way or node |
| Hangar | aeroway=hangar | Area |
| Parking Lot | amenity=parking or parking=multi-storey | Area |
Practical filter approach: Use Osmium to extract all ways with aeroway tags, and all buildings within the airport boundary. You may also want road access (e.g., highway=* leading to the airport). For terrain, consider landcover tags like natural=wood or landuse=farmland to texture the ground.
Handling Runway Width and Surface
Runways tagged with width=* are often given in meters. If a runway is mapped as a line (single way), you need to offset it to create a polygon of the correct width. In QGIS, use the “Buffer” tool with the width value. For surfaces, tag values include asphalt, concrete, grass, or gravel. These can map to different materials in 3D.
Step 4: Conversion to 3D-Compatible Formats
Once you have filtered and cleaned your OSM data, the next step is converting vector features into 3D meshes. The common pipeline is: OSM to GeoJSON → Import into Blender or 3ds Max → Extrude and texture → Export to OBJ, FBX, or COLLADA for your simulator.
Exporting from QGIS
Right-click your layer and select “Export → Save Features As.” Choose GeoJSON if you plan to use BlenderGIS, or DXF if you prefer to import into AutoCAD or Max. For terrain meshes, export DEM raster data as GeoTIFF and convert to a heightmap in Blender.
Blender Workflow Example
- Install BlenderGIS from GitHub.
- In Blender, go to File → Import → OSM to load the osm file directly. Alternatively, use the “Get OSM” button in the BlenderGIS panel for a bounding box.
- BlenderGIS will create separate collections for buildings, roads, forests, and water. For airports, it may not auto-recognize aeroway features—you may need to re-tag them as “building” temporarily or use a custom import script.
- Select building footprints, go to Edit Mode, and use the “Extrude” tool (E key) to give them height. The building’s height tag can be read if written with BlenderGIS’s “Build Buildings” function.
- For runways, create a plane (Shift+A → Mesh → Plane), scale it to the runway dimensions, and use a texture image of asphalt or concrete. Align the plane to the OSM line by snapping vertices to nodes.
- Terrain: load a DEM as a plane and apply a “Displace” modifier with the elevation map. Then project your airport features onto this surface.
Automating with Python
If you have many airports to process, consider writing a Python script using the osmnx library (for fetching and simplifying networks) and trimesh or pyrender for 3D export. OSMnx can download aeroways and buildings as GeoDataFrames, then you can extrude each polygon based on height tags.
Step 5: Integration into Simulation Environments
Each platform handles custom scenery differently. The following guidelines apply to the most common simulation engines:
Microsoft Flight Simulator 2020/2024
MSFS uses a proprietary SDK. You can import your Blender scene as a glTF model package via the MSFS Toolkit. Alternatively, you can use the BGL Compiler and place your 3D models using lat/lon coordinates. OSM-derived terrain elevation can be baked into the ground mesh using the SDK’s “Mesh Generator” with GeoTIFF input.
X-Plane
X-Plane uses the apt.dat and DSF (Digital Scenery File) formats. For airports, you can use WED (World Editor) to layout runways, taxiways, and ground markings. Export your own 3D objects as OBJ8 format (X-Plane’s custom OBJ specification). Terrain can be added using .ter files referencing a mesh exported from QGIS.
Unreal Engine or Unity
For non-simulator visualizations, import your OBJ or FBX files directly. Unreal’s Landmass system allows you to import heightmaps. Place your OSM-derived buildings and runways as static meshes. Use the GeoJSON importers available on the Unreal Marketplace for streamlined integration.
Advanced Tips for Realistic Results
- Use OSMD2SHP for legacy or offline conversion: The
osm2shputility can quickly convert OSM files to shapefiles that are easy to load in GIS tools. - Correct projection: Many 3D engines expect a local Cartesian coordinate system. Use QGIS to reproject your data to a projected CRS (e.g., UTM zone) before exporting, so that your model is not in latitude/longitude degrees.
- Texturing from satellite imagery: Use the OpenAerialMap or Google Earth Pro (within fair use) to get orthophotos. In QGIS, load a WMTS layer of satellite imagery, then export the airport area as a georeferenced image. Use that as an image texture on a ground plane in Blender.
- Validate with known airports: Compare your output to default scenery in your simulator. If the runway orientation is off, double-check the OSM tags—runway directions are often tagged with
ref=12L/30R. - Batch processing for large sceneries: Use GRASS GIS or GDAL scripts to clip, reproject, and convert multiple OSM extracts into a cohesive terrain tile.
Common Pitfalls and How to Avoid Them
- Missing nodes: When filtering in Osmosis, always use
--used-nodeto ensure you don’t lose the geometry that defines your features. Or use Osmium which does this automatically. - Incoherent runway surfaces: OSM runways may be drawn as a single line even when the real surface is wide. Always check the
widthtag; if missing, you may need to estimate from known lengths. Use satellite imagery in QGIS to confirm. - Altitude mismatch: OSM does not provide elevation for terminal buildings. You must extract height tags (
building:levelsorheight) or manually assign plausible values. For terrain, ensure your DEM covers the entire airport extent and is vertically referenced to the same datum as your simulator (typically WGS84 ellipsoidal height). - Data staleness: Airport construction projects are frequent. Re-download your OSM extract before starting a major project. Use Geofabrik’s daily updates.
Conclusion: A Reliable Pipeline for Virtual Geography
Creating custom airports and terrain from OpenStreetMap data is not just feasible—it is a well-documented and actively supported workflow. The combination of OSM’s rich feature tagging, open GIS tools like QGIS and Osmium, and 3D suites like Blender gives you the freedom to model any airport on Earth with a degree of accuracy that rivals payware add-ons. By following the steps in this guide—sourcing extracts, filtering relevant tags, converting to 3D, and integrating into your target platform—you can build immersive, up-to-date environments that enhance any simulation project.
For further learning, explore the OSM wiki for aeronautical mapping standards and join communities like the AVSIM OSM Airports forum where mappers share airport data and techniques. With practice, you will be able to convert any real-world airport into a virtual asset that feels authentic and performs efficiently.