You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We are struggling with interpreting the legs in the output from OSRM. Our goal is generally to draw a line with timestamps for each node. To draw the line, matchings[i].geometry.coordinates should be enough. However in order to enrich the coordinates with timestamps we need to use the legs.
I looks like that in a leg with n nodes, there is n-1 distances and durations. I guess duration[0] is the duration between nodes[0] and nodes[1]. However, we have noticed an overlap between the ending of one leg and the beginning of the next one. It appears as though the last two nodes in a leg also appears in the beginning of the next leg. Why is the output like that and how should the distance and duration be calculated in the overlap?
The text was updated successfully, but these errors were encountered:
Hi there,
We are struggling with interpreting the legs in the output from OSRM. Our goal is generally to draw a line with timestamps for each node. To draw the line,
matchings[i].geometry.coordinates
should be enough. However in order to enrich the coordinates with timestamps we need to use the legs.I looks like that in a leg with n nodes, there is n-1 distances and durations. I guess
duration[0]
is the duration betweennodes[0]
andnodes[1]
. However, we have noticed an overlap between the ending of one leg and the beginning of the next one. It appears as though the last two nodes in a leg also appears in the beginning of the next leg. Why is the output like that and how should the distance and duration be calculated in the overlap?The text was updated successfully, but these errors were encountered: