Page 1 of 1

Calculate distance and time between maneouvres and segments

Posted: Mon Nov 23, 2015 9:21 am
by Patricia
Is it posible calculate the distance and time between two segments of a route? and also, Is it posible calculate the distance and time between Maneouvres of a route?

I'm using CalculateExtendedRoute for get Route between two or more waypoints.

Thanks in advance.

Re: Calculate distance and time between maneouvres and segme

Posted: Mon Nov 23, 2015 12:54 pm
by Bernd Welter
Hello Patricia,

you can derive the required information from the various arrays that are part of the result "route" object:
http://xserver.ptvgroup.com/fileadmin/f ... %7C_____58

It contains several arrays that are cross referencing each other.

A spontaneous recommendation from my side is
  • The distance between two segments segment[index1] and segment[index2] is
    distance := route.segments[index2].accDist - route.segments[index1].accDist
  • The distance between two maneouvres is based on the manouvres segments:
    distance := route.segments[manoeuvres[index2].routeListSegmentIndex].accDist - route.segments[manoeuvres[index1].routeListSegmentIndex].accDist


Best regards Bernd