Eclipse SUMO - Simulation of Urban MObility
GNECalibrator.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 /****************************************************************************/
15 //
16 /****************************************************************************/
17 
18 // ===========================================================================
19 // included modules
20 // ===========================================================================
21 
22 #include <netedit/GNENet.h>
23 #include <netedit/GNEUndoList.h>
24 #include <netedit/GNEViewNet.h>
29 #include <utils/gui/div/GLHelper.h>
31 
32 #include "GNECalibrator.h"
33 
34 
35 // ===========================================================================
36 // member method definitions
37 // ===========================================================================
38 
39 GNECalibrator::GNECalibrator(const std::string& id, GNEViewNet* viewNet, GNEEdge* edge, double pos, SUMOTime frequency, const std::string& name, const std::string& output, const std::string& routeprobe) :
40  GNEAdditional(id, viewNet, GLO_CALIBRATOR, SUMO_TAG_CALIBRATOR, name, false, {
41  edge
42 }, {}, {}, {}, {}, {}, {}, {}, {}, {}),
43 myPositionOverLane(pos),
44 myFrequency(frequency),
45 myOutput(output),
46 myRouteProbe(routeprobe) {
47 }
48 
49 
50 GNECalibrator::GNECalibrator(const std::string& id, GNEViewNet* viewNet, GNELane* lane, double pos, SUMOTime frequency, const std::string& name, const std::string& output, const std::string& routeprobe) :
51  GNEAdditional(id, viewNet, GLO_CALIBRATOR, SUMO_TAG_LANECALIBRATOR, name, false, {}, {lane}, {}, {}, {}, {}, {}, {}, {}, {}),
52 myPositionOverLane(pos),
53 myFrequency(frequency),
54 myOutput(output),
55 myRouteProbe(routeprobe) {
56 }
57 
58 
60 
61 
62 void
64  // This additional cannot be moved
65 }
66 
67 
68 void
70  // This additional cannot be moved
71 }
72 
73 
74 void
76  // Clear all containers
78  // get shape depending of we have a edge or a lane
79  if (getLaneParents().size() > 0) {
80  // Get shape of lane parent
81  myGeometry.shape.push_back(getLaneParents().front()->getGeometry().shape.positionAtOffset(myPositionOverLane));
82  // Save rotation (angle) of the vector constructed by points f and s
83  myGeometry.shapeRotations.push_back(getLaneParents().front()->getGeometry().shape.rotationDegreeAtOffset(myPositionOverLane) * -1);
84  } else if (getEdgeParents().size() > 0) {
85  for (auto i : getEdgeParents().front()->getLanes()) {
86  // Get shape of lane parent
87  myGeometry.shape.push_back(i->getGeometry().shape.positionAtOffset(myPositionOverLane));
88  // Save rotation (angle) of the vector constructed by points f and s
89  myGeometry.shapeRotations.push_back(getEdgeParents().front()->getLanes().at(0)->getGeometry().shape.rotationDegreeAtOffset(myPositionOverLane) * -1);
90  }
91  } else {
92  throw ProcessError("Both myEdge and myLane aren't defined");
93  }
94 }
95 
96 
99  PositionVector shape = (getLaneParents().size() > 0) ? getLaneParents().front()->getGeometry().shape : getEdgeParents().front()->getLanes().at(0)->getGeometry().shape;
100  if (myPositionOverLane < 0) {
101  return shape.front();
102  } else if (myPositionOverLane > shape.length()) {
103  return shape.back();
104  } else {
105  return shape.positionAtOffset(myPositionOverLane);
106  }
107 }
108 
109 
110 Boundary
112  return myGeometry.shape.getBoxBoundary().grow(10);
113 }
114 
115 
116 std::string
118  // get parent name depending of we have a edge or a lane
119  if (getLaneParents().size() > 0) {
120  return getLaneParents().front()->getMicrosimID();
121  } else if (getEdgeParents().size() > 0) {
122  return getEdgeParents().front()->getLanes().at(0)->getMicrosimID();
123  } else {
124  throw ProcessError("Both myEdge and myLane aren't defined");
125  }
126 }
127 
128 
129 void
131  // get values
132  const double exaggeration = s.addSize.getExaggeration(s, this);
133  // begin draw
134  glPushName(getGlID());
135  glLineWidth(1.0);
136  // iterate over every Calibrator symbol
137  for (int i = 0; i < (int)myGeometry.shape.size(); ++i) {
138  const Position& pos = myGeometry.shape[i];
139  double rot = myGeometry.shapeRotations[i];
140  glPushMatrix();
141  glTranslated(pos.x(), pos.y(), getType());
142  glRotated(rot, 0, 0, 1);
143  glTranslated(0, 0, getType());
144  glScaled(exaggeration, exaggeration, 1);
145  glPolygonMode(GL_FRONT_AND_BACK, GL_FILL);
146  // set color
147  if (drawUsingSelectColor()) {
149  } else {
151  }
152  // base
153  glBegin(GL_TRIANGLES);
154  glVertex2d(0 - 1.4, 0);
155  glVertex2d(0 - 1.4, 6);
156  glVertex2d(0 + 1.4, 6);
157  glVertex2d(0 + 1.4, 0);
158  glVertex2d(0 - 1.4, 0);
159  glVertex2d(0 + 1.4, 6);
160  glEnd();
161  // draw text if isn't being drawn for selecting
162  if (!s.drawForSelecting && s.drawDetail(s.detailSettings.calibratorText, exaggeration)) {
163  // set color depending of selection status
165  // draw "C"
166  GLHelper::drawText("C", Position(0, 1.5), 0.1, 3, textColor, 180);
167  // draw "edge" or "lane "
168  if (getLaneParents().size() > 0) {
169  GLHelper::drawText("lane", Position(0, 3), .1, 1, textColor, 180);
170  } else if (getEdgeParents().size() > 0) {
171  GLHelper::drawText("edge", Position(0, 3), .1, 1, textColor, 180);
172  } else {
173  throw ProcessError("Both myEdge and myLane aren't defined");
174  }
175  }
176  glPopMatrix();
177  // check if dotted contour has to be drawn
178  if (myViewNet->getDottedAC() == this) {
179  GLHelper::drawShapeDottedContourRectangle(s, getType(), pos, 2.8, 6, rot, 0, 3);
180  }
181  }
182  // draw name
184  // pop name
185  glPopName();
186 }
187 
188 
189 void
191  // Open calibrator dialog
192  GNECalibratorDialog calibratorDialog(this);
193 }
194 
195 
196 std::string
198  switch (key) {
199  case SUMO_ATTR_ID:
200  return getAdditionalID();
201  case SUMO_ATTR_EDGE:
202  return getEdgeParents().front()->getID();
203  case SUMO_ATTR_LANE:
204  return getLaneParents().front()->getID();
205  case SUMO_ATTR_POSITION:
207  case SUMO_ATTR_FREQUENCY:
208  return time2string(myFrequency);
209  case SUMO_ATTR_NAME:
210  return myAdditionalName;
211  case SUMO_ATTR_OUTPUT:
212  return myOutput;
214  return myRouteProbe;
215  case GNE_ATTR_SELECTED:
217  case GNE_ATTR_GENERIC:
218  return getGenericParametersStr();
219  default:
220  throw InvalidArgument(getTagStr() + " doesn't have an attribute of type '" + toString(key) + "'");
221  }
222 }
223 
224 
225 void
226 GNECalibrator::setAttribute(SumoXMLAttr key, const std::string& value, GNEUndoList* undoList) {
227  if (value == getAttribute(key)) {
228  return; //avoid needless changes, later logic relies on the fact that attributes have changed
229  }
230  switch (key) {
231  case SUMO_ATTR_ID:
232  case SUMO_ATTR_EDGE:
233  case SUMO_ATTR_LANE:
234  case SUMO_ATTR_POSITION:
235  case SUMO_ATTR_FREQUENCY:
236  case SUMO_ATTR_NAME:
237  case SUMO_ATTR_OUTPUT:
239  case GNE_ATTR_SELECTED:
240  case GNE_ATTR_GENERIC:
241  undoList->p_add(new GNEChange_Attribute(this, myViewNet->getNet(), key, value));
242  break;
243  default:
244  throw InvalidArgument(getTagStr() + " doesn't have an attribute of type '" + toString(key) + "'");
245  }
246 
247 }
248 
249 
250 bool
251 GNECalibrator::isValid(SumoXMLAttr key, const std::string& value) {
252  switch (key) {
253  case SUMO_ATTR_ID:
254  return isValidAdditionalID(value);
255  case SUMO_ATTR_EDGE:
256  if (myViewNet->getNet()->retrieveEdge(value, false) != nullptr) {
257  return true;
258  } else {
259  return false;
260  }
261  case SUMO_ATTR_LANE:
262  if (myViewNet->getNet()->retrieveLane(value, false) != nullptr) {
263  return true;
264  } else {
265  return false;
266  }
267  case SUMO_ATTR_POSITION:
268  if (canParse<double>(value)) {
269  // obtain position and check if is valid
270  double newPosition = parse<double>(value);
271  PositionVector shape = (getLaneParents().size() > 0) ? getLaneParents().front()->getGeometry().shape : getEdgeParents().front()->getLanes().at(0)->getGeometry().shape;
272  if ((newPosition < 0) || (newPosition > shape.length())) {
273  return false;
274  } else {
275  return true;
276  }
277  } else {
278  return false;
279  }
280  case SUMO_ATTR_FREQUENCY:
281  return canParse<SUMOTime>(value);
282  case SUMO_ATTR_NAME:
284  case SUMO_ATTR_OUTPUT:
287  return SUMOXMLDefinitions::isValidNetID(value);
288  case GNE_ATTR_SELECTED:
289  return canParse<bool>(value);
290  case GNE_ATTR_GENERIC:
291  return isGenericParametersValid(value);
292  default:
293  throw InvalidArgument(getTagStr() + " doesn't have an attribute of type '" + toString(key) + "'");
294  }
295 }
296 
297 
298 std::string
300  return getTagStr() + ": " + getID();
301 }
302 
303 
304 std::string
306  return getTagStr();
307 }
308 
309 // ===========================================================================
310 // private
311 // ===========================================================================
312 
313 void
314 GNECalibrator::setAttribute(SumoXMLAttr key, const std::string& value) {
315  switch (key) {
316  case SUMO_ATTR_ID:
317  changeAdditionalID(value);
318  break;
319  case SUMO_ATTR_EDGE:
320  changeEdgeParents(this, value);
321  break;
322  case SUMO_ATTR_LANE:
323  changeLaneParents(this, value);
324  break;
325  case SUMO_ATTR_POSITION:
326  myPositionOverLane = parse<double>(value);
327  break;
328  case SUMO_ATTR_FREQUENCY:
329  myFrequency = parse<SUMOTime>(value);
330  break;
331  case SUMO_ATTR_NAME:
332  myAdditionalName = value;
333  break;
334  case SUMO_ATTR_OUTPUT:
335  myOutput = value;
336  break;
338  myRouteProbe = value;
339  break;
340  case GNE_ATTR_SELECTED:
341  if (parse<bool>(value)) {
343  } else {
345  }
346  break;
347  case GNE_ATTR_GENERIC:
349  break;
350  default:
351  throw InvalidArgument(getTagStr() + " doesn't have an attribute of type '" + toString(key) + "'");
352  }
353 }
354 
355 /****************************************************************************/
GUIGlObject::getType
GUIGlObjectType getType() const
Returns the type of the object as coded in GUIGlObjectType.
Definition: GUIGlObject.cpp:181
SUMOXMLDefinitions::isValidAttribute
static bool isValidAttribute(const std::string &value)
whether the given string is a valid attribute for a certain key (for example, a name)
Definition: SUMOXMLDefinitions.cpp:988
SUMO_TAG_LANECALIBRATOR
A calibrator placed over lane (used in netedit)
Definition: SUMOXMLDefinitions.h:94
GNEAdditional
An Element which don't belongs to GNENet but has influency in the simulation.
Definition: GNEAdditional.h:47
GNEAdditional::setGenericParametersStr
void setGenericParametersStr(const std::string &value)
set generic parameters in string format
Definition: GNEAdditional.cpp:704
GNEAdditional::getAdditionalID
const std::string & getAdditionalID() const
Definition: GNEAdditional.cpp:578
GNEAttributeCarrier::getID
const std::string getID() const
function to support debugging
Definition: GNEAttributeCarrier.cpp:1187
GNECalibrator::myRouteProbe
std::string myRouteProbe
ID to current RouteProbe.
Definition: GNECalibrator.h:156
GNECalibrator::commitGeometryMoving
void commitGeometryMoving(GNEUndoList *undoList)
commit geometry changes in the attributes of an element after use of moveGeometry(....
Definition: GNECalibrator.cpp:69
GNEAdditional::AdditionalGeometry::shape
PositionVector shape
The shape of the additional element.
Definition: GNEAdditional.h:68
SUMOXMLDefinitions::isValidFilename
static bool isValidFilename(const std::string &value)
whether the given string is a valid attribute for a filename (for example, a name)
Definition: SUMOXMLDefinitions.cpp:994
GUIGlObject::drawName
void drawName(const Position &pos, const double scale, const GUIVisualizationTextSettings &settings, const double angle=0) const
draw name of item
Definition: GUIGlObject.cpp:355
RGBColor::BLACK
static const RGBColor BLACK
Definition: RGBColor.h:198
GNECalibrator::getAttribute
std::string getAttribute(SumoXMLAttr key) const
Definition: GNECalibrator.cpp:197
GNECalibrator::myFrequency
SUMOTime myFrequency
Frequency of calibrator.
Definition: GNECalibrator.h:150
GNEAdditional::AdditionalGeometry::shapeRotations
std::vector< double > shapeRotations
The rotations of the single shape parts.
Definition: GNEAdditional.h:74
GNEAttributeCarrier::isGenericParametersValid
static bool isGenericParametersValid(const std::string &value)
check if given string can be parsed to a map/list of generic parameters
Definition: GNEAttributeCarrier.cpp:1354
SUMOTime
long long int SUMOTime
Definition: SUMOTime.h:35
SUMO_ATTR_EDGE
Definition: SUMOXMLDefinitions.h:424
GNEViewNet
Definition: GNEViewNet.h:43
GNEHierarchicalElementParents::getEdgeParents
const std::vector< GNEEdge * > & getEdgeParents() const
get edge parents
Definition: GNEHierarchicalElementParents.cpp:150
GNECalibrator::setAttribute
void setAttribute(SumoXMLAttr key, const std::string &value, GNEUndoList *undoList)
method for setting the attribute and letting the object perform additional changes
Definition: GNECalibrator.cpp:226
SUMO_ATTR_ID
Definition: SUMOXMLDefinitions.h:379
PositionVector::length
double length() const
Returns the length.
Definition: PositionVector.cpp:476
GNECalibrator::~GNECalibrator
~GNECalibrator()
Destructor.
Definition: GNECalibrator.cpp:59
GLHelper.h
SUMO_ATTR_LANE
Definition: SUMOXMLDefinitions.h:635
GNECalibrator::getPositionInView
Position getPositionInView() const
Returns position of additional in view.
Definition: GNECalibrator.cpp:98
SUMO_ATTR_ROUTEPROBE
Definition: SUMOXMLDefinitions.h:667
GNEAdditional::changeAdditionalID
void changeAdditionalID(const std::string &newID)
change ID of additional
Definition: GNEAdditional.cpp:604
PositionVector
A list of positions.
Definition: PositionVector.h:46
GNEAdditional::unselectAttributeCarrier
void unselectAttributeCarrier(bool changeFlag=true)
unselect attribute carrier using GUIGlobalSelection
Definition: GNEAdditional.cpp:634
GNECalibrator::openAdditionalDialog
void openAdditionalDialog()
open Calibrator Dialog
Definition: GNECalibrator.cpp:190
GLHelper::setColor
static void setColor(const RGBColor &c)
Sets the gl-color to this value.
Definition: GLHelper.cpp:616
PositionVector::getBoxBoundary
Boundary getBoxBoundary() const
Returns a boundary enclosing this list of lines.
Definition: PositionVector.cpp:382
GNEAdditional::myViewNet
GNEViewNet * myViewNet
The GNEViewNet this additional element belongs.
Definition: GNEAdditional.h:365
GNEEdge
A road/street connecting two junctions (netedit-version)
Definition: GNEEdge.h:50
GNEAttributeCarrier::GNEChange_Attribute
friend class GNEChange_Attribute
declare friend class
Definition: GNEAttributeCarrier.h:57
GNEHierarchicalElementParents::getLaneParents
const std::vector< GNELane * > & getLaneParents() const
get lanes of VSS
Definition: GNEHierarchicalElementParents.cpp:182
GNEUndoList::p_add
void p_add(GNEChange_Attribute *cmd)
special method, avoid empty changes, always execute
Definition: GNEUndoList.cpp:132
GNECalibrator::GNECalibrator
GNECalibrator(const std::string &id, GNEViewNet *viewNet, GNEEdge *edge, double pos, SUMOTime frequency, const std::string &name, const std::string &output, const std::string &routeprobe)
Constructor using edge.
Definition: GNECalibrator.cpp:39
GNEViewNet::getNet
GNENet * getNet() const
get the net object
Definition: GNEViewNet.cpp:927
GNEAdditional::isAttributeCarrierSelected
bool isAttributeCarrierSelected() const
check if attribute carrier is selected
Definition: GNEAdditional.cpp:650
GLHelper::drawText
static void drawText(const std::string &text, const Position &pos, const double layer, const double size, const RGBColor &col=RGBColor::BLACK, const double angle=0, int align=0, double width=-1)
Definition: GLHelper.cpp:668
RGBColor
Definition: RGBColor.h:40
GNECalibratorDialog.h
GUIVisualizationSettings::addName
GUIVisualizationTextSettings addName
Definition: GUIVisualizationSettings.h:582
GNECalibrator::myOutput
std::string myOutput
output of calibrator
Definition: GNECalibrator.h:153
GUIVisualizationSettings::detailSettings
GUIVisualizationDetailSettings detailSettings
detail settings
Definition: GUIVisualizationSettings.h:655
GNECalibrator::isValid
bool isValid(SumoXMLAttr key, const std::string &value)
method for checking if the key and their conrrespond attribute are valids
Definition: GNECalibrator.cpp:251
GUIVisualizationColorSettings::selectedAdditionalColor
RGBColor selectedAdditionalColor
additional selection color (busStops, Detectors...)
Definition: GUIVisualizationSettings.h:148
GUIVisualizationDetailSettings::calibratorText
static const double calibratorText
details for calibrator text
Definition: GUIVisualizationSettings.h:311
GNEAdditional::selectAttributeCarrier
void selectAttributeCarrier(bool changeFlag=true)
Definition: GNEAdditional.cpp:619
GNEViewNet.h
PositionVector::positionAtOffset
Position positionAtOffset(double pos, double lateralOffset=0) const
Returns the position at the given length.
Definition: PositionVector.cpp:246
GUIGlObject::getGlID
GUIGlID getGlID() const
Returns the numerical id of the object.
Definition: GUIGlObject.cpp:150
GNEViewNet::getDottedAC
const GNEAttributeCarrier * getDottedAC() const
get AttributeCarrier under cursor
Definition: GNEViewNet.cpp:939
Boundary
A class that stores a 2D geometrical boundary.
Definition: Boundary.h:42
GLHelper::drawShapeDottedContourRectangle
static void drawShapeDottedContourRectangle(const GUIVisualizationSettings &s, const int type, const Position &center, const double width, const double height, const double rotation=0, const double offsetX=0, const double offsetY=0)
draw a dotted contour around the given Position with certain width and height
Definition: GLHelper.cpp:555
GUIVisualizationSettings::scale
double scale
information about a lane's width (temporary, used for a single view)
Definition: GUIVisualizationSettings.h:623
ProcessError
Definition: UtilExceptions.h:40
GNEAdditional::AdditionalGeometry::clearGeometry
void clearGeometry()
reset geometry
Definition: GNEAdditional.cpp:53
Position
A point in 2D or 3D with translation and scaling methods.
Definition: Position.h:39
Position::x
double x() const
Returns the x-position.
Definition: Position.h:57
GNEEdge.h
time2string
std::string time2string(SUMOTime t)
Definition: SUMOTime.cpp:65
GNEAdditional::myAdditionalName
std::string myAdditionalName
name of additional
Definition: GNEAdditional.h:374
GNELane.h
SUMO_ATTR_FREQUENCY
Definition: SUMOXMLDefinitions.h:660
SUMO_ATTR_POSITION
Definition: SUMOXMLDefinitions.h:658
GNECalibrator::myPositionOverLane
double myPositionOverLane
position over Lane
Definition: GNECalibrator.h:147
GUIVisualizationColorSettings::calibrator
static const RGBColor calibrator
color for Calibrators
Definition: GUIVisualizationSettings.h:223
GUIVisualizationSettings::colorSettings
GUIVisualizationColorSettings colorSettings
color settings
Definition: GUIVisualizationSettings.h:649
GUIVisualizationColorSettings::selectionColor
RGBColor selectionColor
basic selection color
Definition: GUIVisualizationSettings.h:130
GLIncludes.h
toString
std::string toString(const T &t, std::streamsize accuracy=gPrecision)
Definition: ToString.h:48
GNE_ATTR_GENERIC
generic attribute
Definition: SUMOXMLDefinitions.h:986
Position::y
double y() const
Returns the y-position.
Definition: Position.h:62
GNECalibratorDialog
Dialog for edit calibrators.
Definition: GNECalibratorDialog.h:46
SUMO_ATTR_OUTPUT
Definition: SUMOXMLDefinitions.h:785
InvalidArgument
Definition: UtilExceptions.h:57
GNEAdditional::getGenericParametersStr
std::string getGenericParametersStr() const
return generic parameters in string format
Definition: GNEAdditional.cpp:678
SUMOXMLDefinitions::isValidNetID
static bool isValidNetID(const std::string &value)
whether the given string is a valid id for a network element
Definition: SUMOXMLDefinitions.cpp:964
GNECalibrator::getParentName
std::string getParentName() const
Returns the name of the parent object.
Definition: GNECalibrator.cpp:117
GNECalibrator::getCenteringBoundary
Boundary getCenteringBoundary() const
Returns the boundary to which the view shall be centered in order to show the object.
Definition: GNECalibrator.cpp:111
GNEAdditional::drawUsingSelectColor
bool drawUsingSelectColor() const
check if attribute carrier must be drawn using selecting color.
Definition: GNEAdditional.cpp:656
GNECalibrator.h
GNEHierarchicalElementParents::changeLaneParents
void changeLaneParents(GNEShape *elementChild, const std::string &newLaneIDs)
change edge parents of a shape
Definition: GNEHierarchicalElementParents.cpp:460
GLO_CALIBRATOR
a Calibrator
Definition: GUIGlObjectTypes.h:92
GNECalibrator::updateGeometry
void updateGeometry()
update pre-computed geometry information
Definition: GNECalibrator.cpp:75
GNENet::retrieveEdge
GNEEdge * retrieveEdge(const std::string &id, bool failHard=true)
get edge by id
Definition: GNENet.cpp:1020
GNEAdditional::myGeometry
AdditionalGeometry myGeometry
geometry to be precomputed in updateGeometry(...)
Definition: GNEAdditional.h:368
GNENet::retrieveLane
GNELane * retrieveLane(const std::string &id, bool failHard=true, bool checkVolatileChange=false)
get lane by id
Definition: GNENet.cpp:1179
GUIVisualizationSettings::addSize
GUIVisualizationSizeSettings addSize
Definition: GUIVisualizationSettings.h:580
GNE_ATTR_SELECTED
element is selected
Definition: SUMOXMLDefinitions.h:968
Boundary::grow
Boundary & grow(double by)
extends the boundary by the given amount
Definition: Boundary.cpp:301
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:1621
GNECalibrator::getHierarchyName
std::string getHierarchyName() const
get Hierarchy Name (Used in AC Hierarchy)
Definition: GNECalibrator.cpp:305
GNEAttributeCarrier::getTagStr
const std::string & getTagStr() const
get tag assigned to this object in string format
Definition: GNEAttributeCarrier.cpp:1165
SUMO_ATTR_NAME
Definition: SUMOXMLDefinitions.h:381
GNEUndoList
Definition: GNEUndoList.h:49
GUIVisualizationSettings
Stores the information about how to visualize structures.
Definition: GUIVisualizationSettings.h:346
GNECalibrator::moveGeometry
void moveGeometry(const Position &offset)
change the position of the element geometry without saving in undoList
Definition: GNECalibrator.cpp:63
GNEHierarchicalElementParents::changeEdgeParents
void changeEdgeParents(GNEShape *elementChild, const std::string &newEdgeIDs)
change edge parents of a shape
Definition: GNEHierarchicalElementParents.cpp:340
GNECalibrator::drawGL
void drawGL(const GUIVisualizationSettings &s) const
Draws the object.
Definition: GNECalibrator.cpp:130
SUMO_TAG_CALIBRATOR
A calibrator placed over edge.
Definition: SUMOXMLDefinitions.h:92
GNEAdditional::isValidAdditionalID
bool isValidAdditionalID(const std::string &newID) const
check if a new additional ID is valid
Definition: GNEAdditional.cpp:584
SumoXMLAttr
SumoXMLAttr
Numbers representing SUMO-XML - attributes.
Definition: SUMOXMLDefinitions.h:373
GNELane
This lane is powered by an underlying GNEEdge and basically knows how to draw itself.
Definition: GNELane.h:46
GNEChange_Attribute.h
GNENet.h
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
GNECalibrator::getPopUpID
std::string getPopUpID() const
get PopPup ID (Used in AC Hierarchy)
Definition: GNECalibrator.cpp:299
GNEUndoList.h
GUIVisualizationSettings::drawForSelecting
bool drawForSelecting
whether drawing is performed for the purpose of selecting objects
Definition: GUIVisualizationSettings.h:635