52 #ifdef CHECK_MEMORY_LEAKS
54 #endif // CHECK_MEMORY_LEAKS
61 myParentJunction(parentJunction),
62 myCrossing(parentJunction.getNBNode()->getCrossing(id)),
63 myShape(myCrossing.shape) {
74 int segments = (int)
myShape.size() - 1;
78 for (
int i = 0; i < segments; ++i) {
98 glColor3d(0.9, 0.9, 0.9);
100 glColor3d(0.1, 0.1, 0.1);
102 glTranslated(0, 0, .2);
110 glTranslated(0, 0, 0.1);
111 int e = (int)
myShape.size() - 1;
112 for (
int i = 0; i < e; ++i) {
118 glVertex2d(-halfWidth, -t);
119 glVertex2d(-halfWidth, -t - length);
120 glVertex2d(halfWidth, -t - length);
121 glVertex2d(halfWidth, -t);
129 glTranslated(0, 0, -.2);
210 return isPositive<SUMOReal>(value);
212 return value ==
"true" || value ==
"false";
void setAttribute(SumoXMLAttr key, const std::string &value, GNEUndoList *undoList)
SUMOReal width
This lane's width.
GNECrossing(GNEJunction &parentJunction, const std::string &id)
Constructor.
void drawGL(const GUIVisualizationSettings &s) const
Draws the object.
std::vector< SUMOReal > myShapeLengths
The lengths of the shape parts.
Stores the information about how to visualize structures.
SumoXMLAttr
Numbers representing SUMO-XML - attributes.
std::string getAttribute(SumoXMLAttr key) const
SUMOReal x() const
Returns the x-position.
GUIGlID getGlID() const
Returns the numerical id of the object.
A class that stores a 2D geometrical boundary.
bool priority
whether the pedestrians have priority
void updateGeometry()
update pre-computed geometry information
virtual const std::string & getMicrosimID() const
Returns the id of the object as known to microsim.
void updateCrossingAttributes(NBNode::Crossing crossing)
modify the specified crossing (using friend privileges)
A point in 2D or 3D with translation and scaling methods.
GUIParameterTableWindow * getParameterWindow(GUIMainWindow &app, GUISUMOAbstractView &parent)
Returns an own parameter window.
friend class GNEChange_Attribute
declare friend class
GNEJunction & myParentJunction
the parent junction of this crossing
GUIGLObjectPopupMenu * myPopup
the created popup
std::string toString(const T &t, std::streamsize accuracy=OUTPUT_ACCURACY)
NBNode::Crossing myCrossing
the data for this crossing
GUIGLObjectPopupMenu * getPopUpMenu(GUIMainWindow &app, GUISUMOAbstractView &parent)
Returns an own popup-menu.
Boundary & grow(SUMOReal by)
extends the boundary by the given amount
SUMOReal y() const
Returns the y-position.
Boundary getCenteringBoundary() const
Returns the boundary to which the view shall be centered in order to show the object.
virtual ~GNECrossing()
Destructor.
bool drawCrossingsAndWalkingareas
whether crosings and walkingareas shall be drawn
EdgeVector edges
The edges being crossed.
SUMOReal distanceTo2D(const Position &p2) const
returns the euclidean distance in the x-y-plane
bool isValid(SumoXMLAttr key, const std::string &value)
const PositionVector myShape
the shape of the edge
Boundary getBoxBoundary() const
Returns a boundary enclosing this list of lines.
void closeBuilding()
Closes the building of the table.
A window containing a gl-object's parameter.
std::vector< SUMOReal > myShapeRotations
void buildPopupHeader(GUIGLObjectPopupMenu *ret, GUIMainWindow &app, bool addSeparator=true)
Builds the header.