Realtime visualisation of The Isle Of White using height, waterways and soil data
Technical Overview
A real-time terrain-generation pipeline that pulls in high-resolution GeoTIFF data covering the UK and bits of mainland Europe. That includes:
- 2 m/texel LiDAR heightmaps for topography
- Soil-composition data from the UK Soil Observatory
- Hydrology layers for rivers and waterways
The system decompresses the GeoTIFF tiles on the CPU, then streams them straight to the GPU as height, soil-type and water-type textures. From there, a set of compute shaders:
- Classifies every texel based on elevation, slope, soil and hydrology, building a GPU-resident classification map
- Uses that classification to work out where vegetation should appear (grass, rocks, trees, etc.) and procedurally generates GPU instance buffers for all the vegetation and rock geometry
Inputs
LiDAR heightmap data
Soil composition data
Hydrology and waterways data
Displacement Map
The terrain is generated using a grid mesh with 1024x1024 vertices that then gets displaced by the heightmap. The mesh is instanced so there is only ever one of them per LOD level.
1024x1024 grid mesh
1024x1024 mesh displaced with a LiDAR heightmap
Generating the Terrain
The waterways are rendered as a separate mesh with any area that is not water being masked out and not rendered. This mesh can then be rendered in the same location as the terrain mesh to show both ground and water.
Part of the Thames River Waterway
Terrain around the Thames combined with its Waterway
Vegetation
A procedural vegetation placement and instancing system then runs as a compute shader using the information from the soil map and procedural heuristics to determine the spread and type of vegetation across the terrain.
Finally
Some dinos get added for scale :)