GMoncrieff / ngimaps

Online map of South Africa based on CD:NGI map sheets

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

This is an application which provides a map of South Africa based on the 1:50,000 topographic map sheets published by the Chief Directorate: National Geospatial Information. The map can be seen in action at https://ngimaps.frith.dev/.

How it works

The 1,912 individual sheets of the 1:50,000 topographical map series are available as GeoTIFFs from the CDNGI Geospatial Portal. I downloaded these maps, warped them to Web Mercator projection, and trimmed off the marginalia so that just the map itself remains. The resulting files are available as Cloud Optimized GeoTIFFs (COGs) at https://mapimages.frith.dev/50k/.

These COGs are assembled into a MosaicJSON file. A small Python service based on TiTiler renders this layer into XYZ ("slippy") tiles. An instance of MapProxy sits in front of the tiler; it stores rendered tiles in an on-disk cache. Finally, an instance of NGINX sits in front of it all, serving cached tiles directly from the disk and otherwise passing the requests on to MapProxy. The NGINX service also serves the Leaflet-based frontend for viewing the map.

Note: generating tiles for zoom levels < 9 can be very demanding as it entails assembling many individual sheets into a tile. If you deploy this stack, I suggest pre-seeding those levels before going live.

About

Online map of South Africa based on CD:NGI map sheets

License:MIT License


Languages

Language:HTML 41.1%Language:JavaScript 24.4%Language:Python 16.3%Language:Dockerfile 12.0%Language:CSS 6.2%