This article describes how to style contour lines that intersect glaciers in your map. You can use this tutorial to improve your topographic or outdoor maps, particularly in mountainous regions covered with glaciers.
Important notice
To use the Contours tileset in your maps, you need to add it in the Advanced editor with the DATA SOURCES button. By default, contours are included in the Topo, Outdoor, and Winter map styles.
MapTiler Contours tileset
MapTiler Contours is a vector tileset containing contour lines with height in meters and additional information for index line and glacier styling. Contours are generated from zoom 9.
For cartographers, we recommend working with three main integer attributes:
height
- the exact height in meters that the contour connects
nth_line (possible values: 1, 2, 5, 10)
- index of the line useful for labeling or highlighting for example every 10th contour
glacier (possible value: 1)
- attribute confirming if the contour crosses a glacier
Styling
To style the contours to show where they intersect the glaciers, you need to use the Advanced editor. You can follow our example working with the Outdoor map style.
First, go to the layer contour
. Here we need to filter out the lines that are crossing a glacier, in order to style them separately using ["!has", "glacier"]
filter. The same should be done also for the layer contour_index
.
Next, create a copy of the layers contour
(we adjusted the name to contour_glacier
) and contour_index
and change the filter to ["==", "glacier", 1]
.
Now you can play with the colors for both new layers with the glacier
tag.
- for
contour
we usedhsl(200, 98%, 50%)
- for
contour_index
which highlights every 5th and 10th line, we chose a darker colourhsl(215, 100%, 49%)
You can use the same workflow to adjust also the contour_label
layer depicting the height. To make the contours stand out even more, change the colour of the glacier
polygon layer as well!
Conclusion
With the newly added glacier
tag in the Contours tileset, you can easily highlight the contours intersecting glaciers and bring your cartography to the next level.
Useful links
How to work with Customize tool and Advanced editor together in MapTiler Cloud
Comments
0 comments
Please sign in to leave a comment.