SUMO - Simulation of Urban MObility
GUIE2Collector.h
Go to the documentation of this file.
1 /****************************************************************************/
9 // The gui-version of the MS_E2_ZS_Collector
10 /****************************************************************************/
11 // SUMO, Simulation of Urban MObility; see http://sumo.dlr.de/
12 // Copyright (C) 2001-2017 DLR (http://www.dlr.de/) and contributors
13 /****************************************************************************/
14 //
15 // This file is part of SUMO.
16 // SUMO is free software: you can redistribute it and/or modify
17 // it under the terms of the GNU General Public License as published by
18 // the Free Software Foundation, either version 3 of the License, or
19 // (at your option) any later version.
20 //
21 /****************************************************************************/
22 #ifndef GUIE2Collector_h
23 #define GUIE2Collector_h
24 
25 
26 // ===========================================================================
27 // included modules
28 // ===========================================================================
29 #ifdef _MSC_VER
30 #include <windows_config.h>
31 #else
32 #include <config.h>
33 #endif
34 
36 #include "GUIDetectorWrapper.h"
37 
38 
39 // ===========================================================================
40 // class definitions
41 // ===========================================================================
51 class GUIE2Collector : public MSE2Collector {
52 public:
73  GUIE2Collector(const std::string& id, DetectorUsage usage,
74  MSLane* lane, double startPos, double endPos, double detLength,
75  SUMOTime haltingTimeThreshold, double haltingSpeedThreshold, double jamDistThreshold,
76  const std::string& vTypes, bool showDetector);
77 
78 
93  GUIE2Collector(const std::string& id, DetectorUsage usage,
94  std::vector<MSLane*> lanes, double startPos, double endPos,
95  SUMOTime haltingTimeThreshold, double haltingSpeedThreshold, double jamDistThreshold,
96  const std::string& vTypes, bool showDetector);
97 
98 
100  ~GUIE2Collector();
101 
102 
108 
109 private:
112 
113 public:
118  class MyWrapper : public GUIDetectorWrapper {
119  public:
121  MyWrapper(GUIE2Collector& detector);
122 
124  ~MyWrapper();
125 
126 
128 
129 
138  GUIMainWindow& app, GUISUMOAbstractView& parent);
139 
140 
147 
148 
153  void drawGL(const GUIVisualizationSettings& s) const;
155 
156 
159 
160 
161  private:
164 
167 
170 
172  std::vector<double> myShapeLengths;
173 
175  std::vector<double> myShapeRotations;
176 
177  private:
179  MyWrapper(const MyWrapper&);
180 
182  MyWrapper& operator=(const MyWrapper&);
183 
184  };
185 
186 };
187 
188 
189 #endif
190 
191 /****************************************************************************/
192 
std::vector< double > myShapeLengths
A sequence of lengths in full-geometry mode.
std::vector< double > myShapeRotations
A sequence of rotations in full-geometry mode.
GUIParameterTableWindow * getParameterWindow(GUIMainWindow &app, GUISUMOAbstractView &parent)
Returns an own parameter window.
An areal detector corresponding to a sequence of consecutive lanes.
Definition: MSE2Collector.h:87
MyWrapper(GUIE2Collector &detector)
Constructor.
Stores the information about how to visualize structures.
Boundary getCenteringBoundary() const
Returns the boundary to which the view shall be centered in order to show the object.
GUIE2Collector & myDetector
The wrapped detector.
The gui-version of the MSE2Collector.
A class that stores a 2D geometrical boundary.
Definition: Boundary.h:48
PositionVector myFullGeometry
A sequence of positions in full-geometry mode.
A list of positions.
virtual GUIDetectorWrapper * buildDetectorGUIRepresentation()
Returns the wrapper for this detector.
GUIE2Collector(const std::string &id, DetectorUsage usage, MSLane *lane, double startPos, double endPos, double detLength, SUMOTime haltingTimeThreshold, double haltingSpeedThreshold, double jamDistThreshold, const std::string &vTypes, bool showDetector)
Constructor with given end position and detector length.
MyWrapper & operator=(const MyWrapper &)
Invalidated assignment operator.
void drawGL(const GUIVisualizationSettings &s) const
Draws the object.
bool myShowDetectorInGUI
Whether the detector shall be drawn in the gui.
long long int SUMOTime
Definition: TraCIDefs.h:52
~GUIE2Collector()
Destructor.
Representation of a lane in the micro simulation.
Definition: MSLane.h:79
A window containing a gl-object&#39;s parameter.
GUIE2Collector & getDetector()
Returns the detector itself.
Boundary myBoundary
The detector&#39;s boundary.