VR-Forces 4.2 Class Documentation
Functions
calcHeadingAlongRouteSegment.h File Reference

Go to the source code of this file.

Functions

DT_DLL_vrfmodel double DtCalculateHeadingAlongRouteSegment (const DtVector &localTestPoint, const DtVector &localRouteSegmentStart, const DtVector &localRouteSegmentEnd, const Coordinate_System &coordinateSystem, double offsetFromRouteSegment=0.0, double minCorrectionDistance=0.1, double maxCorrectionDistance=8.0, double maxCorrectionAngle=0.5236)
 Calculates the heading for a given test point to direct it along a route segment.

Detailed Description

Function Documentation

DT_DLL_vrfmodel double DtCalculateHeadingAlongRouteSegment ( const DtVector localTestPoint,
const DtVector localRouteSegmentStart,
const DtVector localRouteSegmentEnd,
const Coordinate_System &  coordinateSystem,
double  offsetFromRouteSegment = 0.0,
double  minCorrectionDistance = 0.1,
double  maxCorrectionDistance = 8.0,
double  maxCorrectionAngle = 0.5236 
)

Calculates the heading for a given test point to direct it along a route segment.

It finds a heading that attempts to both direct a given point toward the endpoint of a route segment and keep the point close to the segment at the same time. Called periodically in the context of moving along a route or attempting to stay in lane while traveling along a road feature.

Returns
Heading in radians.
Parameters
localTestPointPoint from which we want to find the appropriate heading to move toward the endpoint of the route segment. In local (database) coordinates.
localRouteSegmentStartStarting point of route segment in local coordinates.
localRouteSegmentEndEnd point of route segment in local coordinates. This is the goal we are heading toward.
coordinateSystemCoordinate system that local coordinates are given in.
offsetFromRouteSegmentSigned offset from route segment that we would like to maintain when moving along segment. Positive value indicates offset to right as you look down the segment from the starting point to the end point. Negative value indicates an offset to the left. In meters.
minCorrectionDistanceMinimum distance threshold below which we will not attempt to correct heading to pull point on to the route segment.
maxCorrectionDistanceMaximum distance threshold above which we will not attempt to correct heading to pull point on to the route segment.
maxCorrectionAngleAbsolute value of the maximum amount of angular correction we will make to pull the point in toward the route segment. In radians (default = 30 degrees).

Document ID: Generated on Sun Nov 24 19:49:21 EST 2013 from SVN revision 133924
Copyright © 2005-2013 VT MÄK. All Rights Reserved (www.mak.com)