[Routing] Turn by turn instructions
Nic Roets
nroets at gmail.com
Thu Jul 24 17:19:47 BST 2008
I reimplemented turn-by-turn instructions in gosmore. Here is the basic logic :
Look ahead at the predicted route for up to 300m. If there is a
junction (defined as a node with 3 segments) and the predicted route
makes a turn smaller than 45 degrees, continue looking further ahead.
If the turn is larger than 45 degrees, output either "turnLeft",
"turnRight", "keepLeft" or "keepRight". The latter 2 are used then the
turn junction wasn't the first junction encountered.
I'm not too used to roundabouts (not too many around here) and I've
never seen a satnav operate at one. But I suspect the best idea is to
tell the driver how many exists to skip.
More information about the Routing
mailing list