I can see the map get more and more detailed when zooming in, while only a selected number of features displayed when zooming out. May I ask how the selection was made by OSM server? Is there a tag explicitly saying which feature should be displayed at which zoom level?

asked 25 Aug '17, 12:37

Digmaa's gravatar image

accept rate: 0%

Assuming you are referring to the standard style on opensreetmap.org: the rendering of individual elements colour, patterns, labels etc. is defined in a static style file, that contains rules for each zoom level. See https://github.com/gravitystorm/openstreetmap-carto for the source code.

You cannot influence the cartographic decisions by object tagging, nor would that be a sensible thing to implement.

If should be noted that with so called "vector tiles" which are rendered in your browser instead of as bitmaps on a central server, there is a bit more flexibility. However for practical reasons there is still a zoom level based object selection for the contents of the vector tiles.

permanent link

answered 25 Aug '17, 12:58

SimonPoole's gravatar image

SimonPoole ♦
accept rate: 19%

edited 25 Aug '17, 12:59


Interesting question and answers! The question is initially about map generalization. May I get to know map generalization was achieved? Or how to determine which map objects should be removed, or which map objects should be retained?

(25 Aug '17, 15:19) binjiang

Basically what I wondered is how OSM community deals the issue of automated map generalization from a single largest scale of database. Or just like many mapping agencies, OSM community maintains multiple databases for creating different scales of tiles. Any comments are highly anticipated. Thanks!

(26 Aug '17, 11:23) binjiang

If you have a proper question please ask in in a separate question and neither a comment or an answer.

(26 Aug '17, 11:36) SimonPoole ♦

To see the discussion that happens about "what gets displayed at what zoom level", have a look at the discussion that takes place on the issues and pull requests over at https://github.com/gravitystorm/openstreetmap-carto . That's just one renderer though.

An example of the actual code that results from this is https://github.com/gravitystorm/openstreetmap-carto/blob/master/power.mss#L4 - that says "show this at zoom level 14 and higher".

(26 Aug '17, 12:41) SomeoneElse ♦
Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here



Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:


question asked: 25 Aug '17, 12:37

question was seen: 1,426 times

last updated: 26 Aug '17, 12:41

powered by OSQA