![]() |
Eclipse SUMO - Simulation of Urban MObility
|
Representation of a lane section. More...
#include <NIImporter_OpenDrive.h>
Public Member Functions | |
void | buildLaneMapping (const NBTypeCont &tc) |
Build the mapping from OpenDrive to SUMO lanes. More... | |
OpenDriveLaneSection | buildLaneSection (double startPos) |
bool | buildSpeedChanges (const NBTypeCont &tc, std::vector< OpenDriveLaneSection > &newSections) |
std::map< int, int > | getInnerConnections (OpenDriveXMLTag dir, const OpenDriveLaneSection &prev) |
Returns the links from the previous to this lane section. More... | |
OpenDriveLaneSection (double sArg) | |
Constructor. More... | |
Data Fields | |
std::map< int, int > | laneMap |
A mapping from OpenDrive to SUMO-index (the first is signed, the second unsigned) More... | |
std::map< OpenDriveXMLTag, std::vector< OpenDriveLane > > | lanesByDir |
The lanes, sorted by their direction. More... | |
int | leftLaneNumber |
std::string | leftType |
double | length |
The length of this lane section. More... | |
int | rightLaneNumber |
The number of lanes on the right and on the left side, respectively. More... | |
std::string | rightType |
the composite type built from all used lane types More... | |
double | s |
The starting offset of this lane section. More... | |
double | sOrig |
The original starting offset of this lane section (differs from s if the section had to be split) More... | |
std::string | sumoID |
The id (generic, without the optionally leading '-') of the edge generated for this section. More... | |
Representation of a lane section.
Definition at line 318 of file NIImporter_OpenDrive.h.
NIImporter_OpenDrive::OpenDriveLaneSection::OpenDriveLaneSection | ( | double | sArg | ) |
Constructor.
[in] | sArg | The offset from the start, counted from the begin |
Definition at line 1565 of file NIImporter_OpenDrive.cpp.
References lanesByDir, NIImporter_OpenDrive::OPENDRIVE_TAG_CENTER, NIImporter_OpenDrive::OPENDRIVE_TAG_LEFT, and NIImporter_OpenDrive::OPENDRIVE_TAG_RIGHT.
void NIImporter_OpenDrive::OpenDriveLaneSection::buildLaneMapping | ( | const NBTypeCont & | tc | ) |
Build the mapping from OpenDrive to SUMO lanes.
Not all lanes are converted to SUMO-lanes; the mapping includes only those which are included in the SUMO network.
[in] | tc | The type container needed to determine whether a lane shall be imported by using the lane's type |
Definition at line 1573 of file NIImporter_OpenDrive.cpp.
References NBTypeCont::getShallBeDiscarded(), joinToString(), NBTypeCont::knows(), NIImporter_OpenDrive::myImportAllTypes, NIImporter_OpenDrive::OPENDRIVE_TAG_LEFT, and NIImporter_OpenDrive::OPENDRIVE_TAG_RIGHT.
NIImporter_OpenDrive::OpenDriveLaneSection NIImporter_OpenDrive::OpenDriveLaneSection::buildLaneSection | ( | double | startPos | ) |
Definition at line 1647 of file NIImporter_OpenDrive.cpp.
References lanesByDir, NIImporter_OpenDrive::OPENDRIVE_TAG_LEFT, NIImporter_OpenDrive::OPENDRIVE_TAG_RIGHT, s, NIImporter_OpenDrive::OpenDriveLane::speed, and NIImporter_OpenDrive::OpenDriveLane::speeds.
bool NIImporter_OpenDrive::OpenDriveLaneSection::buildSpeedChanges | ( | const NBTypeCont & | tc, |
std::vector< OpenDriveLaneSection > & | newSections | ||
) |
Definition at line 1671 of file NIImporter_OpenDrive.cpp.
References gDebugFlag1, NBTypeCont::getSpeed(), joinToString(), lanesByDir, NIImporter_OpenDrive::OPENDRIVE_TAG_LEFT, NIImporter_OpenDrive::OPENDRIVE_TAG_RIGHT, NIImporter_OpenDrive::OpenDriveLane::speed, and NIImporter_OpenDrive::OpenDriveLane::type.
std::map< int, int > NIImporter_OpenDrive::OpenDriveLaneSection::getInnerConnections | ( | OpenDriveXMLTag | dir, |
const OpenDriveLaneSection & | prev | ||
) |
Returns the links from the previous to this lane section.
[in] | dir | The OpenDrive-direction of drive |
[in] | pre | The previous lane section |
Definition at line 1608 of file NIImporter_OpenDrive.cpp.
References laneMap, NIImporter_OpenDrive::OPENDRIVE_TAG_LEFT, and UNSET_CONNECTION.
std::map<int, int> NIImporter_OpenDrive::OpenDriveLaneSection::laneMap |
A mapping from OpenDrive to SUMO-index (the first is signed, the second unsigned)
Definition at line 352 of file NIImporter_OpenDrive.h.
Referenced by getInnerConnections(), and NIImporter_OpenDrive::setEdgeLinks2().
std::map<OpenDriveXMLTag, std::vector<OpenDriveLane> > NIImporter_OpenDrive::OpenDriveLaneSection::lanesByDir |
The lanes, sorted by their direction.
Definition at line 354 of file NIImporter_OpenDrive.h.
Referenced by buildLaneSection(), buildSpeedChanges(), NIImporter_OpenDrive::laneSectionsConnected(), OpenDriveLaneSection(), NIImporter_OpenDrive::recomputeWidths(), NIImporter_OpenDrive::sanitizeWidths(), NIImporter_OpenDrive::setEdgeLinks2(), and NIImporter_OpenDrive::splitMinWidths().
int NIImporter_OpenDrive::OpenDriveLaneSection::leftLaneNumber |
Definition at line 358 of file NIImporter_OpenDrive.h.
Referenced by NIImporter_OpenDrive::recomputeWidths(), NIImporter_OpenDrive::sanitizeWidths(), and NIImporter_OpenDrive::splitMinWidths().
std::string NIImporter_OpenDrive::OpenDriveLaneSection::leftType |
Definition at line 361 of file NIImporter_OpenDrive.h.
double NIImporter_OpenDrive::OpenDriveLaneSection::length |
The length of this lane section.
Definition at line 350 of file NIImporter_OpenDrive.h.
Referenced by NIImporter_OpenDrive::sanitizeWidths().
int NIImporter_OpenDrive::OpenDriveLaneSection::rightLaneNumber |
The number of lanes on the right and on the left side, respectively.
Definition at line 358 of file NIImporter_OpenDrive.h.
Referenced by NIImporter_OpenDrive::recomputeWidths(), NIImporter_OpenDrive::sanitizeWidths(), and NIImporter_OpenDrive::splitMinWidths().
std::string NIImporter_OpenDrive::OpenDriveLaneSection::rightType |
the composite type built from all used lane types
Definition at line 360 of file NIImporter_OpenDrive.h.
double NIImporter_OpenDrive::OpenDriveLaneSection::s |
The starting offset of this lane section.
Definition at line 346 of file NIImporter_OpenDrive.h.
Referenced by buildLaneSection(), NIImporter_OpenDrive::loadNetwork(), NIImporter_OpenDrive::sections_by_s_sorter::operator()(), NIImporter_OpenDrive::setEdgeLinks2(), and NIImporter_OpenDrive::splitMinWidths().
double NIImporter_OpenDrive::OpenDriveLaneSection::sOrig |
The original starting offset of this lane section (differs from s if the section had to be split)
Definition at line 348 of file NIImporter_OpenDrive.h.
Referenced by NIImporter_OpenDrive::splitMinWidths().
std::string NIImporter_OpenDrive::OpenDriveLaneSection::sumoID |
The id (generic, without the optionally leading '-') of the edge generated for this section.
Definition at line 356 of file NIImporter_OpenDrive.h.