On Wed, Dec 17, 2008 at 3:21 PM, Scott Atwood <[email protected]>wrote:
> How does Mapnik select which place names to render when the cities are > close enough that there would be label collisions in the rendering? And is > there any good way of tagging the place name to give better hints about > which place names should have priority in case of collisions? > In particular, when I look at renderings of the California Bay Area at > various zoom levels, I see lots of poor choices for name collision > resolution. > > Virtually everyone would agree that San Francisco is the most prominent > city in the region, and should win any name rendering collision amongst > cities in the region. Yet, at zoom level 6 and 7, Daly City gets rendered > instead of San Francisco. Similarly, Oakland and San Jose are the next most > prominent cities in the region, yet at many zoom levels, smaller and less > prominent adjacent places get rendered instead. > > Another related quirk is that some of these smaller place names are have > discontinuities in when then show in the zoom sequence, e.g. Mountain View > shows up at zoom level 6 and 8, but not 7, and Santa Clara shows up at zoom > level 7, 9, and 11, but not 8 or 10. > > I'm sure this problem is not unique to the Bay Area, but it is merely an > example drawn from an area that I'm very familiar with. > > Is there a good solution to this problem? > > -Scott > I looked a bit at the osm.xml file for Mapnik. It currently orders them by the place tag hierarchy (city, town, suburb, village, hamlet/locality), but there doesn't seem to be any sorting within equal hierarchies (which is probably why you see Daly City instead of San Francisco at certain zooms). Ideally it could do this by population, with a bonus for capitals. The documentation for Mapnik indicates that it supports value comparisons, but it looks like the population would have to be stored in a column. Anyway, that seems like it would be the way to go. Karl
_______________________________________________ talk mailing list [email protected] http://lists.openstreetmap.org/listinfo/talk

