TomTom Maps for JavaScript
    Preparing search index...

    Type Alias RouteProgressPoint

    RouteProgressPoint: RouteProgress & { pointIndex: number }

    Progress measurements tied to a specific coordinate on the route path.

    Extends RouteProgress with a pointIndex that identifies the corresponding entry in the route's coordinate array.

    Type Declaration

    • pointIndex: number

      Zero-based index of this point in the route's coordinate array.

    • The progress array on a route always contains entries for the first and last points
    • Progress for intermediate points can be linearly interpolated between entries
    const points: RouteProgressPoint[] = [
    { pointIndex: 0, travelTimeInSeconds: 0, distanceInMeters: 0 },
    { pointIndex: 50, travelTimeInSeconds: 120, distanceInMeters: 2500 },
    { pointIndex: 100, travelTimeInSeconds: 300, distanceInMeters: 5000 }
    ];