Friday, August 16, 2019

3D Terrain Mapping

Vladimir Agafonkin, the creator of the Leaflet mapping platform, has released a JavaScript library for real-time terrain mesh generation from height data. MARTINI allows you to render terrain in 3D.

MARTINI builds a 3D terrain using Right-Triangulated Irregular Networks (RTIN). Check out this MARTINI: Real-Time RTIN Terrain Mesh Observable notebook which both explains what this means and includes a demo map which shows you perfectly how RTIN works. You can zoom in an out and rotate the demo map. You can also adjust the level of precision using the slide control.

The 2D map below the 3D scene also updates in real-time when you adjust the precision of the map. This provides a great visualization of how Martini works as it shows the number of triangles being used at different levels of precision.

No comments: