Opened 9 years ago

Closed 5 years ago

#2992 closed defect (duplicate)

[roads] Improve rendering of junctions

Reported by: stanton Owned by: mapnik-team@…
Priority: minor Milestone:
Component: mapnik Version:
Keywords: Cc: dareus@…

Description

When different highway types share the same junction, rendering at the crossing point (which road is drawn on top) seems somewhat random. My suggestion for improvement is to introduce a priority based on the tags that affect rendering (most notably, highway and access):

  • highway=*_link "loses" over everything else (as a link by definition goes only from one road of the corresponding type to another road of the same or a lower type).
  • The only road of its kind to arrive at the junction "loses" over all others except *_link.
  • For roads that continue across the junction, the highest type wins - that is, first motorway, then trunk, then primary, then secondary, then tertiary, then unclassified, then residential and finally service.

A special case are any kinds of restrictions, such as denoted by the access tag and certain kinds of highway tags (e,g, highway=pedestrian). Restrictions denoted by the access tag are most likely interrupted when they continue beyond a junction. However, the case of an unclassified crossing a pedestrian is trickier: does the unclassified interrupt the pedestrian zone or vice versa? This is a semantic question and, where in doubt, is probably best denoted by tagging the node at which the ways cross accordingly.

Suggestion for this case: tag the node with the highway=* tag of the road that should continue across it (if necessary, same for the access=* tag) to make it clear. Some tags used exclusively on nodes (e.g. highway=crossing) may make this impossible but may by themselves contain the required information: in the case of the crossing between an unclassified and a pedestrian, if the node is tagged with highway=crossing or highway=traffic_signals, this implies that the unclassified interrupts the pedestrian way.

Change History (5)

comment:1 Changed 9 years ago by Ldp

Rendering priority ordering could indeed be better. CM has something like this, but the current stylesheet is not quite suited yet to that method.

Your other suggestions for junction handling (only road of its kind loses; which one continues across the intersection) are hard to handle, since roads are drawn serially, and they don't know about junctions and nearness of other roads.

comment:2 Changed 6 years ago by dareus@…

Cc: dareus@… added

After 3 years this bug (which I suppose is a tricky one) is still here.

It is quite bad in Italy where roundabout are almost everywhere and quite often there are many different highway tags connecting; e.g. here (I know it looks like a bean, but sometimes we like to be fanciful :) )

comment:3 Changed 5 years ago by math1985

@dareus@ I think that's a tagging mistake, the bean should not be tagged as link, I think.

comment:4 Changed 5 years ago by math1985

Summary: Improve rendering of junctions[roads] Improve rendering of junctions

comment:5 Changed 5 years ago by math1985

Resolution: duplicate
Status: newclosed

This issue is now being discussed on Github: https://github.com/gravitystorm/openstreetmap-carto/issues/832 Therefore, I will close this issue here.

Note: See TracTickets for help on using tickets.