Package org.opentrafficsim.core.geometry
Class OTSOffsetLinePK
- java.lang.Object
-
- org.opentrafficsim.core.geometry.OTSOffsetLinePK
-
public final class OTSOffsetLinePK extends Object
Peter Knoppers' attempt to implement offsetLine.Copyright (c) 2013-2020 Delft University of Technology, PO Box 5, 2600 AA, Delft, the Netherlands. All rights reserved.
BSD-style license. See OpenTrafficSim License.- Version:
- $Revision$, $LastChangedDate$, by $Author$, initial version Dec 1, 2015
- Author:
- Peter Knoppers
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static OTSLine3DoffsetLine(OTSLine3D referenceLine, double offset)Construct an offset line.static voidsetDebugOffsetLine(boolean newValue)Set or clear the debugging flag.
-
-
-
Method Detail
-
offsetLine
public static OTSLine3D offsetLine(OTSLine3D referenceLine, double offset) throws OTSGeometryException
Construct an offset line.- Parameters:
referenceLine- OTSLine3D; the reference lineoffset- double; the offset; positive values indicate left of the reference line, negative values indicate right of the reference line- Returns:
- OTSLine3D; a line at the specified offset from the reference line
- Throws:
OTSGeometryException- when this method runs into major trouble and cannot produce a decent result
-
setDebugOffsetLine
public static void setDebugOffsetLine(boolean newValue)
Set or clear the debugging flag.- Parameters:
newValue- boolean; new value for the debugging flag
-
-