Interface InfrastructurePerception
- All Superinterfaces:
LaneBasedPerceptionCategory,PerceptionCategory<LaneBasedGtu,LanePerception>
- All Known Implementing Classes:
DirectInfrastructurePerception
Copyright (c) 2013-2026 Delft University of Technology, PO Box 5, 2600 AA, Delft, the Netherlands. All rights reserved.
BSD-style license. See OpenTrafficSim License.
- Author:
- Alexander Verbraeck, Peter Knoppers, Wouter Schakel
-
Method Summary
Modifier and TypeMethodDescriptionReturns a set of relative lanes representing the cross section.Returns infrastructure lane change info of a lane.org.djunits.value.vdouble.scalar.LengthgetLegalLaneChangePossibility(RelativeLane fromLane, LateralDirectionality lat) Returns the distance over which a lane change remains legally possible.SortedMap<org.djunits.value.vdouble.scalar.Length,DirectedPoint2d> Relevant points in path from scanning.Returns infrastructure lane change info of a lane.org.djunits.value.vdouble.scalar.LengthgetPhysicalLaneChangePossibility(RelativeLane fromLane, LateralDirectionality lat) Returns the distance over which a lane change remains physically possible.Optional<DistancedObject<org.djunits.value.vdouble.scalar.Speed>>Returns speed bump information.getSpeedLimits(RelativeLane lane) Returns the current speed limits.
-
Method Details
-
getLegalLaneChangeInfo
Returns infrastructure lane change info of a lane. A set is returned as multiple points may force lane changes. Which point is considered most critical is a matter of driver interpretation and may change over time. This is shown below. Suppose vehicle A needs to take the off-ramp, and that behavior is that the minimum distance per required lane change determines how critical it is. First, 400m before the lane-drop, the off-ramp is critical. 300m downstream, the lane-drop is critical. Info is sorted by distance, closest first._______ _ _A_ _\_________ _ _ _ _ _ _ _ _ _ _________ _ _ ___ \_______ (-) Lane-drop: 1 lane change in 400m (400m per lane change) (--------) Off-ramp: 3 lane changes in 900m (300m per lane change, critical) (-) Lane-drop: 1 lane change in 100m (100m per lane change, critical) (--------) Off-ramp: 3 lane changes in 600m (200m per lane change)- Parameters:
lane- relative lateral lane- Returns:
- infrastructure lane change info of a lane
-
getPhysicalLaneChangeInfo
Returns infrastructure lane change info of a lane. A set is returned as multiple points may force lane changes. Which point is considered most critical is a matter of driver interpretation and may change over time. This is shown below. Suppose vehicle A needs to take the off-ramp, and that behavior is that the minimum distance per required lane change determines how critical it is. First, 400m before the lane-drop, the off-ramp is critical. 300m downstream, the lane-drop is critical. Info is sorted by distance, closest first._______ _ _A_ _\_________ _ _ _ _ _ _ _ _ _ _________ _ _ ___ \_______ (-) Lane-drop: 1 lane change in 400m (400m per lane change) (--------) Off-ramp: 3 lane changes in 900m (300m per lane change, critical) (-) Lane-drop: 1 lane change in 100m (100m per lane change, critical) (--------) Off-ramp: 3 lane changes in 600m (200m per lane change)- Parameters:
lane- relative lateral lane- Returns:
- infrastructure lane change info of a lane
-
getSpeedLimits
Returns the current speed limits.- Parameters:
lane- lane for the speed limits- Returns:
- current speed limits.
-
getPathScan
SortedMap<org.djunits.value.vdouble.scalar.Length,DirectedPoint2d> getPathScan()Relevant points in path from scanning.- Returns:
- relevant points in path from scanning
-
getSpeedBump
Optional<DistancedObject<org.djunits.value.vdouble.scalar.Speed>> getSpeedBump()Returns speed bump information.- Returns:
- distance and speed of first downstream speed bump.
-
getLegalLaneChangePossibility
org.djunits.value.vdouble.scalar.Length getLegalLaneChangePossibility(RelativeLane fromLane, LateralDirectionality lat) Returns the distance over which a lane change remains legally possible. Negative values indicate the distance over which a lane change is legally not possible.- Parameters:
fromLane- lane from which the lane change possibility is requestedlat- LEFT or RIGHT, null not allowed- Returns:
- distance over which a lane change remains possible
- Throws:
NullPointerException- iflat == null
-
getPhysicalLaneChangePossibility
org.djunits.value.vdouble.scalar.Length getPhysicalLaneChangePossibility(RelativeLane fromLane, LateralDirectionality lat) Returns the distance over which a lane change remains physically possible. Negative values indicate the distance over which a lane change is physically not possible.- Parameters:
fromLane- lane from which the lane change possibility is requestedlat- LEFT or RIGHT, null not allowed- Returns:
- distance over which a lane change remains possible
- Throws:
NullPointerException- iflat == null
-
getCrossSection
SortedSet<RelativeLane> getCrossSection()Returns a set of relative lanes representing the cross section. Lanes are sorted left to right.- Returns:
- set of relative lanes representing the cross section
-