Aimsun Next Scripting
22
|
Public Types | |
enum | LateralType { eLeftIn , eLeftOut , eRightIn , eRightOut } |
enum | GKSectionOrientation { eGKNorth , eGKSouth , eGKEast , eGKWest } |
enum | sectionSide { eOrigin =0 , eDestination } |
![]() | |
enum | GKBezierCurveType { eSegment = 0 , eSimpleCurve = 1 , eCurve = 2 } |
![]() | |
enum | GKGeoContainer { eNothing = 0 , ePartially = 1 , eTotally = 2 } |
![]() | |
enum | IdentifierFormFlag { eIdentifierDefault , eIdentifierId , eIdentifierName , eIdentifierExternalId , eIdentifierTypeExternalName , eIdentifierDescription , eIdentifierStandard , eIdentifierStandardWithType , eIdentifierAll } |
enum | GKLockType { eNone , eModification , eDelete , eModificationDelete } |
enum | GKObjectStatus { eNew , eSaved , eModified , eDeleted } |
typedef QFlags< GKObject::IdentifierFormFlag > | IdentifierForm |
Public Member Functions | |
GKSection () | |
virtual GKBBox | getBBox () const |
bool | canUse (GKVehicleClass *v) const |
QVector< double > | getLaneExtraLengthAtEntrance () const |
QVector< double > | getLaneExtraLengthAtExit () const |
bool | canUseVehicle (const GKMobileAgent *v) const |
GKNode * | getOrigin () const |
GKNode * | getDestination () const |
void | setOrigin (GKNode *) |
void | setDestination (GKNode *) |
virtual int | getDataValueInt (const GKColumn *, const GKContext &=GKContext::anyContext) const |
virtual double | getDataValueDouble (const GKColumn *, const GKContext &=GKContext::anyContext) const |
virtual void | setDataValue (const GKColumn *, const QVariant &) |
virtual bool | getDataValueBool (const GKColumn *attr, const GKContext &context=GKContext::anyContext) const |
const GKRoadType * | getRoadType () const |
void | setRoadType (const GKRoadType *, bool) |
double | getLaneWidth () const |
void | setLaneWidth (double width) |
double | getLaneWidth (uint lanepos) const |
void | setLaneWidth (uint lanepos, double width) |
GKCoord | getLanesLength2D () const |
GKCoord | getLanesLength3D () const |
GKCoord | getLaneLength2D (uint lanepos) const |
GKCoord | getLaneLength3D (uint lanepos) const |
GKCoord | getLaneLength2DWithoutPedestrianCrossings (uint lanepos, bool full=false) const |
GKCoord | getLaneLength3DWithoutPedestrianCrossings (uint lanepos, bool full=false) const |
const QVector< GKSectionLane > & | getLanes () const |
GKSectionLane & | getLane (uint lanepos) |
void | removeLane (uint lanepos) |
void | removeLastLane () |
void | addLane (const GKSectionLane &lane, int lanepos=-1) |
QPair< int, int > | getLanesAtPos (double pos) const |
int | getNbLanesAtPos (double pos) const |
int | getNbFullLanes () const |
QPair< int, int > | getEntryLanes () const |
QPair< int, int > | getExitLanes () const |
bool | existLaneAtPos (int laneNumber, double pos) const |
QPair< int, int > | getLanesAtSegment (int segment) const |
GKCoord | getWidth () const |
virtual void | changeDirection () |
virtual void | join (const GKPolyline *pol, bool atStart) |
virtual void | removePoints (uint nbPoints, bool atStart) |
void | removePoint (uint pos) |
void | setEntranceLineAngle (GKCoord angle) |
GKCoord | getEntranceLineAngle () const |
void | setExitLineAngle (GKCoord angle) |
GKCoord | getExitLineAngle () const |
GKCoord | getExitAngle () const |
GKCoord | getEntranceAngle () const |
GKSectionOrientation | getSectionEntranceOrientation () const |
GKSectionOrientation | getSectionExitOrientation () const |
int | getLastSegmentNbLanes () const |
int | getNbTurningsUsingLane (int iLane, sectionSide iSide) |
GKCoord | getEntranceHeight () const |
GKCoord | getExitHeight () const |
GKCoord | getZRotationAtDistance (GKCoord dist, bool degrees) const |
GKCoord | getYRotationAtDistance (GKCoord dist, bool degrees) const |
GKCoord | getHeightAtDistance (GKCoord dist) const |
GKCoord | getHeightAtPoint2D (const GKPoint &p, int nbLane) const |
GKCoord | getHeightAtPoint2D (const GKPoint &p, const GKPoints &bezierCurve) const |
bool | isConnected (const GKSection *) const |
double | getSpeed () const |
void | setSpeed (double) |
void | clearSpeedDetailed () |
void | setSpeedDetailed (int, int, double) |
double | getSpeedDetailed (int, int) |
double | getCapacityForVehicle (const GKVehicle *v, const GKModelConnection *iModelConnection) const |
double | getCapacity () const |
void | setCapacity (double value) |
double | getAdditionalVolume () const |
void | setAdditionalVolume (double value) |
double | getUserDefinedCost () const |
double | getUserDefinedCost2 () const |
double | getUserDefinedCost3 () const |
void | setUserDefinedCost (double value) |
void | setUserDefinedCost2 (double value) |
void | setUserDefinedCost3 (double value) |
GKFunctionCost * | getInitialFunction () const |
GKFunctionCost * | getKInitialsFunction () const |
GKFunctionCost * | getDynamicFunction () const |
void | setInitialFunction (GKFunctionCost *fc) |
void | setKInitialsFunction (GKFunctionCost *fc) |
void | setDynamicFunction (GKFunctionCost *fc) |
void | setCostFunction (GKFunctionCost *fc) |
const GKPedestrianCrossing * | getPedestrianCrossingAtEnd () const |
const GKPedestrianCrossing * | getPedestrianCrossingAtBeginning () const |
GKPoints & | calculatePolylineWithoutPedestrianCrossings (GKPoints &points, uint nbpoints=0, QVector< int > *segmentsBeginPos=NULL) const |
GKPoints | calculateLanePolyline (int lane, bool keepSegments, uint nbpoints=0, QVector< int > *segmentsBeginPos=NULL) const |
GKPoints | calculateLanePolylineWithoutPedestrianCrossings (int lane, uint nbpoints=0, QVector< int > *segmentsBeginPos=NULL) const |
bool | getAutoIntermediateHeight () const |
void | setAutoIntermediateHeight (bool value) |
double | getInherentSpeed () const |
void | setInherentSpeed (double newInherentSpeed) |
void | recalculateAltitudes () |
void | autoCurveTurnings (bool curveStraightTurnings=true) |
GKPoint | getExtremePointAtPos (double pos, bool atRight) const |
GKPoints | getExtremePointsLane (uint lanepos) const |
GKObjectDelCmd * | getDelCmd () |
virtual GKGeoObjectCutCmd * | getCutCmd (const GKPoint &from, const GKPoint &to, bool keepConnection) |
bool | useRoadTypeNonAllowedVehicles () const |
void | setUseRoadTypeNonAllowedVehicles (bool value) |
QVector< const GKMobileAgent * > | getNonAllowedVehicles () const |
void | setNonAllowedVehicles (QVector< const GKMobileAgent * > vehicles) |
GKTurnings | getDestTurnings () const |
GKTurnings | getOrigTurnings () const |
GKTurnings | getOrigTurnings (int laneIndex) const |
uint | getNumExitSections () const |
uint | getNumEntranceSections () const |
QVector< GKSection * > | getExitSections () const |
QVector< GKSection * > | getEntranceSections () const |
double | getStopLine () const |
void | setStopLine (double v) |
void | updateAltitudeTurnings () |
![]() | |
GKBezierCurve () | |
void | addSegment (GKBezierCurveType type) |
void | setPoint (int s, int i, const GKPoint &p) |
void | setPoint (int i, const GKPoint &p) |
void | setCurve (const GKBezierCurve &curve) |
void | setFromSegment (const GKPoint &p1, const GKPoint &p2, GKBezierCurveType type) |
void | setFromPoints (const GKPoints &ps, GKBezierCurveType type) |
uint | getNbSegments () const |
virtual void | addCurvePointAt (int pos, const GKPoint &p) |
virtual void | removePoint (uint pos) |
virtual bool | canPointBeAdded (uint pos) const |
GKPoints | calculatePolyline (uint nbpoints=0, bool simplify=true, QVector< int > *segmentsBeginPos=NULL) const |
bool | isASegment () const |
bool | onlyContainsSegments () const |
GKBezierCurveType | getCurveType (uint pos) const |
GKCoord | length2D (uint nbpoints=0) const |
GKCoord | length3D (uint nbpoints=0) const |
GKCoord | getSegmentLength (uint pos, uint nbpoints=0) const |
GKBezierCurve | getSegment (uint pos) const |
int | getNumSegmentControlPoints (int pos) const |
GKPoint | calculateBezierPoint (float t) const |
GKVector | calculateBezierDerivative (float t) const |
GKVector | calculateBezierSecondDerivative (float t) const |
GKCoord | calculateBezierRadius (const GKPoints &p, uint nbpoints=0) const |
GKCoord | getBezierRadiusatPoint (const GKPoints &p, const GKPoint &p1, uint nbpoints=0) const |
GKCoord | MeanRadius (uint nbpoints=0) const |
bool | hit (const GKPoint &p, float epsilon) const |
virtual void | changeDirection () |
virtual void | join (const GKPolyline *pol, bool atStart) |
virtual void | removePoints (uint nbPoints, bool atStart, int &nbSegmentsRemoved) |
GKPoint | pointAtPos (float pos) const |
float | posAtPoint (const GKPoint &p, GKCoord maxDistToCurve=0.01) const |
int | segmentAtPos (GKCoord pos, double *length=NULL) const |
int | segmentAtPosComplete (const GKPoints &points, GKCoord pos, double *retLength=NULL) const |
uint | nbParts () const |
GKCoord | angleToCurve (const GKBezierCurve &curve) const |
virtual GKCoord | getAltitude () const |
virtual void | setAltitude (GKCoord value) |
![]() | |
GKPolyline () | |
uint | nbPoints () const |
const GKPoint & | getPoint (uint at) const |
void | setPoint (uint at, const GKPoint &p) |
const GKPoints & | getPoints () const |
virtual void | addPoint (const GKPoint &p) |
virtual void | addPointAt (int pos, const GKPoint &p) |
virtual void | removePoint (uint pos) |
virtual void | setPoints (const GKPoints &ps) |
virtual GKCoord | length2D () const |
virtual GKCoord | length3D () const |
virtual bool | canPointBeAdded (uint pos) const |
virtual void | join (const GKPolyline *pol, bool atStart) |
virtual void | removePoints (uint nbPoints, bool atStart) |
virtual bool | canBeJoined (const GKPolyline *pol) const |
void | prepend (const GKPoints &ps) |
void | add (const GKPoints &ps) |
void | setPointSelected (uint p, bool value) |
bool | isPointSelected (uint p) const |
void | selectAllPoints () |
void | unselectAllPoints () |
int | getNbSelPoints () const |
virtual void | changeDirection () |
GKCoord | getSlope (int segmentPos) const |
GKBBox | getBBox () const |
void | setPenColor (const QColor &color) |
virtual const QColor & | getPenColor () const |
void | setPenStyle (const Qt::PenStyle &astyle) |
const Qt::PenStyle & | getPenStyle () const |
void | setPenSize (float size) |
float | getPenSize () const |
void | setPenSizeUnits (const GK::SizeUnits &units) |
const GK::SizeUnits & | getPenSizeUnits () const |
![]() | |
GKGeoObject () | |
virtual void | setSelected (bool newState) |
virtual bool | isSelected () const |
bool | canBeModified () const |
bool | canBeEdited () const |
virtual bool | canBeGrouped () const |
int | getMark () const |
void | setMark (int newMark) |
void | addMark (int newMark) |
void | unmark () |
const QVector< int > * | getMarks () const |
uint | getNumberOfMarks () const |
GKLayer * | getLayer () const |
void | setLayer (GKLayer *alayer) |
virtual void | translate (const GKPoint &delta) |
virtual void | rotate (const GKPoint ¢er, double angle) |
virtual void | scale (const GKPoint &) |
virtual GKCoord | getAltitude () const |
virtual void | setAltitude (GKCoord value) |
void | addTopObject (GKGeoObject *) |
QSet< GKGeoObject * > * | getTopObjects () const |
GKGeoObject * | getBottomObject () const |
void | setLabeled (bool value) |
bool | isLabeled () const |
GKGeoContainer | getContainedWay (const GKPoints &points, const GKBBox &bboxPoints) const |
virtual GKGeoContainer | doGetContainedWay (const GKBBox &myBBox, const GKPoints &points, const GKBBox &bboxPoints) const |
GK::ConnectionType | objectConnectionType (const GKGeoObject *object) const |
QSet< GKObjectConnection * > | getConnections () const |
QSet< GKObjectConnection * > | getConnections (const GKGeoObject *) const |
bool | anyConnection (const GKGeoObject *) const |
virtual void | addConnection (GKObjectConnection *) |
virtual void | removeConnection (GKObjectConnection *, GK::ObjectDeletionBehaviour) |
virtual void | changeConnectionObject (GKGeoObject *oldObject, GKGeoObject *newObject, GK::ConnectionType connectionType=GK::eConnectionUndefined) |
virtual void | removeAllConnections (GK::ObjectDeletionBehaviour) |
virtual bool | acceptConnection (GKGeoObject *object) const |
virtual GKGeoObjectCutCmd * | getCutCmd (const GKPoint &from, const GKPoint &to, bool keepConnection) |
virtual bool | exists (quint32 scenarioId) const |
![]() | |
GKObject () | |
GKObject (const GKObject &o) | |
virtual void | addedToCatalog () |
virtual void | removedFromCatalog () |
uint | getTick () const |
virtual void | increaseTick () |
void | setTick (uint t) |
virtual GKObject * | clone (bool addItToModel=true) const |
virtual GKObject * | cloneAsTemporary (bool addItToModel=true) const |
GKFolder * | getCreateRootFolder () |
GKFolder * | getRootFolder () const |
void | setRootFolder (GKFolder *afolder) |
GKFolder * | findFolder (const QString &byName) const |
QVector< GKFolder * > | getParentFolders () const |
bool | isDataValueNull (const GKColumn *attr) const |
virtual QVariant * | getDataValue (const GKColumn *attr, bool *deleteit, const GKContext &context=GKContext::anyContext) const |
QVariant * | getDataValueByID (uint attrId, bool *deleteit, const GKContext &context=GKContext::anyContext) const |
virtual void | setDataValue (const GKColumn *attr, const QVariant &v) |
void | setDataValueByID (uint attrId, const QVariant &v) |
virtual void | setDataValueObject (const GKColumn *attr, const GKObject *obj) |
void | setDataValueObjectByID (uint attrId, const GKObject *obj) |
virtual void | setDataValueDouble (const GKColumn *attr, double v) |
void | setDataValueDoubleByID (uint attrId, double v) |
virtual double | getDataValueInTS (const GKColumn *attr, GKTimeSerieIndex index, double *deviation=NULL) const |
double | getDataValueInTSByID (uint attrId, GKTimeSerieIndex index, double *deviation=NULL) const |
bool | hasAnyTSWithData () const |
virtual GKTimeSerie * | getDataValueTS (const GKColumn *attr) const |
GKTimeSerie * | getDataValueTSByID (uint attrId) const |
virtual void | setDataValueInTS (const GKColumn *attr, GKTimeSerieIndex index, double value, double deviation, GKTSDescription *aDescription=NULL, int reservedSize=0) |
virtual void | setDataValueInTS (const GKColumn *attr, GKTimeSerieIndex index, double value, double deviation, double lowerValue, GKTSDescription *aDescription=NULL, int reservedSize=0) |
virtual void | setDataValueInSingleTS (const GKColumn *attr, GKTimeSerieIndex index, double value, double deviation, GKTSDescription *aDescription) |
void | setDataValueInTSByID (uint attrId, GKTimeSerieIndex index, double value, double deviation, GKTSDescription *aDescription=NULL, int reservedSize=0) |
virtual void | setAggregatedValueInTS (const GKColumn *attr, double value, double deviation, GKTSDescription *aDescription=NULL) |
void | setAggregatedValueInTSByID (uint attrId, double value, double deviation, GKTSDescription *aDescription=NULL) |
virtual void | clearDataValueTS (const GKColumn *attr, GKTSDescription *aDescription=NULL) |
void | clearDataValueTSByID (uint attrId, GKTSDescription *aDescription=NULL) |
virtual int | getDataValueInt (const GKColumn *attr, const GKContext &context=GKContext::anyContext) const |
int | getDataValueIntByID (uint attrId, const GKContext &context=GKContext::anyContext) const |
virtual double | getDataValueDouble (const GKColumn *attr, const GKContext &context=GKContext::anyContext) const |
double | getDataValueDoubleByID (uint attrId, const GKContext &context=GKContext::anyContext) const |
QString | getDataValueString (const GKColumn *attr, const GKContext &context=GKContext::anyContext) const |
QString | getDataValueStringByID (uint attrId, const GKContext &context=GKContext::anyContext) const |
virtual bool | getDataValueBool (const GKColumn *attr, const GKContext &context=GKContext::anyContext) const |
bool | getDataValueBoolByID (uint attrId, const GKContext &context=GKContext::anyContext) const |
virtual GKObject * | getDataValueObject (const GKColumn *attr, const GKContext &context=GKContext::anyContext) const |
GKObject * | getDataValueObjectByID (uint attrId, const GKContext &context=GKContext::anyContext) const |
QDate | getDataValueDate (const GKColumn *attr, const GKContext &context=GKContext::anyContext) const |
QDate | getDataValueDateByID (uint attrId, const GKContext &context=GKContext::anyContext) const |
QTime | getDataValueTime (const GKColumn *attr, const GKContext &context=GKContext::anyContext) const |
QTime | getDataValueTimeByID (uint attrId, const GKContext &context=GKContext::anyContext) const |
QDateTime | getDataValueDateTime (const GKColumn *attr, const GKContext &context=GKContext::anyContext) const |
QDateTime | getDataValueDateTimeByID (uint attrId, const GKContext &context=GKContext::anyContext) const |
GKTimeDuration | getDataValueTimeDuration (const GKColumn *attr, const GKContext &context=GKContext::anyContext) const |
GKTimeDuration | getDataValueTimeDurationByID (uint attrId, const GKContext &context=GKContext::anyContext) const |
void | removeDataValue (const GKColumn *attr) |
void | removeDataValueByID (uint attrId) |
const QString & | getDescription () const |
void | setDescription (const QString &adescription) |
const QString & | getExternalId () const |
void | setExternalId (const QString &anId) |
virtual GKObjectDelCmd * | getDelCmd () |
virtual GKObjectConnectionDelCmd * | getDelConnectionCmd (GKObject *target) |
virtual void | nonCommandObjectRemoved (GKObject *) |
virtual void | init () |
virtual void | setId (uint aid, GKModel *model) |
uint | getId () const |
QUuid | getUUID () const |
virtual void | setName (const QString &aname) |
const QString & | getName () const |
QString | getExtendedId (IdentifierForm form=eIdentifierDefault) const |
QString | getNameOrExtendedId (IdentifierForm form=eIdentifierDefault) const |
virtual const QString & | getTypeName () const |
virtual QString | getTypeExternalName () const |
const GKObject * | getMaster () const |
GKType * | getType () const |
virtual void | setType (GKType *atype) |
bool | isA (const GKType *atype) const |
bool | isA (const QString &typeName) const |
virtual void | setModel (GKModel *amodel) |
GKModel * | getModel () const |
virtual void | setLock (GKLockType atype) |
GKLockType | getLock () const |
virtual bool | canBeDeleted () const |
virtual bool | canBeModified () const |
virtual bool | canBeEdited () const |
GKObjectStatus | getStatus () const |
virtual void | setStatus (const GKObjectStatus astatus) |
void | notifyStatusChange () |
bool | isTemporary () const |
void | setTemporary (bool value) |
bool | isExternal () const |
void | setExternal (bool value) |
virtual void | preferencesChanged () |
void | removeColumn (GKColumn *column) |
void | resetColumn (GKColumn *column) |
![]() | |
GKBaseObject () | |
if (base) | |
virtual uint | getId () const =0 |
virtual const QString & | getTypeName () const =0 |
virtual QString | getTypeExternalName () const =0 |
virtual const GKObject * | getMaster () const =0 |
virtual const QString & | getName () const =0 |
virtual const QString & | getExternalId () const =0 |
virtual const QString & | getDescription () const =0 |
virtual GKModel * | getModel () const =0 |
virtual QVariant * | getDataValue (const GKColumn *attr, bool *deleteit, const GKContext &context=GKContext::anyContext) const =0 |
virtual QVariant * | getDataValueByID (uint attrId, bool *deleteit, const GKContext &context=GKContext::anyContext) const =0 |
virtual double | getDataValueInTS (const GKColumn *attr, GKTimeSerieIndex index, double *deviation=NULL) const =0 |
virtual double | getDataValueInTSByID (uint attrId, GKTimeSerieIndex index, double *deviation=NULL) const =0 |
virtual GKTimeSerie * | getDataValueTS (const GKColumn *attr) const =0 |
virtual GKTimeSerie * | getDataValueTSByID (uint attrId) const =0 |
virtual int | getDataValueInt (const GKColumn *attr, const GKContext &context=GKContext::anyContext) const =0 |
virtual int | getDataValueIntByID (uint attrId, const GKContext &context=GKContext::anyContext) const =0 |
virtual double | getDataValueDouble (const GKColumn *attr, const GKContext &context=GKContext::anyContext) const =0 |
virtual double | getDataValueDoubleByID (uint attrId, const GKContext &context=GKContext::anyContext) const =0 |
virtual QString | getDataValueString (const GKColumn *attr, const GKContext &context=GKContext::anyContext) const =0 |
virtual QString | getDataValueStringByID (uint attrId, const GKContext &context=GKContext::anyContext) const =0 |
virtual bool | getDataValueBool (const GKColumn *attr, const GKContext &context=GKContext::anyContext) const =0 |
virtual bool | getDataValueBoolByID (uint attrId, const GKContext &context=GKContext::anyContext) const =0 |
virtual GKObject * | getDataValueObject (const GKColumn *attr, const GKContext &context=GKContext::anyContext) const =0 |
virtual GKObject * | getDataValueObjectByID (uint attrId, const GKContext &context=GKContext::anyContext) const =0 |
virtual QDate | getDataValueDate (const GKColumn *attr, const GKContext &context=GKContext::anyContext) const =0 |
virtual QDate | getDataValueDateByID (uint attrId, const GKContext &context=GKContext::anyContext) const =0 |
virtual QTime | getDataValueTime (const GKColumn *attr, const GKContext &context=GKContext::anyContext) const =0 |
virtual QTime | getDataValueTimeByID (uint attrId, const GKContext &context=GKContext::anyContext) const =0 |
virtual QDateTime | getDataValueDateTime (const GKColumn *attr, const GKContext &context=GKContext::anyContext) const =0 |
virtual QDateTime | getDataValueDateTimeByID (uint attrId, const GKContext &context=GKContext::anyContext) const =0 |
virtual GKTimeDuration | getDataValueTimeDuration (const GKColumn *attr, const GKContext &context=GKContext::anyContext) const =0 |
virtual GKTimeDuration | getDataValueTimeDurationByID (uint attrId, const GKContext &context=GKContext::anyContext) const =0 |
Additional Inherited Members | |
![]() | |
ConvertToSubClassCode Py_BEGIN_ALLOW_THREADS GKBaseObject * | base = (GKBaseObject*)sipCpp |
sipType = 0 | |
We have to understand GKSection as one of the base building blocks of an Aimsun Network.
A section is a group of contiguous lanes where vehicles move in the same direction. The partition of the traffic network into sections is usually governed by the physical boundaries of the area and the existence of turn movements. In an urban network, a section corresponds closely to the road from one intersection to the next. In a freeway area, a section can be the part of the road between two ramps.
GKSection::GKSection | ( | ) |
void GKSection::addLane | ( | const GKSectionLane & | lane, |
int | lanepos = -1 |
||
) |
Add a lane to this section at position lanepos. ID lanepos is -1 (the default) the lane will be the last lane (rightmost).
void GKSection::autoCurveTurnings | ( | bool | curveStraightTurnings = true | ) |
This function recalculates the geometry of all the turns entering or leaving the current section
GKPoints GKSection::calculateLanePolyline | ( | int | lane, |
bool | keepSegments, | ||
uint | nbpoints = 0 , |
||
QVector< int > * | segmentsBeginPos = NULL |
||
) | const |
Calculates a polyline that represents the lane desired. Lanes are numbered from 0 (the leftmost one) to number of lanes -1. The polyline is calculated in "points" and "points" is also returned.
If keepSegments is true it will keep at least one point per section segment, if false it will simplify the number of points as most as possible.
If segmentsBeginPos is not NULL in this vector (one entry by segment) the start position of each segment is returned (start position in the array of calculated points).
If nbpoints is 0 then the value of GKPoints::gkDefaultBezierPoints will be used.
GKPoints GKSection::calculateLanePolylineWithoutPedestrianCrossings | ( | int | lane, |
uint | nbpoints = 0 , |
||
QVector< int > * | segmentsBeginPos = NULL |
||
) | const |
Calculates a polyline that represents the lane desired without considerings the pedestrian crossings that might be at the beginning or end of the section. Lanes are numbered from 0 (the leftmost one) to number of lanes -1. The polyline is calculated in "points" and "points" is also returned.
If segmentsBeginPos is not NULL in this vector (one entry by segment) the start position of each segment is returned (start position in the array of calculated points).
If nbpoints is 0 then the value of GKPoints::gkDefaultBezierPoints will be used.
GKPoints & GKSection::calculatePolylineWithoutPedestrianCrossings | ( | GKPoints & | points, |
uint | nbpoints = 0 , |
||
QVector< int > * | segmentsBeginPos = NULL |
||
) | const |
Calculates a polyline that represents the center line of this section without considering the pedestrian crossings the section may have at the beginning or end of the section.The polyline is calculated in "points" and "points" is also returned.
If segmentsBeginPos is not NULL in this vector (one entry by segment) the start position of each segment is returned (start position in the array of calculated points).
If nbpoints is 0 then the value of GKPoints::gkDefaultBezierPoints will be used.
bool GKSection::canUse | ( | GKVehicleClass * | v | ) | const |
Returns true if this vehicle class can use this section
bool GKSection::canUseVehicle | ( | const GKMobileAgent * | v | ) | const |
Returns true if this vehicle can use this section
|
virtual |
Changes the direction of flow of this section (in fact inverses the order of the points that defines the geometry of the section.
Reimplemented from GKBezierCurve.
void GKSection::clearSpeedDetailed | ( | ) |
Clears all the detailed speed information, if any, defined for this section.
bool GKSection::existLaneAtPos | ( | int | laneNumber, |
double | pos | ||
) | const |
Returns true if lane "lane" exists at "pos". A main lane will always return true (no check will be done for pos to enter inside the [0,length]. A side lane will return false if pos is not in the lane.
double GKSection::getAdditionalVolume | ( | ) | const |
Additional Volume
bool GKSection::getAutoIntermediateHeight | ( | ) | const |
Returns true if the height of the intermediate points will be calculated automatically or not using the GKSectionEditor. True by default.
The user can change the heights individually no matter the value of the attribute but they will be overwrite when using the editor.
|
virtual |
Gets the bounding box of this object.
double GKSection::getCapacity | ( | ) | const |
The section capacity for static assignments in PCUs.
double GKSection::getCapacityForVehicle | ( | const GKVehicle * | v, |
const GKModelConnection * | iModelConnection | ||
) | const |
Returns the section capacity for this vehicle type. When reserved lanes are defined in the section, if the vehicle is not allowed to use them, then the capacity of the not allowed lanes will not be taken into account. If the section has any lane reserved compulsory or reserved tram for the vehicle type v then the capacity will be the one defined by these reserved compulsory or tram lanes only.
|
virtual |
reimplemented from GKGeoObject
Reimplemented from GKGeoObject.
|
virtual |
|
virtual |
|
virtual |
|
virtual |
Gets a command to delete the current section
Reimplemented from GKObject.
GKNode * GKSection::getDestination | ( | ) | const |
Returns the destination node of this section (contains turns that start at this section). It can be NULL.
GKTurnings GKSection::getDestTurnings | ( | ) | const |
Returns all turns exiting this section.
GKFunctionCost * GKSection::getDynamicFunction | ( | ) | const |
Get the Dynamic Cost Function for the turn.
GKCoord GKSection::getEntranceAngle | ( | ) | const |
Returns the angle in radians that the section's first segment makes with the horizontal. The value will be between (-PI, PI)
GKCoord GKSection::getEntranceHeight | ( | ) | const |
Gets the z coordinate of the section's entrance line
GKCoord GKSection::getEntranceLineAngle | ( | ) | const |
Returns the angle in radians that the entrance line makes with the perpendicular in the section's first segment. The value will be between (-PI/2.0, PI/2.0)
QVector< GKSection * > GKSection::getEntranceSections | ( | ) | const |
Returns a vector with the entrance sections, that is the origin sections of all turns arriving to this section.
QPair< int, int > GKSection::getEntryLanes | ( | ) | const |
Returns the range of lanes (from 0 to N-1, where N is the number of lanes) that can be used to enter this section. It takes into account the laterals to discard it if needed.
GKCoord GKSection::getExitAngle | ( | ) | const |
Returns the angle in radians that the section's last segment makes with the horizontal . The value will be between (-PI, PI)
GKCoord GKSection::getExitHeight | ( | ) | const |
Gets the z coordinate of the section's exit line
QPair< int, int > GKSection::getExitLanes | ( | ) | const |
Returns the range of lanes (from 0 to N-1, where N is the number of lanes) that can be used to exit this section. It takes into account the laterals to discard it if needed.
GKCoord GKSection::getExitLineAngle | ( | ) | const |
Returns the angle in radians that the exit line makes with the perpendicular in the section's last segment . The value will be between (-PI/2.0, PI/2.0)
QVector< GKSection * > GKSection::getExitSections | ( | ) | const |
Returns a vector with the exit sections, that is the destination sections of all turns exiting from this section.
GKPoint GKSection::getExtremePointAtPos | ( | double | pos, |
bool | atRight | ||
) | const |
It returns the parallel point to the one located in the center line at pos from the beginning and at the right contour line of the section when atRight is true and at the left side otherwise. It takes into acount side lanes if any
GKPoints GKSection::getExtremePointsLane | ( | uint | lanepos | ) | const |
Returns an array of four points: 0 is the left bottom, 1 is the left top, 2 is the right top and 3 is the right bottom. Left and right using the section direction.
GKCoord GKSection::getHeightAtDistance | ( | GKCoord | dist | ) | const |
Returns the z coordinate of the section at distance dist from the beginning.
Returns the z coordinate of the section at point p where only the x and y are valid coordinates. Point p must be located in the middle line of lane nbLane, otherwise the result is unknown
GKCoord GKSection::getHeightAtPoint2D | ( | const GKPoint & | p, |
int | nbLane | ||
) | const |
Returns the z coordinate of the section at point p where only the x and y are valid coordinates. Point p must be located in the middle line of lane nbLane, otherwise the result is unknown
double GKSection::getInherentSpeed | ( | ) | const |
Returns the inherent speed of the section
GKFunctionCost * GKSection::getInitialFunction | ( | ) | const |
Get the Initial Cost Function for the turn.
GKFunctionCost * GKSection::getKInitialsFunction | ( | ) | const |
Get the K-Initials Cost Function for the turn.
GKSectionLane & GKSection::getLane | ( | uint | lanepos | ) |
Get lane (by pos). It goes from 0 to N-1 (where N is the number of lanes) 0 is the left most lane, N-1 the right most lane. Left and right using the section direction.
QVector< double > GKSection::getLaneExtraLengthAtEntrance | ( | ) | const |
Section's initial and end point are related to the section's center line. When the section's entrance line is not perpendicularto the section's first segment line, each lane can have an additional or a lower length at the beginning. This length is the one returned in this vector, for each one of the section's lanes.
QVector< double > GKSection::getLaneExtraLengthAtExit | ( | ) | const |
Section's initial and end point are related to the section's center line. When the section's exit line is not perpendicularto the section's last segment line, each lane can have an additional or a lower length at the end. This length is the one returned in this vector, for each one of the section's lanes.
GKCoord GKSection::getLaneLength2D | ( | uint | lanepos | ) | const |
Gets the 2D lane length (by position). The position input can range from 0 to N-1, where N is the number of lanes, 0 the left-most lane position and N-1 the right-most lane according to the section direction. If the position input is greater than or equal to N the function will return 0.
GKCoord GKSection::getLaneLength2DWithoutPedestrianCrossings | ( | uint | lanepos, |
bool | full = false |
||
) | const |
Gets the 2D lane length (by position) without considering the pedestrian crossing that might be defined at the beginning or end of the section. The position input can range from 0 to N-1, where N is the number of lanes, 0 the left-most lane position and N-1 the right-most lane according to the section direction. If the position input is greater than or equal to N the function will return 0.
If full is true then the length will be calculated as if the lane was a full one, ignoring any side lane offset values.
GKCoord GKSection::getLaneLength3D | ( | uint | lanepos | ) | const |
Gets the 3D lane length (by position). The position input can range from 0 to N-1, where N is the number of lanes, 0 the left-most lane position and N-1 the right-most lane according to the section direction. If the position input is greater than or equal to N the function will return 0.
GKCoord GKSection::getLaneLength3DWithoutPedestrianCrossings | ( | uint | lanepos, |
bool | full = false |
||
) | const |
Gets the 3D lane length (by position) without considering the pedestrian crossing that might be defined at the beginning or end of the section. The position input can range from 0 to N-1, where N is the number of lanes, 0 the left-most lane position and N-1 the right-most lane according to the section direction. If the position input is greater than or equal to N the function will return 0.
If full is true then the length will be calculated as if the lane was a full one, ignoring any side lane offset values.
const QVector< GKSectionLane > & GKSection::getLanes | ( | ) | const |
Get all the lanes sorted by position. It goes from 0 to N-1 (where N is the number of lanes) 0 is the left most lane, N-1 the right most lane. Left and right using the section direction.
QPair< int, int > GKSection::getLanesAtPos | ( | double | pos | ) | const |
Returns the range of lanes (from 0 to N-1, where N is the number of lanes) that exists at position pos (relative to the start of the section, pos = 0.0 means the start point, pos = length2D() means the end point of the section.
Is pos > length2D() then the function will use length2D() as position.
QPair< int, int > GKSection::getLanesAtSegment | ( | int | segment | ) | const |
Returns the range of lanes (from 0 to N-1, where N is the number of lanes) that exists at segment 'segment' (from 0 to M-1, where M is the number of segments).
GKCoord GKSection::getLanesLength2D | ( | ) | const |
Returns the sum of the section lanes' 2D length. The output may differ from multiplying the section 2D length by the number of lanes because not all lanes must necessarily have the same 2D length (e.g. lateral lanes or curved section).
GKCoord GKSection::getLanesLength3D | ( | ) | const |
Returns the sum of the section lanes' 3D length. The output may differ from multiplying the section 3D length by the number of lanes because not all lanes must necessarily have the same 3D length (e.g. lateral lanes or curved section).
double GKSection::getLaneWidth | ( | ) | const |
Default lane width of this section. Note that this information is per section and not per lane.
double GKSection::getLaneWidth | ( | uint | lanepos | ) | const |
Get the specified lane's width. The variable lanepos goes from 0 to N-1 (where N is the number of lanes): 0 is the left most lane, N-1 the right most lane. Left and right are based on the section's direction.
int GKSection::getLastSegmentNbLanes | ( | ) | const |
Returns the number of lanes that are present in the last segment of the section. that is, all the main lanes and the laterals that starts or ends in the last segment
int GKSection::getNbFullLanes | ( | ) | const |
int GKSection::getNbLanesAtPos | ( | double | pos | ) | const |
Returns the number of lanes that exists at position pos (relative to the start of the section, pos = 0.0 means the start point, pos = length2D() means the end point of the section.
Is pos > length2D() then the function will use length2D() as position.
int GKSection::getNbTurningsUsingLane | ( | int | iLane, |
sectionSide | iSide | ||
) |
Return the number of turns using this lane
QVector< const GKMobileAgent * > GKSection::getNonAllowedVehicles | ( | ) | const |
List of vehicles and pedestrian types that are not allowed in this section
uint GKSection::getNumEntranceSections | ( | ) | const |
Returns the number of entrance sections, that is the number of sections where a turn arriving to this section strats from.
uint GKSection::getNumExitSections | ( | ) | const |
Returns the number of exit sections, that is the number of sections where a turn exiting from this section goes to.
GKNode * GKSection::getOrigin | ( | ) | const |
Returns the origin node of this section (node from where turns will enter). It can be NULL.
GKTurnings GKSection::getOrigTurnings | ( | ) | const |
Returns all turns entering this section.
GKTurnings GKSection::getOrigTurnings | ( | int | laneIndex | ) | const |
Returns all turns entering this section and arriving to lane "laneIndex", where laneIndex goes from 0 to number of lanes - 1. Lane 0 is the leftmost lane in the section's direction of flow.
const GKPedestrianCrossing * GKSection::getPedestrianCrossingAtBeginning | ( | ) | const |
Crossing at the beginning of the section? Note that they are section objects and are also available as a list of top objects (GKGeoObject::getTopObjects).
const GKPedestrianCrossing * GKSection::getPedestrianCrossingAtEnd | ( | ) | const |
Crossing at the end of the section? Note that they are section objects and are also available as a list of top objects (GKGeoObject::getTopObjects).
const GKRoadType * GKSection::getRoadType | ( | ) | const |
Gets the road type of the section
GKSectionOrientation GKSection::getSectionEntranceOrientation | ( | ) | const |
Returns the section orientation taking into account the first segment and the north direction defined in Preferences. Each orientation will have a possible deviation of 45 degrees into each side, that is, all sections will be classified into the closer category
GKSectionOrientation GKSection::getSectionExitOrientation | ( | ) | const |
Returns the section orientation taking into account the last segment and the north direction defined in Preferences. Each orientation will have a possible deviation of 45 degrees into each side, that is, all sections will be classified into the closer category
double GKSection::getSpeed | ( | ) | const |
Returns the section speed.
double GKSection::getSpeedDetailed | ( | int | , |
int | |||
) |
Gets the value of a detailed speed.
double GKSection::getStopLine | ( | ) | const |
Stop Line distance from the beginning of the section (in meters) common for all lanes. Every lane can have an additional value to override it.
The distance is either 0 that means either at the beginning of the scetion of just after the crosswalk (if any). If greater than 0 is up to the user to place it after the crosswalk.
double GKSection::getUserDefinedCost | ( | ) | const |
User-defined cost
double GKSection::getUserDefinedCost2 | ( | ) | const |
User-defined cost (second one)
double GKSection::getUserDefinedCost3 | ( | ) | const |
User-defined cost (third one)
GKCoord GKSection::getWidth | ( | ) | const |
Returns the section width (computed as the sum of all lanes' width)
GKCoord GKSection::getYRotationAtDistance | ( | GKCoord | dist, |
bool | degrees | ||
) | const |
Returns the angle that the section makes with the vertical at distance dist from the beginning. This angle can be expressed in degrees (setting the parameter degrees to true) or in radians (setting degrees to false).
GKCoord GKSection::getZRotationAtDistance | ( | GKCoord | dist, |
bool | degrees | ||
) | const |
Returns the angle that the section makes with the horizontal at distance dist from the beginning. This angle can be expressed in degrees (setting the parameter degrees to true) or in radians (setting degrees to false).
bool GKSection::isConnected | ( | const GKSection * | ) | const |
Returns true is the section is connected to the section "nextSection".
|
virtual |
Join to sections in one. "pol" must be a GKSection. See GKBezierCurve::join for details.
Reimplemented from GKBezierCurve.
void GKSection::recalculateAltitudes | ( | ) |
Recalcule all the altitude coordinates of the section
void GKSection::removeLane | ( | uint | lanepos | ) |
Remove a lane by pos (see getLane() )
void GKSection::removeLastLane | ( | ) |
Remove the last lane (rightmost)
|
virtual |
Removes a point from the section. This will simplify the section (4 points section to 3 section curve, 3 section curve to a segment, if it is a segment it will be removed).
Reimplemented from GKBezierCurve.
|
virtual |
Removes nbPoints from this section. See GKBezierCurve::removePoints for details.
Reimplemented from GKPolyline.
void GKSection::setAdditionalVolume | ( | double | value | ) |
Additional Volume
void GKSection::setAutoIntermediateHeight | ( | bool | value | ) |
void GKSection::setCapacity | ( | double | value | ) |
Sets the section capacity for static assignments in PCUs.. This capacity is for the whole section and not per lane. This capacity is automatically updated when the user changes the number of lanes of a section. In this case side lanes are not considered.
If the user wants to set the section capacity using a lane capacity he/she will:
void GKSection::setCostFunction | ( | GKFunctionCost * | fc | ) |
Set the Volume Delay Cost Function for the section. DP: Named as Cost Function, only here, a refactor is needed.
|
virtual |
void GKSection::setDestination | ( | GKNode * | ) |
Sets the destination node of the section
void GKSection::setDynamicFunction | ( | GKFunctionCost * | fc | ) |
Set the Dynamic Cost Function for the turn.
void GKSection::setEntranceLineAngle | ( | GKCoord | angle | ) |
Sets the angle in radians that the entrance line makes with the perpendicular to the section's first segment. Taking as x axis the section's first segment and as y axis its perpendicular line, the angle is positive if the entrance line is located in the first and third quadrant and it is negative if the entrance line is located in the second and fourth quadrant. Correct values are (-PI/2.0, PI/2.0) . Default value is 0.0
void GKSection::setExitLineAngle | ( | GKCoord | angle | ) |
Sets the angle in radians that the exit line makes with the perpendicular to the section's last segment. Taking as x axis the section's last segment and as y axis its perpendicular line, the angle is positive if the entrance line is located in the first and third quadrant and it is negative if the entrance line is located in the second and fourth quadrant. Correct values are (-PI/2.0, PI/2.0) . Default value is 0.0
void GKSection::setInherentSpeed | ( | double | newInherentSpeed | ) |
Sets the inherent speed of the section
void GKSection::setInitialFunction | ( | GKFunctionCost * | fc | ) |
Set the Initial Cost Function for the turn.
void GKSection::setKInitialsFunction | ( | GKFunctionCost * | fc | ) |
Set the K-Initials Cost Function for the turn.
void GKSection::setLaneWidth | ( | double | width | ) |
Set the default Lane width of this section. Note that this information is per section and not per lane.
void GKSection::setLaneWidth | ( | uint | lanepos, |
double | width | ||
) |
Set the specified lane's width. lanepos goes from 0 to N-1 (where N is the number of lanes) 0 is the left most lane, N-1 the right most lane. Left and right are based on the section's direction.
void GKSection::setNonAllowedVehicles | ( | QVector< const GKMobileAgent * > | vehicles | ) |
List of vehicles and pedestrian types that are not allowed in this section
void GKSection::setOrigin | ( | GKNode * | ) |
Sets the origin node of the section
void GKSection::setRoadType | ( | const GKRoadType * | , |
bool | |||
) |
Set the road type of this section. If assignValues is true the values in the road type will be copied in the section.
void GKSection::setSpeed | ( | double | ) |
Sets the section speed.
void GKSection::setSpeedDetailed | ( | int | , |
int | , | ||
double | |||
) |
Sets information on detailed speed for a segment and/or lane. A -1 is returned when no speed as been set for the segment/lane combination.
void GKSection::setStopLine | ( | double | v | ) |
Stop Line distance from the beginning of the section (in meters) common for all lanes. Every lane can have an additional value to override it.
The distance is either 0 that means either at the beginning of the scetion of just after the crosswalk (if any). If greater than 0 is up to the user to place it after the crosswalk.
void GKSection::setUserDefinedCost | ( | double | value | ) |
User-defined cost
void GKSection::setUserDefinedCost2 | ( | double | value | ) |
User-defined cost (second one)
void GKSection::setUserDefinedCost3 | ( | double | value | ) |
User-defined cost (third one)
void GKSection::setUseRoadTypeNonAllowedVehicles | ( | bool | value | ) |
If true (the default) uses the list of non allowed vehicles from the road type If false, from the section
void GKSection::updateAltitudeTurnings | ( | ) |
Update the altitude of the Adjoining Turnings by the section extreme points.
bool GKSection::useRoadTypeNonAllowedVehicles | ( | ) | const |
If true (the default) uses the list of non allowed vehicles from the road type If false, from the section
|
static |
Acceleration Factor attribute.
|
static |
Additional volume attribute.
|
static |
Lane-changing Aggressiveness atribute.
|
static |
Capacity attribute.
|
static |
Consider Two-lane Car-following model attribute.
|
static |
Lane-changing Cooperation attribute.
|
static |
Destination node attribute.
|
static |
Dynamic Cost Function attribute.
|
static |
Functional Class attribute, from the road type.
|
static |
Maximum capacity.
|
static |
Maximum jam density (per lane).
|
static |
Maximum lane width.
|
static |
Maximum line angle.
|
static |
Maximum number of lanes.
|
static |
Maximum speed.
|
static |
Maximum visibility.
|
static |
Maximum zone.
|
static |
Minimum capacity.
|
static |
Minimum jam density (per lane).
|
static |
Minimum lane width.
|
static |
Minimum line angle.
|
static |
Minimum speed.
|
static |
Minimum visibility.
|
static |
Minimum zone.
|
static |
Maximum section slope.
|
static |
Minimum section slope.
|
static |
Has detailed speed attribute.
|
static |
Has Entry Side Lane attribute.
|
static |
Has Exit Side Lane attribute.
|
static |
Imprudent Lane Changing attribute.
|
static |
Inherent speed attribute.
|
static |
Initial Cost Function attribute.
|
static |
Jam density (per lane) attribute.
|
static |
K-Initials Cost Function attribute.
|
static |
Lane Width attribute.
|
static |
Left extra type attribute.
|
static |
Left extra width attribute.
|
static |
Look-ahead Distance attribute.
|
static |
Defines whether the section is considered as a merge/diverge starting point for HCM outputs.
|
static |
|
static |
|
static |
Number of main lanes attribute.
|
static |
Number of Lanes attribute.
|
static |
Number of Transit Lines that use this section.
|
static |
Number of signals attribute.
|
static |
Number of Traffic Management Actions Defined for this section.
|
static |
Side Lane Cooperation Distance (Micro) attribute.
|
static |
Side Lane Merge: First Vehicle On is First Vehicle Off (Micro) attribute.
|
static |
Side Lane Merging Distance (Micro) attribute.
|
static |
Origin node attribute.
|
static |
Additional Reaction Time At Stop (Micro) attribute.
|
static |
Additional Reaction Time At Traffic Light (Micro) attribute.
|
static |
Reaction Time Factor (Meso) attribute.
|
static |
Reaction Time Variation (Micro) attribute.
|
static |
Visibility Distance for this section reserved lanes, if any, for the dynamic simulators in m (GKColumn::Double).
|
static |
Return to curbside lane after Overtaking attribute.
|
static |
Right extra type attribute.
|
static |
Right extra width attribute.
|
static |
Road type attribute.
|
static |
Penalise Shared Lanes attribute.
|
static |
Take into Account Fast/Slow Lanes attribute.
|
static |
Speed attribute.
|
static |
Number of Traffic Conditions Defined for this section.
|
static |
Two-way overtaking: mirror section attribute.
|
static |
Two-way overtaking: speed difference to overtake solid line attribute
|
static |
Two-way overtaking: visibility distance attribute.
|
static |
Two-way overtaking: visibility factor attribute.
|
static |
Reservation Type (GKLaneType) attribute.
|
static |
Second User-defined Cost attribute.
|
static |
Third User-defined Cost attribute.
|
static |
User-defined Cost attribute.
|
static |
Use Road Type Settings for Prohibited Vehicle and Pedestrian Types attribute.
|
static |
Volume Delay Function attribute.
|
static |
Defines whether the section is considered as a weaving for HCM outputs