Nop schrieb:
But now the real problem starts: How do I use the contour functions?
You say: "- Now the OSM styling engine is used to set labels, types &
resolution of the contour lines. "
How does this work? What rules are required? How can I distinguish
between minor and major lines, I did find some code that adds some
tags and then does some conversion, but there is nothing there for
minor/medium/major contour lines.
The code just sets "contour=elevation" and "ele=<level in meter>", so
you can do the rest with the style, e.g. like this:
# Contours take their name from the elevation setting.
contour=elevation & ele ~ '\d*[02468]00'
{ name '${ele|conv:m=>ft}'; }
[0x22 resolution 18]
contour=elevation & ele ~ '\d+00'
{ name '${ele|conv:m=>ft}'; }
[0x21 resolution 20]
contour=elevation
{ name '${ele|conv:m=>ft}'; }
[0x20 resolution 22]
How would I apply styles with --dem-maxlevels? When the levels
increase, so must the major contour distances, otherwise more and more
lines will be major while minor lines disappear from the map.
Ok, that's a valid point - I have no answer yet.
I also do not want all minor contour lines to be tagged with an
elevation, that clutters up the map. But I see no way to suppress this.
I think there is a special character (like the one for the highway
symbols) which "hides" the label unless you point on the line. I will
have a look.
Actually, with the styles above I have no problem with the labels
cluttering the display.
And eventually, how do I get the proper input data from CGIAR and
ASTER? What does a proper input file look like that the contours
function can process? I am only familiar with .hgt.
The CGIAR files are GeoTIFF files which cover 5x5 degrees. You can get
them from http://srtm.csi.cgiar.org/. The ASTER data
(http://asterweb.jpl.nasa.gov/gdem.asp) also comes as GeoTIFF files
(each covering 1x1 degrees as the SRTM HGT files).
Best wishes
Christian
_______________________________________________
mkgmap-dev mailing list
mkgmap-dev@lists.mkgmap.org.uk
http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev