Skip to content
This repository has been archived by the owner on Jul 24, 2021. It is now read-only.

routing should respect the to members of a turn restriction #2004

Closed
openstreetmap-trac opened this issue Jul 23, 2021 · 7 comments
Closed

Comments

@openstreetmap-trac
Copy link

Reporter: dmgroom
[Submitted to the original trac issue database at 8.24am, Monday, 29th June 2009]

Gosmore currently ignores relation = restriction when calculating the routing.

@openstreetmap-trac
Copy link
Author

Author: David Dean
[Added to the original trac issue at 9.35am, Monday, 29th June 2009]

gosmore currently does have support for some restriction relations, but I don't think it can currently handle restrictions with ways as the via.

If your restriction is a simple no_*_turn with from and to ways and a via node it should work.

@openstreetmap-trac
Copy link
Author

Author: David Dean
[Added to the original trac issue at 9.37am, Monday, 29th June 2009]

Some details on the operation can be gleaned from this thread: http://lists.openstreetmap.org/pipermail/routing/2008-August/000387.html

@openstreetmap-trac
Copy link
Author

Author: David Dean
[Added to the original trac issue at 1.37pm, Wednesday, 1st July 2009]

David Groom wrote:

Here is turn restriction relation I created http://www.openstreetmap.org/browse/relation/30772/history last edited on 8 June
and here's a route which doesn't obey the restriction I tried to create

http://www.yournavigation.org/?flat=50.681478&flon=-1.143316&tlat=50.677831&tlon=-1.144155&v=motorcar&fast=1&layer=mapnik

@openstreetmap-trac
Copy link
Author

Author: David Dean
[Added to the original trac issue at 1.48pm, Wednesday, 1st July 2009]

OK, I've had a look at the code in gosmore, and it turns out that the no_right_turn restriction is only based on the angle of travel as you leave the from way. I don't think the via or to members of the relation are considered at all. As the angle between the from way and the to way are within a 90 degree angle centred on the from way, gosmore currently views this as a straight_on corner and ignores the no_right_turn restriction accordingly.

So as gosmore currently stands, this would have to be changed to a no_straight_on restriction for it to work. This seems like a problem with gosmore's current method of interpreting turning restrictions, and I have updated the title of the bug to reflect this.

Ideally it seems that the angle of the turn should have no impact on the restriction, and it should only be determined by the from, via and to members and whether it is a no_* or only_* restriction.

@openstreetmap-trac
Copy link
Author

Author: grand.edgemaster[at]gmail.com
[Added to the original trac issue at 2.39pm, Wednesday, 1st July 2009]

In short, the original implementation of restriction handling in gosmore was no-brained and crazy, since it ignored the tagging spec?

@openstreetmap-trac
Copy link
Author

Author: dmgroom
[Added to the original trac issue at 3.10pm, Wednesday, 1st July 2009]

Replying to [comment:5 grand.edgemaster[at]gmail.com]:

In short, the original implementation of restriction handling in gosmore was no-brained and crazy, since it ignored the tagging spec?

I suspect that rather than "no-brained and crazy" it was more a case of the original Gosmore routing being developed before the current relation tagging came into practice.

@openstreetmap-trac
Copy link
Author

Author: nroets[at]gmail.com
[Added to the original trac issue at 10.49am, Wednesday, 4th November 2009]

In 2008, I created a file called routingTest.osm for testing gosmore (or any other routing software). Routing around the outside is the desired behaviour. My interpretation was then that the angle should be considered and gosmore passed the test at that time.

I recently changed the file so that angles are no longer considered and changed only_* from being a restriction to an enforcement. I changed gosmore and it now passes the test. Everything is in SVN.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

1 participant