Ejemplo n.º 1
0
LinearLocation LengthLocationMap::getLocation(double length) const
{
	double forwardLength = length;
	if (length < 0.0)
	{
		double lineLen = linearGeom->getLength();
		forwardLength = lineLen + length;
	}
	return getLocationForward(forwardLength);
}
Ejemplo n.º 2
0
LinearLocation
LengthLocationMap::getLocation(double length, bool resolveLower) const
{
    double forwardLength = length;

    // negative values are measured from end of geometry
    if (length < 0.0)
    {
        double lineLen = linearGeom->getLength();
        forwardLength = lineLen + length;
    }

    LinearLocation loc = getLocationForward(forwardLength);
    if (resolveLower) {
        return loc;
    }
    return resolveHigher(loc);
}