[OSM-talk] turn restriction relations: via
Tobias Knerr
osm at tobias-knerr.de
Mon Mar 30 20:58:51 BST 2009
Nic Roets schrieb:
> Perhaps we should introduce restriction=forced_left / forced_right etc. that
> are rendered the same as only_*, but interpreted as restrictions ?
> "Forced" may not be the best word. Any word that is unused will work.
> Perhaps only2left, only2right... or only2_left, etc ?
I assume that the name isn't the most important aspect. The main problem
is probably that users would have to add all forbidden alternatives
rather than just the single allowed one. That would, of course, be more
effort, and has also been argued by some to be more error-prone (adding
a new service road and forgetting to modify relations etc.).
What I've done for now is a only_ implementation that forces you to use
"to" after "from" with nothing but "via" ways (or parts of ways between
via node pairs) in between. It doesn't care about how many of the via
members you actually use.
Still wouldn't mind a real definition, though.
>>> I think we should require that complex vias must always include all the
>> ways
>>> that are traveled.
>> Does "way" mean way primitives here, as opposed to nodes?
>>
>
> In addition to nodes. AFAIK having nodes and ways in the same role of the
> same relation is allowed. I haven't decided what I favour : Either that all
> the nodes are optional, or that all the nodes except endpoints of 'from' and
> 'to' are optional.
I'd support make every node optional, as the endpoints can be determined
without help from the mappers (which means less work for them), and this
can always be done unambiguously if the ways are properly split (that's
usually the case anyway).
> I realized that there is an ambiguity with the current (unordered definition
> of via) that cannot be solved : If the via includes a loop that must be
> taken for the restriction to be applied.
Yes, I've thought about loops, too, and I have to agree that they are a
possible situation where order would make a difference. I've yet to see
any real-life examples, but nevertheless I don't really like this.
Tobias Knerr
More information about the talk
mailing list