Interface StripeAnimation.StripeData
- All Superinterfaces:
LineLocatable,Locatable,OtsShape
- Enclosing class:
- StripeAnimation
StripeData provides the information required to draw a stripe.
Copyright (c) 2023-2026 Delft University of Technology, PO Box 5, 2600 AA, Delft, the Netherlands. All rights reserved.
BSD-style license. See OpenTrafficSim License.
- Author:
- Wouter Schakel
-
Field Summary
Fields inherited from interface org.opentrafficsim.base.geometry.OtsShape
DEFAULT_POLYGON_SEGMENTS, WORLD_MARGIN_LINE -
Method Summary
Modifier and TypeMethodDescriptionReturns the center line in world coordinates, with directions of end-points.org.djunits.value.vdouble.scalar.LengthReturn dash offset.Returns the stripe elements.Returns the line along which dashes are applied.org.djunits.value.vdouble.scalar.LengthgetWidth(org.djunits.value.vdouble.scalar.Length position) Returns the line width.default doublegetZ()Methods inherited from interface org.opentrafficsim.animation.LineLocatable
contains, getLine, signedDistanceMethods inherited from interface org.opentrafficsim.base.geometry.OtsShape
contains, getAbsoluteBounds, getAbsoluteContour, getAbsoluteContour, getDirZ, getRelativeBounds, getRelativeContour, signedDistance
-
Method Details
-
getLocation
DirectedPoint2d getLocation()- Specified by:
getLocationin interfaceLocatable- Specified by:
getLocationin interfaceOtsShape
-
getCenterLine
DirectionalPolyLine getCenterLine()Returns the center line in world coordinates, with directions of end-points.- Returns:
- the center line in world coordinates, with directions of end-points
-
getReferenceLine
PolyLine2d getReferenceLine()Returns the line along which dashes are applied. At these fractions, parts of the centerline are taken.- Returns:
- line along which dashes are applied
-
getElements
List<StripeElement> getElements()Returns the stripe elements.- Returns:
- stripe elements
-
getDashOffset
org.djunits.value.vdouble.scalar.Length getDashOffset()Return dash offset.- Returns:
- dash offset
-
getWidth
org.djunits.value.vdouble.scalar.Length getWidth(org.djunits.value.vdouble.scalar.Length position) Returns the line width.- Parameters:
position- where to obtain width- Returns:
- line width
-
getZ
default double getZ()
-