Eclipse SUMO - Simulation of Urban MObility
GNEConnection.cpp
Go to the documentation of this file.
1 /****************************************************************************/
2 // Eclipse SUMO, Simulation of Urban MObility; see https://eclipse.org/sumo
3 // Copyright (C) 2001-2019 German Aerospace Center (DLR) and others.
4 // This program and the accompanying materials
5 // are made available under the terms of the Eclipse Public License v2.0
6 // which accompanies this distribution, and is available at
7 // http://www.eclipse.org/legal/epl-v20.html
8 // SPDX-License-Identifier: EPL-2.0
9 /****************************************************************************/
14 // A class for visualizing connections between lanes
15 /****************************************************************************/
16 
17 
18 // ===========================================================================
19 // included modules
20 // ===========================================================================
21 #include <config.h>
22 
26 #include <utils/gui/div/GLHelper.h>
31 #include <netedit/GNENet.h>
32 #include <netedit/GNEUndoList.h>
33 #include <netedit/GNEViewNet.h>
35 
36 #include "GNEConnection.h"
37 #include "GNEJunction.h"
38 #include "GNEEdge.h"
39 #include "GNELane.h"
40 #include "GNEInternalLane.h"
41 
42 
43 // ===========================================================================
44 // static member definitions
45 // ===========================================================================
46 int NUM_POINTS = 5;
47 
48 // ===========================================================================
49 // method definitions
50 // ===========================================================================
51 
53  GNENetElement(from->getNet(), "from" + from->getMicrosimID() + "to" + to->getMicrosimID(),
55  myFromLane(from),
56  myToLane(to),
57  myLinkState(LINKSTATE_TL_OFF_NOSIGNAL),
58  mySpecialColor(nullptr),
59  myShapeDeprecated(true) {
60 }
61 
62 
64 }
65 
66 
67 std::string
69  // currently unused
70  return "";
71 }
72 
73 
74 const PositionVector&
76  if (myConnectionGeometry.getShape().size() > 0) {
78  } else {
80  }
81 }
82 
83 
84 void
86  // Get shape of from and to lanes
88  if (myShapeDeprecated) {
89  // obtain lane shape from
90  PositionVector laneShapeFrom;
91  if ((int)getEdgeFrom()->getNBEdge()->getLanes().size() > nbCon.fromLane) {
92  laneShapeFrom = getEdgeFrom()->getNBEdge()->getLanes().at(nbCon.fromLane).shape;
93  } else {
94  return;
95  }
96  // obtain lane shape to
97  PositionVector laneShapeTo;
98  if ((int)nbCon.toEdge->getLanes().size() > nbCon.toLane) {
99  laneShapeTo = nbCon.toEdge->getLanes().at(nbCon.toLane).shape;
100  } else {
101  return;
102  }
103  // Calculate shape of connection depending of the size of Junction shape
104  // value obtanied from GNEJunction::drawgl
105  if (nbCon.customShape.size() != 0) {
107  } else if (getEdgeFrom()->getNBEdge()->getToNode()->getShape().area() > 4) {
108  if (nbCon.shape.size() != 0) {
109  PositionVector connectionShape = nbCon.shape;
110  // only append via shape if it exists
111  if (nbCon.haveVia) {
112  connectionShape.append(nbCon.viaShape);
113  }
114  myConnectionGeometry.updateGeometryShape(connectionShape);
115  } else {
116  // Calculate shape so something can be drawn immidiately
117  myConnectionGeometry.updateGeometryShape(getEdgeFrom()->getNBEdge()->getToNode()->computeSmoothShape(
118  laneShapeFrom, laneShapeTo, NUM_POINTS,
119  getEdgeFrom()->getNBEdge()->getTurnDestination() == nbCon.toEdge,
120  (double) 5. * (double) getEdgeFrom()->getNBEdge()->getNumLanes(),
121  (double) 5. * (double) nbCon.toEdge->getNumLanes()));
122  }
123  } else {
124  myConnectionGeometry.updateGeometryShape({laneShapeFrom.positionAtOffset(MAX2(0.0, laneShapeFrom.length() - 1)),
125  laneShapeTo.positionAtOffset(MIN2(1.0, laneShapeFrom.length()))});
126  }
127  // check if internal junction marker must be calculated
128  if (nbCon.haveVia && (nbCon.shape.size() != 0)) {
129  // create marker for interal junction waiting position (contPos)
130  const double orthoLength = 0.5;
131  Position pos = nbCon.shape.back();
132  myInternalJunctionMarker = nbCon.shape.getOrthogonal(pos, 10, true, 0.1);
133  if (myInternalJunctionMarker.length() < orthoLength) {
135  }
136  } else {
137  myInternalJunctionMarker.clear();
138  }
139  // mark connection as non-deprecated
140  myShapeDeprecated = false;
141  }
142 }
143 
144 
145 Position
147  // currently unused
148  return Position(0, 0);
149 }
150 
151 
152 Boundary
154  if (myConnectionGeometry.getShape().size() == 0) {
155  // we need to use the center of junction parent as boundary if shape is empty
156  Position junctionParentPosition = myFromLane->getParentEdge()->getGNEJunctionDestiny()->getPositionInView();
157  return Boundary(junctionParentPosition.x() - 0.1, junctionParentPosition.y() - 0.1,
158  junctionParentPosition.x() + 0.1, junctionParentPosition.x() + 0.1);
159  } else {
161  }
162 }
163 
164 
165 GNEEdge*
167  return myFromLane->getParentEdge();
168 }
169 
170 
171 GNEEdge*
173  return myToLane->getParentEdge();
174 }
175 
176 
177 GNELane*
179  return myFromLane;
180 }
181 
182 
183 GNELane*
185  return myToLane;
186 }
187 
188 
189 int
191  return myFromLane->getIndex();
192 }
193 
194 
195 int
197  return myToLane->getIndex();
198 }
199 
200 
204 }
205 
206 
210  return NBConnection(getEdgeFrom()->getNBEdge(), getFromLaneIndex(),
211  getEdgeTo()->getNBEdge(), getToLaneIndex(),
212  (int)c.tlLinkIndex, (int)c.tlLinkIndex2);
213 }
214 
215 
216 void
219 }
220 
221 
222 LinkState
224  return myLinkState;
225 }
226 
227 
228 void
230  myShapeDeprecated = true;
231 }
232 
233 
234 void
238  nbCon.toEdge,
239  nbCon.fromLane,
240  nbCon.toLane,
241  nbCon.mayDefinitelyPass,
242  nbCon.tlID);
243 }
244 
245 
248  GUIGLObjectPopupMenu* ret = new GUIGLObjectPopupMenu(app, parent, *this);
249  buildPopupHeader(ret, app);
252  // build selection and show parameters menu
255  // build position copy entry
256  buildPositionCopyEntry(ret, false);
257  // check if we're in supermode network
259  // create menu commands
260  FXMenuCommand* mcCustomShape = new FXMenuCommand(ret, "Set custom connection shape", nullptr, &parent, MID_GNE_CONNECTION_EDIT_SHAPE);
261  // check if menu commands has to be disabled
263  // check if we're in the correct edit mode
264  if ((editMode == GNE_NMODE_CONNECT) || (editMode == GNE_NMODE_TLS) || (editMode == GNE_NMODE_CREATE_EDGE)) {
265  mcCustomShape->disable();
266  }
267  }
268  return ret;
269 }
270 
271 
272 Boundary
274  Boundary b = getBoundary();
275  b.grow(20);
276  return b;
277 }
278 
279 
280 void
282  // declare a flag to check if shape has to be draw
283  bool drawConnection = true;
286  drawConnection = !myShapeDeprecated;
289  drawConnection = !myShapeDeprecated;
290  } else {
291  drawConnection = false;
292  }
293  // Check if connection must be drawed
294  if (drawConnection) {
295  // check if boundary has to be drawn
296  if (s.drawBoundaries) {
298  }
299  // Push draw matrix 1
300  glPushMatrix();
301  // Push name
302  glPushName(getGlID());
303  // Traslate matrix
304  glTranslated(0, 0, GLO_JUNCTION + 0.1); // must draw on top of junction
305  // Set color
306  if (drawUsingSelectColor()) {
307  // override with special colors (unless the color scheme is based on selection)
309  } else if (mySpecialColor != nullptr) {
311  } else {
312  // Set color depending of the link state
314  }
315  // draw connection checking whether it is not too small if isn't being drawn for selecting
316  const double selectionScale = isAttributeCarrierSelected() ? s.selectionScale : 1;
317  if ((s.scale * selectionScale < 5.) && !s.drawForRectangleSelection) {
318  // If it's small, draw a simple line
320  } else {
321  // draw a list of lines
322  const bool spreadSuperposed = s.scale >= 1 && s.spreadSuperposed && myFromLane->drawAsRailway(s) && getEdgeFrom()->getNBEdge()->isBidiRail();
323  PositionVector shapeSuperposed = myConnectionGeometry.getShape();
324  if (spreadSuperposed) {
325  shapeSuperposed.move2side(0.5);
326  }
328  glTranslated(0, 0, 0.1);
329  GLHelper::setColor(GLHelper::getColor().changedBrightness(51));
330  // check if internal junction marker has to be drawn
331  if (myInternalJunctionMarker.size() > 0) {
333  }
334  // check if dotted contour has to be drawn (not useful at high zoom)
335  if (myNet->getViewNet()->getDottedAC() == this) {
336  GLHelper::drawShapeDottedContourAroundShape(s, getType(), shapeSuperposed, 0.25);
337  }
338  }
339  // Pop draw matrix 1
340  glPopMatrix();
341 
342  if (s.edgeValue.show) {
344  std::string value = nbCon.getParameter(s.edgeParam, "");
345  if (value != "") {
346  int shapeIndex = (int)myConnectionGeometry.getShape().size() / 2;
347  Position p = (myConnectionGeometry.getShape().size() == 2
348  ? (myConnectionGeometry.getShape().front() * 0.67 + myConnectionGeometry.getShape().back() * 0.33)
349  : myConnectionGeometry.getShape()[shapeIndex]);
350  GLHelper::drawTextSettings(s.edgeValue, value, p, s.scale, 0);
351  }
352  }
353 
354  // Pop name
355  glPopName();
356  }
357 }
358 
359 
360 void
362  mySpecialColor = color;
363 }
364 
365 std::string
367  if (key == SUMO_ATTR_ID) {
368  // used by GNEReferenceCounter
369  // @note: may be called for connections without a valid nbCon reference
370  return getMicrosimID();
371  }
373  switch (key) {
374  case SUMO_ATTR_FROM:
375  return getEdgeFrom()->getID();
376  case SUMO_ATTR_TO:
377  return nbCon.toEdge->getID();
378  case SUMO_ATTR_FROM_LANE:
379  return toString(nbCon.toLane);
380  case SUMO_ATTR_TO_LANE:
381  return toString(nbCon.toLane);
382  case SUMO_ATTR_PASS:
383  return toString(nbCon.mayDefinitelyPass);
385  return toString(nbCon.keepClear);
386  case SUMO_ATTR_CONTPOS:
387  return toString(nbCon.contPos);
389  return toString(nbCon.uncontrolled);
391  return toString(nbCon.visibility);
393  return toString(nbCon.tlLinkIndex);
395  return toString(nbCon.tlLinkIndex2);
396  case SUMO_ATTR_ALLOW:
397  if (nbCon.permissions == SVC_UNSPECIFIED) {
398  return getVehicleClassNames(nbCon.toEdge->getLanes()[nbCon.toLane].permissions);
399  } else {
400  return getVehicleClassNames(nbCon.permissions);
401  }
402  case SUMO_ATTR_DISALLOW:
403  if (nbCon.permissions == SVC_UNSPECIFIED) {
404  return getVehicleClassNames(invertPermissions(nbCon.toEdge->getLanes()[nbCon.toLane].permissions));
405  } else {
407  }
408  case SUMO_ATTR_SPEED:
409  return toString(nbCon.speed);
410  case SUMO_ATTR_DIR:
411  return toString(getEdgeFrom()->getNBEdge()->getToNode()->getDirection(
412  getEdgeFrom()->getNBEdge(), nbCon.toEdge, OptionsCont::getOptions().getBool("lefthand")));
413  case SUMO_ATTR_STATE:
414  return toString(getEdgeFrom()->getNBEdge()->getToNode()->getLinkState(
415  getEdgeFrom()->getNBEdge(), nbCon.toEdge, nbCon.fromLane, nbCon.toLane, nbCon.mayDefinitelyPass, nbCon.tlID));
417  return toString(nbCon.customShape);
418  case GNE_ATTR_SELECTED:
420  case GNE_ATTR_PARAMETERS:
421  return nbCon.getParametersStr();
422  default:
423  throw InvalidArgument(getTagStr() + " doesn't have an attribute of type '" + toString(key) + "'");
424  }
425 }
426 
427 
428 void
429 GNEConnection::setAttribute(SumoXMLAttr key, const std::string& value, GNEUndoList* undoList) {
431  switch (key) {
432  case SUMO_ATTR_FROM:
433  case SUMO_ATTR_TO:
434  case SUMO_ATTR_FROM_LANE:
435  case SUMO_ATTR_TO_LANE:
436  case SUMO_ATTR_PASS:
438  case SUMO_ATTR_CONTPOS:
441  case SUMO_ATTR_ALLOW:
442  case SUMO_ATTR_DISALLOW:
443  case SUMO_ATTR_SPEED:
445  case GNE_ATTR_SELECTED:
446  case GNE_ATTR_PARAMETERS:
447  // no special handling
448  undoList->p_add(new GNEChange_Attribute(this, myNet, key, value));
449  break;
451  if (isAttributeEnabled(SUMO_ATTR_TLLINKINDEX) && (value != getAttribute(key))) {
452  changeTLIndex(key, parse<int>(value), c.tlLinkIndex2, undoList);
453  }
454  break;
456  if (isAttributeEnabled(SUMO_ATTR_TLLINKINDEX) && (value != getAttribute(key))) {
457  changeTLIndex(key, c.tlLinkIndex, parse<int>(value), undoList);
458  }
459  break;
460  case SUMO_ATTR_DIR:
461  throw InvalidArgument("Attribute of '" + toString(key) + "' cannot be modified");
462  case SUMO_ATTR_STATE:
463  throw InvalidArgument("Attribute of '" + toString(key) + "' cannot be modified");
464  default:
465  throw InvalidArgument(getTagStr() + " doesn't have an attribute of type '" + toString(key) + "'");
466  }
467 }
468 
469 
470 void
471 GNEConnection::changeTLIndex(SumoXMLAttr key, int tlIndex, int tlIndex2, GNEUndoList* undoList) {
472  // trigger GNEChange_TLS
473  undoList->p_begin("change tls linkIndex for connection");
474  // make a copy
475  std::set<NBTrafficLightDefinition*> defs = getEdgeFrom()->getNBEdge()->getToNode()->getControllingTLS();
476  for (NBTrafficLightDefinition* tlDef : defs) {
477  NBLoadedSUMOTLDef* sumoDef = dynamic_cast<NBLoadedSUMOTLDef*>(tlDef);
478  NBTrafficLightLogic* tllogic = sumoDef ? sumoDef->getLogic() : tlDef->compute(OptionsCont::getOptions());
479  if (tllogic != nullptr) {
480  NBLoadedSUMOTLDef* newDef = new NBLoadedSUMOTLDef(tlDef, tllogic);
481  newDef->addConnection(getEdgeFrom()->getNBEdge(), getEdgeTo()->getNBEdge(),
482  getLaneFrom()->getIndex(), getLaneTo()->getIndex(), tlIndex, tlIndex2, false);
483  // iterate over NBNodes
484  for (NBNode* node : tlDef->getNodes()) {
485  GNEJunction* junction = getNet()->retrieveJunction(node->getID());
486  undoList->add(new GNEChange_TLS(junction, tlDef, false), true);
487  undoList->add(new GNEChange_TLS(junction, newDef, true), true);
488  }
489  } else {
490  WRITE_ERROR("Could not set attribute '" + toString(key) + "' (tls is broken)");
491  }
492  }
493  undoList->p_end();
494 }
495 
496 bool
497 GNEConnection::isValid(SumoXMLAttr key, const std::string& value) {
498  // Currently ignored before implementation to avoid warnings
499  switch (key) {
500  case SUMO_ATTR_FROM:
501  case SUMO_ATTR_TO:
502  case SUMO_ATTR_FROM_LANE:
503  case SUMO_ATTR_TO_LANE:
504  return false;
505  case SUMO_ATTR_PASS:
506  return canParse<bool>(value);
508  return canParse<bool>(value);
509  case SUMO_ATTR_CONTPOS:
510  return canParse<double>(value) && (parse<double>(value) >= -1);
512  return canParse<bool>(value);
514  return canParse<double>(value) && (parse<double>(value) >= -1);
518  (getNBEdgeConnection().uncontrolled == false) &&
519  (getEdgeFrom()->getNBEdge()->getToNode()->getControllingTLS().size() > 0) &&
520  canParse<int>(value) &&
521  (parse<int>(value) >= 0 || parse<int>(value) == -1)) {
522  // obtan Traffic light definition
524  return def->getMaxValidIndex() >= parse<int>(value);
525  } else {
526  return false;
527  }
528  case SUMO_ATTR_ALLOW:
529  case SUMO_ATTR_DISALLOW:
530  return canParseVehicleClasses(value);
531  case SUMO_ATTR_SPEED:
532  return canParse<double>(value) && (parse<double>(value) >= -1);
533  case SUMO_ATTR_CUSTOMSHAPE: {
534  // empty custom shapes are allowed
535  return canParse<PositionVector>(value);
536  }
537  case SUMO_ATTR_STATE:
538  return false;
539  case SUMO_ATTR_DIR:
540  return false;
541  case GNE_ATTR_SELECTED:
542  return canParse<bool>(value);
543  case GNE_ATTR_PARAMETERS:
544  return Parameterised::areParametersValid(value);
545  default:
546  throw InvalidArgument(getTagStr() + " doesn't have an attribute of type '" + toString(key) + "'");
547  }
548 }
549 
550 
551 bool
553  switch (key) {
554  case SUMO_ATTR_FROM:
555  case SUMO_ATTR_TO:
556  case SUMO_ATTR_FROM_LANE:
557  case SUMO_ATTR_TO_LANE:
558  case SUMO_ATTR_DIR:
559  case SUMO_ATTR_STATE:
560  // this attributes cannot be edited
561  return false;
564  // get Traffic Light definitions
565  if (getEdgeFrom()->getNBEdge()->getToNode()->isTLControlled()) {
567  NBLoadedSUMOTLDef* sumoDef = dynamic_cast<NBLoadedSUMOTLDef*>(tlDef);
568  NBTrafficLightLogic* tllogic = sumoDef != nullptr ? sumoDef->getLogic() : tlDef->compute(OptionsCont::getOptions());
569  if (tllogic != nullptr) {
570  return true;
571  } else {
572  return false;
573  }
574  }
575  return false;
576  default:
577  return true;
578  }
579 }
580 
581 // ===========================================================================
582 // private
583 // ===========================================================================
584 
585 void
586 GNEConnection::setAttribute(SumoXMLAttr key, const std::string& value) {
588  switch (key) {
589  case SUMO_ATTR_PASS:
590  nbCon.mayDefinitelyPass = parse<bool>(value);
591  break;
593  nbCon.keepClear = parse<bool>(value);
594  break;
596  nbCon.uncontrolled = parse<bool>(value);
597  break;
598  case SUMO_ATTR_CONTPOS:
599  nbCon.contPos = parse<double>(value);
600  break;
602  nbCon.visibility = parse<double>(value);
603  break;
604  case SUMO_ATTR_SPEED:
605  nbCon.speed = parse<double>(value);
606  break;
607  case SUMO_ATTR_ALLOW: {
608  const SVCPermissions successorAllows = nbCon.toEdge->getLanes()[nbCon.toLane].permissions;
609  SVCPermissions customPermissions = parseVehicleClasses(value);
610  if (successorAllows != customPermissions) {
611  nbCon.permissions = customPermissions;
612  }
613  break;
614  }
615  case SUMO_ATTR_DISALLOW: {
616  const SVCPermissions successorDisallows = invertPermissions(nbCon.toEdge->getLanes()[nbCon.toLane].permissions);
617  SVCPermissions customPermissions = invertPermissions(parseVehicleClasses(value));
618  if (successorDisallows != customPermissions) {
619  nbCon.permissions = customPermissions;
620  }
621  break;
622  }
623  case SUMO_ATTR_STATE:
624  throw InvalidArgument("Attribute of '" + toString(key) + "' cannot be modified");
625  case SUMO_ATTR_DIR:
626  throw InvalidArgument("Attribute of '" + toString(key) + "' cannot be modified");
627  case SUMO_ATTR_CUSTOMSHAPE: {
628  nbCon.customShape = parse<PositionVector>(value);
629  break;
630  }
631  case GNE_ATTR_SELECTED:
632  if (parse<bool>(value)) {
634  } else {
636  }
637  break;
638  case GNE_ATTR_PARAMETERS:
639  nbCon.setParametersStr(value);
640  break;
641  default:
642  throw InvalidArgument(getTagStr() + " doesn't have an attribute of type '" + toString(key) + "'");
643  }
644  // Update Geometry after setting a new attribute (but avoided for certain attributes)
645  if ((key != SUMO_ATTR_ID) && (key != GNE_ATTR_PARAMETERS) && (key != GNE_ATTR_SELECTED)) {
647  updateGeometry();
648  }
649 }
650 
651 /****************************************************************************/
GUIGlObject::getType
GUIGlObjectType getType() const
Returns the type of the object as coded in GUIGlObjectType.
Definition: GUIGlObject.cpp:180
NBEdge::Connection::tlID
std::string tlID
The id of the traffic light that controls this connection.
Definition: NBEdge.h:218
GNEConnection::isValid
bool isValid(SumoXMLAttr key, const std::string &value)
Definition: GNEConnection.cpp:497
GLO_CONNECTION
@ GLO_CONNECTION
a connection
Definition: GUIGlObjectTypes.h:54
GNEJunction::getPositionInView
Position getPositionInView() const
Returns position of hierarchical element in view.
Definition: GNEJunction.cpp:122
GNEConnection::mySpecialColor
const RGBColor * mySpecialColor
optional special color
Definition: GNEConnection.h:173
GNEConnection::changeTLIndex
void changeTLIndex(SumoXMLAttr key, int tlIndex, int tlIndex2, GNEUndoList *undoList)
manage change of tlLinkindices
Definition: GNEConnection.cpp:471
SVC_UNSPECIFIED
const SVCPermissions SVC_UNSPECIFIED
permissions not specified
Definition: SUMOVehicleClass.cpp:148
NBEdge::Connection::toEdge
NBEdge * toEdge
The edge the connections yields in.
Definition: NBEdge.h:212
GNENetElement::unselectAttributeCarrier
void unselectAttributeCarrier(bool changeFlag=true)
unselect attribute carrier using GUIGlobalSelection
Definition: GNENetElement.cpp:99
GLHelper::drawTextSettings
static void drawTextSettings(const GUIVisualizationTextSettings &settings, const std::string &text, const Position &pos, const double scale, const double angle=0, const double layer=2048)
Definition: GLHelper.cpp:706
GLHelper::getColor
static RGBColor getColor()
gets the gl-color
Definition: GLHelper.cpp:627
MIN2
T MIN2(T a, T b)
Definition: StdDefs.h:73
NBTrafficLightDefinition::compute
NBTrafficLightLogic * compute(OptionsCont &oc)
Computes the traffic light logic.
Definition: NBTrafficLightDefinition.cpp:106
Parameterised::getParametersStr
std::string getParametersStr() const
Returns the inner key/value map in string format "key1=value1|key2=value2|...|keyN=valueN".
Definition: Parameterised.cpp:112
GUIVisualizationSettings::edgeParam
std::string edgeParam
key for coloring by edge parameter
Definition: GUIVisualizationSettings.h:482
GNEConnection::updateGeometry
void updateGeometry()
update pre-computed geometry information
Definition: GNEConnection.cpp:85
NBNode::getLinkState
LinkState getLinkState(const NBEdge *incoming, NBEdge *outgoing, int fromLane, int toLane, bool mayDefinitelyPass, const std::string &tlID) const
get link state
Definition: NBNode.cpp:2011
NBEdge::Connection::haveVia
bool haveVia
check if Connection have a Via
Definition: NBEdge.h:257
GNEAttributeCarrier::getID
const std::string getID() const
function to support debugging
Definition: GNEAttributeCarrier.cpp:1289
SUMO_ATTR_DISALLOW
@ SUMO_ATTR_DISALLOW
Definition: SUMOXMLDefinitions.h:783
NBTrafficLightDefinition::getMaxValidIndex
virtual int getMaxValidIndex()
Returns the maximum index controlled by this traffic light.
Definition: NBTrafficLightDefinition.h:356
GNEGeometry::Geometry::updateGeometryShape
void updateGeometryShape(const PositionVector &shape, double startPos=-1, double endPos=-1, const Position &extraFirstPosition=Position::INVALID, const Position &extraLastPosition=Position::INVALID)
update geometry shape
Definition: GNEGeometry.cpp:48
GUISUMOAbstractView
Definition: GUISUMOAbstractView.h:72
GNEInternalLane.h
LINKSTATE_TL_OFF_NOSIGNAL
@ LINKSTATE_TL_OFF_NOSIGNAL
The link is controlled by a tls which is off, not blinking, may pass.
Definition: SUMOXMLDefinitions.h:1153
GNEUndoList::p_end
void p_end()
End undo command sub-group. If the sub-group is still empty, it will be deleted; otherwise,...
Definition: GNEUndoList.cpp:79
NBEdge::Connection::uncontrolled
bool uncontrolled
check if Connection is uncontrolled
Definition: NBEdge.h:275
GUIVisualizationSettings::drawForRectangleSelection
bool drawForRectangleSelection
whether drawing is performed for the purpose of selecting objects using a rectangle
Definition: GUIVisualizationSettings.h:647
GNELane::getParentEdge
GNEEdge * getParentEdge() const
Returns underlying parent edge.
Definition: GNELane.cpp:1371
OptionsCont.h
GUIVisualizationSettings::drawBoundaries
bool drawBoundaries
enable or disable draw boundaries
Definition: GUIVisualizationSettings.h:638
GLHelper::drawBoxLines
static void drawBoxLines(const PositionVector &geom, const std::vector< double > &rots, const std::vector< double > &lengths, double width, int cornerDetail=0, double offset=0)
Draws thick lines.
Definition: GLHelper.cpp:182
GNEGeometry::Geometry::getShapeLengths
const std::vector< double > & getShapeLengths() const
The lengths of the single shape parts.
Definition: GNEGeometry.cpp:159
NUM_POINTS
int NUM_POINTS
Definition: GNEConnection.cpp:46
SUMO_ATTR_TO_LANE
@ SUMO_ATTR_TO_LANE
Definition: SUMOXMLDefinitions.h:720
NBEdge::Connection::permissions
SVCPermissions permissions
List of vehicle types that are allowed on this connection.
Definition: NBEdge.h:245
SUMO_ATTR_CUSTOMSHAPE
@ SUMO_ATTR_CUSTOMSHAPE
whether a given shape is user-defined
Definition: SUMOXMLDefinitions.h:702
GUIGLObjectPopupMenu.h
NBEdge::Connection::contPos
double contPos
custom position for internal junction on this connection
Definition: NBEdge.h:233
GNEConnection::getLinkState
LinkState getLinkState() const
get LinkState
Definition: GNEConnection.cpp:223
NBEdge::isBidiRail
bool isBidiRail(bool ignoreSpread=false) const
whether this edge is part of a bidirectional railway
Definition: NBEdge.cpp:691
GNEConnection::myFromLane
GNELane * myFromLane
incoming lane of this connection
Definition: GNEConnection.h:164
OptionsCont::getBool
bool getBool(const std::string &name) const
Returns the boolean-value of the named option (only for Option_Bool)
Definition: OptionsCont.cpp:222
OptionsCont::getOptions
static OptionsCont & getOptions()
Retrieves the options.
Definition: OptionsCont.cpp:57
SUMO_ATTR_SPEED
@ SUMO_ATTR_SPEED
Definition: SUMOXMLDefinitions.h:384
PositionVector::extrapolate
void extrapolate(const double val, const bool onlyFirst=false, const bool onlyLast=false)
extrapolate position vector
Definition: PositionVector.cpp:1042
SUMO_ATTR_VISIBILITY_DISTANCE
@ SUMO_ATTR_VISIBILITY_DISTANCE
foe visibility distance of a link
Definition: SUMOXMLDefinitions.h:710
SUMO_ATTR_ID
@ SUMO_ATTR_ID
Definition: SUMOXMLDefinitions.h:378
PositionVector::length
double length() const
Returns the length.
Definition: PositionVector.cpp:484
GNEConnection::generateChildID
std::string generateChildID(SumoXMLTag childTag)
gererate a new ID for an element child
Definition: GNEConnection.cpp:68
GLHelper.h
NBLoadedSUMOTLDef::getLogic
NBTrafficLightLogic * getLogic()
Returns the internal logic.
Definition: NBLoadedSUMOTLDef.h:122
GNE_NMODE_CREATE_EDGE
@ GNE_NMODE_CREATE_EDGE
mode for creating new edges
Definition: GNEViewNetHelper.h:64
GNEConnection::setAttribute
void setAttribute(SumoXMLAttr key, const std::string &value, GNEUndoList *undoList)
Definition: GNEConnection.cpp:429
GNE_NMODE_TLS
@ GNE_NMODE_TLS
mode for editing tls
Definition: GNEViewNetHelper.h:68
NBEdge::Connection::tlLinkIndex
int tlLinkIndex
The index of this connection within the controlling traffic light.
Definition: NBEdge.h:221
GNENetElement::drawUsingSelectColor
bool drawUsingSelectColor() const
check if attribute carrier must be drawn using selecting color.
Definition: GNENetElement.cpp:120
GUIVisualizationColorSettings::selectedConnectionColor
RGBColor selectedConnectionColor
connection selection color
Definition: GUIVisualizationSettings.h:138
GNEConnection::getEdgeTo
GNEEdge * getEdgeTo() const
get the name of the edge the vehicles may reach when leaving "from"
Definition: GNEConnection.cpp:172
PositionVector
A list of positions.
Definition: PositionVector.h:45
GUIGLObjectPopupMenu
The popup menu of a globject.
Definition: GUIGLObjectPopupMenu.h:47
NBLoadedSUMOTLDef::addConnection
void addConnection(NBEdge *from, NBEdge *to, int fromLane, int toLane, int linkIndex, int linkIndex2, bool reconstruct=true)
Adds a connection and immediately informs the edges.
Definition: NBLoadedSUMOTLDef.cpp:95
GLHelper::setColor
static void setColor(const RGBColor &c)
Sets the gl-color to this value.
Definition: GLHelper.cpp:621
GNEConnection::getPopUpMenu
GUIGLObjectPopupMenu * getPopUpMenu(GUIMainWindow &app, GUISUMOAbstractView &parent)
Returns an own popup-menu.
Definition: GNEConnection.cpp:247
PositionVector::getBoxBoundary
Boundary getBoxBoundary() const
Returns a boundary enclosing this list of lines.
Definition: PositionVector.cpp:390
GNEConnection::getLaneFrom
GNELane * getLaneFrom() const
@briefthe get lane of the incoming lane
Definition: GNEConnection.cpp:178
SUMO_ATTR_DIR
@ SUMO_ATTR_DIR
The abstract direction of a link.
Definition: SUMOXMLDefinitions.h:706
SumoXMLTag
SumoXMLTag
Numbers representing SUMO-XML - element names.
Definition: SUMOXMLDefinitions.h:41
GNELane::drawAsRailway
bool drawAsRailway(const GUIVisualizationSettings &s) const
whether to draw this lane as a railway
Definition: GNELane.cpp:1222
NBEdge::Connection::fromLane
int fromLane
The lane the connections starts at.
Definition: NBEdge.h:209
Parameterised::getParameter
const std::string getParameter(const std::string &key, const std::string &defaultValue="") const
Returns the value for a given key.
Definition: Parameterised.cpp:72
GLHelper::drawBoundary
static void drawBoundary(const Boundary &b)
Draw a boundary (used for debugging)
Definition: GLHelper.cpp:817
GUIAppEnum.h
GNEJunction.h
SUMO_ATTR_TO
@ SUMO_ATTR_TO
Definition: SUMOXMLDefinitions.h:640
GNELane::getIndex
int getIndex() const
returns the index of the lane
Definition: GNELane.cpp:774
NBEdge::Connection::speed
double speed
custom speed for connection
Definition: NBEdge.h:239
MAX2
T MAX2(T a, T b)
Definition: StdDefs.h:79
GNEEdge
A road/street connecting two junctions (netedit-version)
Definition: GNEEdge.h:51
GNEAttributeCarrier::GNEChange_Attribute
friend class GNEChange_Attribute
declare friend class
Definition: GNEAttributeCarrier.h:57
GNEUndoList::p_add
void p_add(GNEChange_Attribute *cmd)
special method, avoid empty changes, always execute
Definition: GNEUndoList.cpp:131
NBEdge::Connection::toLane
int toLane
The lane the connections yields in.
Definition: NBEdge.h:215
parseVehicleClasses
SVCPermissions parseVehicleClasses(const std::string &allowedS)
Parses the given definition of allowed vehicle classes into the given containers Deprecated classes g...
Definition: SUMOVehicleClass.cpp:222
RGBColor
Definition: RGBColor.h:39
LinkState
LinkState
The right-of-way state of a link between two lanes used when constructing a NBTrafficLightLogic,...
Definition: SUMOXMLDefinitions.h:1137
GUIGlObject::setMicrosimID
virtual void setMicrosimID(const std::string &newID)
Changes the microsimID of the object.
Definition: GUIGlObject.cpp:173
GNEConnection::setSpecialColor
void setSpecialColor(const RGBColor *Color2)
Definition: GNEConnection.cpp:361
GNEConnection::updateID
void updateID()
update internal ID of Connection
Definition: GNEConnection.cpp:217
NBEdge::getToNode
NBNode * getToNode() const
Returns the destination node of the edge.
Definition: NBEdge.h:498
canParseVehicleClasses
bool canParseVehicleClasses(const std::string &classes)
Checks whether the given string contains only known vehicle classes.
Definition: SUMOVehicleClass.cpp:251
NBEdge::Connection::viaShape
PositionVector viaShape
shape of via
Definition: NBEdge.h:263
GUIVisualizationSettings::detailSettings
GUIVisualizationDetailSettings detailSettings
detail settings
Definition: GUIVisualizationSettings.h:683
NBEdge::Connection::mayDefinitelyPass
bool mayDefinitelyPass
Information about being definitely free to drive (on-ramps)
Definition: NBEdge.h:227
SUMO_ATTR_KEEP_CLEAR
@ SUMO_ATTR_KEEP_CLEAR
Whether vehicles must keep the junction clear.
Definition: SUMOXMLDefinitions.h:696
SVCPermissions
int SVCPermissions
bitset where each bit declares whether a certain SVC may use this edge/lane
Definition: SUMOVehicleClass.h:218
GNEConnection::getLaneTo
GNELane * getLaneTo() const
@briefthe get lane of the outgoing lane
Definition: GNEConnection.cpp:184
GNEGeometry::Geometry::getShape
const PositionVector & getShape() const
The shape of the additional element.
Definition: GNEGeometry.cpp:147
GUIGlObject::buildNameCopyPopupEntry
void buildNameCopyPopupEntry(GUIGLObjectPopupMenu *ret, bool addSeparator=true)
Builds entries which allow to copy the name / typed name into the clipboard.
Definition: GUIGlObject.cpp:225
GNEConnection::GNEConnection
GNEConnection(GNELane *from, GNELane *to)
Definition: GNEConnection.cpp:52
GNEConnection::getEdgeFrom
GNEEdge * getEdgeFrom() const
get the name of the edge the vehicles leave
Definition: GNEConnection.cpp:166
GNEEdge::getNBEdge
NBEdge * getNBEdge() const
returns the internal NBEdge
Definition: GNEEdge.cpp:631
GNEConnection::getConnectionShape
const PositionVector & getConnectionShape() const
Definition: GNEConnection.cpp:75
GNEConnection::getToLaneIndex
int getToLaneIndex() const
@briefthe get lane index of the outgoing lane
Definition: GNEConnection.cpp:196
GNEViewNet::buildSelectionACPopupEntry
void buildSelectionACPopupEntry(GUIGLObjectPopupMenu *ret, GNEAttributeCarrier *AC)
Builds an entry which allows to (de)select the object.
Definition: GNEViewNet.cpp:338
SUMO_ATTR_PASS
@ SUMO_ATTR_PASS
Definition: SUMOXMLDefinitions.h:768
SUMO_ATTR_TLLINKINDEX2
@ SUMO_ATTR_TLLINKINDEX2
link: the index of the opposite direction link of a pedestrian crossing
Definition: SUMOXMLDefinitions.h:688
GNEConnection::getFromLaneIndex
int getFromLaneIndex() const
@briefthe get lane index of the incoming lane
Definition: GNEConnection.cpp:190
GNEConnection::getNBEdgeConnection
NBEdge::Connection & getNBEdgeConnection() const
get Edge::Connection
Definition: GNEConnection.cpp:202
GNEConnection::myShapeDeprecated
bool myShapeDeprecated
flag to indicate that connection's shape has to be updated
Definition: GNEConnection.h:179
GNEViewNet::getNetworkViewOptions
const GNEViewNetHelper::NetworkViewOptions & getNetworkViewOptions() const
get network view options
Definition: GNEViewNet.cpp:452
GNEChange_TLS.h
GNEViewNet.h
PositionVector::positionAtOffset
Position positionAtOffset(double pos, double lateralOffset=0) const
Returns the position at the given length.
Definition: PositionVector.cpp:248
NBEdge::Connection::shape
PositionVector shape
shape of Connection
Definition: NBEdge.h:251
GUIGlObject::getGlID
GUIGlID getGlID() const
Returns the numerical id of the object.
Definition: GUIGlObject.cpp:149
GNEViewNet::getDottedAC
const GNEAttributeCarrier * getDottedAC() const
get AttributeCarrier under cursor
Definition: GNEViewNet.cpp:1026
Boundary
A class that stores a 2D geometrical boundary.
Definition: Boundary.h:41
GNEConnection::getBoundary
Boundary getBoundary() const
Returns the street's geometry.
Definition: GNEConnection.cpp:153
NBEdge::getNumLanes
int getNumLanes() const
Returns the number of lanes.
Definition: NBEdge.h:477
GNEInternalLane::colorForLinksState
static RGBColor colorForLinksState(FXuint state)
return the color for each linkstate
Definition: GNEInternalLane.cpp:184
GNE_ATTR_PARAMETERS
@ GNE_ATTR_PARAMETERS
parameters "key1=value1|key2=value2|...|keyN=valueN"
Definition: SUMOXMLDefinitions.h:989
GUIVisualizationSettings::scale
double scale
information about a lane's width (temporary, used for a single view)
Definition: GUIVisualizationSettings.h:632
GNE_SUPERMODE_NETWORK
@ GNE_SUPERMODE_NETWORK
Network mode (Edges, junctions, etc..)
Definition: GNEViewNetHelper.h:46
NBEdge::Connection::tlLinkIndex2
int tlLinkIndex2
The index of the internal junction within the controlling traffic light (optional)
Definition: NBEdge.h:224
GNENet::retrieveJunction
GNEJunction * retrieveJunction(const std::string &id, bool failHard=true)
get junction by id
Definition: GNENet.cpp:1050
GNEViewNetHelper::EditModes::currentSupermode
Supermode currentSupermode
the current supermode
Definition: GNEViewNetHelper.h:305
getVehicleClassNames
const std::string & getVehicleClassNames(SVCPermissions permissions, bool expand)
Returns the ids of the given classes, divided using a ' '.
Definition: SUMOVehicleClass.cpp:168
GNEConnection::myToLane
GNELane * myToLane
outgoing lane of this connection
Definition: GNEConnection.h:167
Position
A point in 2D or 3D with translation and scaling methods.
Definition: Position.h:38
GNEConnection::myLinkState
LinkState myLinkState
Linkstate.
Definition: GNEConnection.h:170
GNE_NMODE_CONNECT
@ GNE_NMODE_CONNECT
mode for connecting lanes
Definition: GNEViewNetHelper.h:66
Position::x
double x() const
Returns the x-position.
Definition: Position.h:56
GNEEdge.h
GNEConnection::~GNEConnection
~GNEConnection()
Destructor.
Definition: GNEConnection.cpp:63
GUIVisualizationSettings::selectionScale
double selectionScale
the current selection scaling in NETEDIT (temporary)
Definition: GUIVisualizationSettings.h:641
PositionVector::append
void append(const PositionVector &v, double sameThreshold=2.0)
Definition: PositionVector.cpp:696
GNENetElement::isAttributeCarrierSelected
bool isAttributeCarrierSelected() const
check if attribute carrier is selected
Definition: GNENetElement.cpp:114
GLHelper::drawLine
static void drawLine(const Position &beg, double rot, double visLength)
Draws a thin line.
Definition: GLHelper.cpp:274
GNEChange_TLS
Definition: GNEChange_TLS.h:42
GNENetElement
Definition: GNENetElement.h:43
GNEViewNetHelper::NetworkViewOptions::showConnections
bool showConnections() const
check if select show connections checkbox is enabled
Definition: GNEViewNetHelper.cpp:1638
NBEdge::getConnectionRef
Connection & getConnectionRef(int fromLane, const NBEdge *to, int toLane)
Returns reference to the specified connection This method goes through "myConnections" and returns th...
Definition: NBEdge.cpp:1128
GUIVisualizationTextSettings::show
bool show
flag show
Definition: GUIVisualizationSettings.h:68
NBConnection
Definition: NBConnection.h:43
GNEEdge::getGNEJunctionDestiny
GNEJunction * getGNEJunctionDestiny() const
returns the destination-junction
Definition: GNEEdge.cpp:493
MID_GNE_CONNECTION_EDIT_SHAPE
@ MID_GNE_CONNECTION_EDIT_SHAPE
edit junction shape
Definition: GUIAppEnum.h:882
GNEConnection::isAttributeEnabled
bool isAttributeEnabled(SumoXMLAttr key) const
Definition: GNEConnection.cpp:552
GLHelper::drawShapeDottedContourAroundShape
static void drawShapeDottedContourAroundShape(const GUIVisualizationSettings &s, const int type, const PositionVector &shape, const double width)
draw a dotted contour around the given Non closed shape with certain width
Definition: GLHelper.cpp:461
NetworkEditMode
NetworkEditMode
@brie enum for network edit modes
Definition: GNEViewNetHelper.h:52
GNELane.h
NBEdge::getLanes
const std::vector< NBEdge::Lane > & getLanes() const
Returns the lane definitions.
Definition: NBEdge.h:656
GNENet::getViewNet
GNEViewNet * getViewNet() const
get view net
Definition: GNENet.cpp:2117
GUIGlObject::buildPopupHeader
void buildPopupHeader(GUIGLObjectPopupMenu *ret, GUIMainWindow &app, bool addSeparator=true)
Builds the header.
Definition: GUIGlObject.cpp:207
SUMO_ATTR_FROM_LANE
@ SUMO_ATTR_FROM_LANE
Definition: SUMOXMLDefinitions.h:719
PositionVector::getOrthogonal
PositionVector getOrthogonal(const Position &p, double extend, bool before, double length=1.0) const
return orthogonal through p (extending this vector if necessary)
Definition: PositionVector.cpp:1543
GUIVisualizationSettings::colorSettings
GUIVisualizationColorSettings colorSettings
color settings
Definition: GUIVisualizationSettings.h:677
SUMO_ATTR_FROM
@ SUMO_ATTR_FROM
Definition: SUMOXMLDefinitions.h:639
Parameterised::setParametersStr
void setParametersStr(const std::string &paramsString)
set the inner key/value map in string format "key1=value1|key2=value2|...|keyN=valueN"
Definition: Parameterised.cpp:139
GLIncludes.h
toString
std::string toString(const T &t, std::streamsize accuracy=gPrecision)
Definition: ToString.h:47
GNEConnection::getNBConnection
NBConnection getNBConnection() const
get NBConnection
Definition: GNEConnection.cpp:208
SUMO_ATTR_STATE
@ SUMO_ATTR_STATE
The state of a link.
Definition: SUMOXMLDefinitions.h:708
GNEConnection::drawGL
void drawGL(const GUIVisualizationSettings &s) const
Draws the object.
Definition: GNEConnection.cpp:281
GUIMainWindow
Definition: GUIMainWindow.h:46
Position::y
double y() const
Returns the y-position.
Definition: Position.h:61
GNEConnection::myInternalJunctionMarker
PositionVector myInternalJunctionMarker
waiting position for internal junction
Definition: GNEConnection.h:182
SUMO_ATTR_TLLINKINDEX
@ SUMO_ATTR_TLLINKINDEX
link: the index of the link within the traffic light
Definition: SUMOXMLDefinitions.h:686
Parameterised::areParametersValid
static bool areParametersValid(const std::string &value, bool report=false)
check if given string can be parsed to a parameters map "key1=value1|key2=value2|....
Definition: Parameterised.cpp:166
GNENetElement::getNet
GNENet * getNet() const
get Net in which this element is placed
Definition: GNENetElement.cpp:58
GNE_SUPERMODE_DEMAND
@ GNE_SUPERMODE_DEMAND
Demanding mode (Routes, Vehicles etc..)
Definition: GNEViewNetHelper.h:48
NBNode::getControllingTLS
const std::set< NBTrafficLightDefinition * > & getControllingTLS() const
Returns the traffic lights that were assigned to this node (The set of tls that control this node)
Definition: NBNode.h:318
InvalidArgument
Definition: UtilExceptions.h:56
NBEdge::Connection::keepClear
bool keepClear
whether the junction must be kept clear when using this connection
Definition: NBEdge.h:230
GNEConnection::getAttribute
std::string getAttribute(SumoXMLAttr key) const
Definition: GNEConnection.cpp:366
GUIGlObject::buildShowParamsPopupEntry
void buildShowParamsPopupEntry(GUIGLObjectPopupMenu *ret, bool addSeparator=true)
Builds an entry which allows to open the parameter window.
Definition: GUIGlObject.cpp:248
SUMO_ATTR_ALLOW
@ SUMO_ATTR_ALLOW
Definition: SUMOXMLDefinitions.h:782
SUMO_TAG_CONNECTION
@ SUMO_TAG_CONNECTION
connectio between two lanes
Definition: SUMOXMLDefinitions.h:202
GUIGlObject::buildCenterPopupEntry
void buildCenterPopupEntry(GUIGLObjectPopupMenu *ret, bool addSeparator=true)
Builds an entry which allows to center to the object.
Definition: GUIGlObject.cpp:216
GUIGlObject::buildPositionCopyEntry
void buildPositionCopyEntry(GUIGLObjectPopupMenu *ret, bool addSeparator=true)
Builds an entry which allows to copy the cursor position if geo projection is used,...
Definition: GUIGlObject.cpp:266
SUMO_ATTR_UNCONTROLLED
@ SUMO_ATTR_UNCONTROLLED
Definition: SUMOXMLDefinitions.h:767
NBEdge::Connection::customShape
PositionVector customShape
custom shape for connection
Definition: NBEdge.h:242
GNENetElement::myNet
GNENet * myNet
the net to inform about updates
Definition: GNENetElement.h:166
GNEConnection::updateLinkState
void updateLinkState()
recompute cached myLinkState
Definition: GNEConnection.cpp:235
config.h
GUIVisualizationSettings::addSize
GUIVisualizationSizeSettings addSize
Definition: GUIVisualizationSettings.h:589
GLO_JUNCTION
@ GLO_JUNCTION
a junction
Definition: GUIGlObjectTypes.h:50
GNEConnection::markConnectionGeometryDeprecated
void markConnectionGeometryDeprecated()
check that connection's Geometry has to be updated
Definition: GNEConnection.cpp:229
GNEGeometry::Geometry::getShapeRotations
const std::vector< double > & getShapeRotations() const
The rotations of the single shape parts.
Definition: GNEGeometry.cpp:153
GNE_ATTR_SELECTED
@ GNE_ATTR_SELECTED
element is selected
Definition: SUMOXMLDefinitions.h:971
StringTokenizer.h
GNEViewNet::getEditModes
const GNEViewNetHelper::EditModes & getEditModes() const
get edit modes
Definition: GNEViewNet.cpp:434
GUIVisualizationSettings::spreadSuperposed
bool spreadSuperposed
Whether to improve visualisation of superposed (rail) edges.
Definition: GUIVisualizationSettings.h:479
Boundary::grow
Boundary & grow(double by)
extends the boundary by the given amount
Definition: Boundary.cpp:300
GUIVisualizationSettings::drawDetail
bool drawDetail(const double detail, const double exaggeration) const
check if details can be drawn for the given GUIVisualizationDetailSettings and current scale and exxa...
Definition: GUIVisualizationSettings.cpp:1669
GNENetElement::selectAttributeCarrier
void selectAttributeCarrier(bool changeFlag=true)
select attribute carrier using GUIGlobalSelection
Definition: GNENetElement.cpp:83
NBTrafficLightLogic
A SUMO-compliant built logic for a traffic light.
Definition: NBTrafficLightLogic.h:51
GNEAttributeCarrier::getTagStr
const std::string & getTagStr() const
get tag assigned to this object in string format
Definition: GNEAttributeCarrier.cpp:1267
NBNode
Represents a single node (junction) during network building.
Definition: NBNode.h:67
GNEUndoList
Definition: GNEUndoList.h:48
GUIVisualizationDetailSettings::connectionsDemandMode
static const double connectionsDemandMode
draw connections in demand mode
Definition: GUIVisualizationSettings.h:280
GUIVisualizationSettings
Stores the information about how to visualize structures.
Definition: GUIVisualizationSettings.h:345
NBLoadedSUMOTLDef.h
GNEJunction
Definition: GNEJunction.h:47
NBEdge::Connection
A structure which describes a connection between edges or lanes.
Definition: NBEdge.h:189
GNEUndoList::p_begin
void p_begin(const std::string &description)
Begin undo command sub-group. This begins a new group of commands that are treated as a single comman...
Definition: GNEUndoList.cpp:72
invertPermissions
SVCPermissions invertPermissions(SVCPermissions permissions)
negate the given permissions and ensure that only relevant bits are set
Definition: SUMOVehicleClass.cpp:285
SumoXMLAttr
SumoXMLAttr
Numbers representing SUMO-XML - attributes.
Definition: SUMOXMLDefinitions.h:372
NBEdge::Connection::visibility
double visibility
custom foe visiblity for connection
Definition: NBEdge.h:236
GUIGlObject::getMicrosimID
virtual const std::string & getMicrosimID() const
Returns the id of the object as known to microsim.
Definition: GUIGlObject.cpp:163
GNEConnection::getCenteringBoundary
Boundary getCenteringBoundary() const
Returns the boundary to which the view shall be centered in order to show the object.
Definition: GNEConnection.cpp:273
GNEViewNetHelper::EditModes::networkEditMode
NetworkEditMode networkEditMode
the current Network edit mode
Definition: GNEViewNetHelper.h:308
WRITE_ERROR
#define WRITE_ERROR(msg)
Definition: MsgHandler.h:283
GNEConnection::getPositionInView
Position getPositionInView() const
Returns position of hierarchical element in view.
Definition: GNEConnection.cpp:146
GNELane
This lane is powered by an underlying GNEEdge and basically knows how to draw itself.
Definition: GNELane.h:45
GUIVisualizationSettings::edgeValue
GUIVisualizationTextSettings edgeValue
Definition: GUIVisualizationSettings.h:461
GNEChange_Attribute.h
GNENet.h
GNEConnection::myConnectionGeometry
GNEGeometry::Geometry myConnectionGeometry
connection geometry
Definition: GNEConnection.h:176
GUIVisualizationSizeSettings::getExaggeration
double getExaggeration(const GUIVisualizationSettings &s, const GUIGlObject *o, double factor=20) const
return the drawing size including exaggeration and constantSize values
Definition: GUIVisualizationSettings.cpp:212
PositionVector::move2side
void move2side(double amount, double maxExtension=100)
move position vector to side using certain ammount
Definition: PositionVector.cpp:1103
NBTrafficLightDefinition
The base class for traffic light logic definitions.
Definition: NBTrafficLightDefinition.h:67
GNEUndoList.h
SUMO_ATTR_CONTPOS
@ SUMO_ATTR_CONTPOS
Definition: SUMOXMLDefinitions.h:749
NBEdge::getID
const std::string & getID() const
Definition: NBEdge.h:1380
GNEConnection.h
NBLoadedSUMOTLDef
A loaded (complete) traffic light logic.
Definition: NBLoadedSUMOTLDef.h:44