[OSM-dev] SRTM Contour generation and height labelling

Nick Whitelegg nick at hogweed.org
Sun Feb 11 10:37:16 GMT 2007


Hello everyone,

I have something of a problem with height labelling on SRTM contours using 
Mapnik. The problem is that because the contours are generated by working out 
intersection points in each grid square within the SRTM height file (grid 
square are 1/120 degree across) the contour polylines in the generated 
shapefile are too short to be labelled in Mapnik. That is, each contour 
polyline in the shapefile only spans one 1/120 degree grid square. 

As well as my own utility (described above), the GDAL utility, gdal_contour, 
also results in contours which are not labelled frequently enough.

Looking at it, it seems that it will be very complex to write code from 
scratch to be able to define individual contour lines which cross multiple 
1/120 degree grid squares (e.g. treat the 500ft contour surrounding a 3km 
radius hill as a single polyline in a shapefile). Can anyone provide any 
pointers, maybe to existing code to solve this problem?

Thanks,
Nick




More information about the dev mailing list