Eclipse SUMO - Simulation of Urban MObility
GUIInstantInductLoop.h
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 // The gui-version of the MSInstantInductLoop
15 /****************************************************************************/
16 #ifndef GUIInstantInductLoop_h
17 #define GUIInstantInductLoop_h
18 
19 
20 // ===========================================================================
21 // included modules
22 // ===========================================================================
23 #include <config.h>
24 
25 #include <fx.h>
27 #include <utils/geom/Position.h>
28 #include "GUIDetectorWrapper.h"
29 
30 
31 // ===========================================================================
32 // class definitions
33 // ===========================================================================
39 public:
47  GUIInstantInductLoop(const std::string& id, OutputDevice& od,
48  MSLane* const lane, double positionInMeters, const std::string& vTypes);
49 
50 
53 
54 
55 
60 
61 
62 public:
67  class MyWrapper : public GUIDetectorWrapper {
68  public:
70  MyWrapper(GUIInstantInductLoop& detector, double pos);
71 
73  ~MyWrapper();
74 
75 
77 
78 
87  GUIMainWindow& app, GUISUMOAbstractView& parent);
88 
89 
96 
97 
102  void drawGL(const GUIVisualizationSettings& s) const;
104 
105 
108 
109 
110  private:
113 
116 
119 
121  double myFGRotation;
122 
124  double myPosition;
125 
126  private:
129 
132 
133  };
134 
135 
137  mutable FXMutex myLock;
138 
139 };
140 
141 
142 #endif
143 
144 /****************************************************************************/
145 
GUIInstantInductLoop::MyWrapper::getParameterWindow
GUIParameterTableWindow * getParameterWindow(GUIMainWindow &app, GUISUMOAbstractView &parent)
Returns an own parameter window.
Definition: GUIInstantInductLoop.cpp:84
GUIParameterTableWindow
A window containing a gl-object's parameter.
Definition: GUIParameterTableWindow.h:62
GUISUMOAbstractView
Definition: GUISUMOAbstractView.h:72
MSLane
Representation of a lane in the micro simulation.
Definition: MSLane.h:82
GUIDetectorWrapper
Definition: GUIDetectorWrapper.h:42
OutputDevice
Static storage of an output device and its base (abstract) implementation.
Definition: OutputDevice.h:63
MSInstantInductLoop.h
GUIInstantInductLoop::MyWrapper::~MyWrapper
~MyWrapper()
Destructor.
Definition: GUIInstantInductLoop.cpp:71
GUIInstantInductLoop::MyWrapper::myDetector
GUIInstantInductLoop & myDetector
The wrapped detector.
Definition: GUIInstantInductLoop.h:112
GUIInstantInductLoop
The gui-version of the MSInstantInductLoop.
Definition: GUIInstantInductLoop.h:38
GUIInstantInductLoop::MyWrapper::myPosition
double myPosition
The position on the lane.
Definition: GUIInstantInductLoop.h:124
GUIInstantInductLoop::MyWrapper::myFGPosition
Position myFGPosition
The position in full-geometry mode.
Definition: GUIInstantInductLoop.h:118
GUIInstantInductLoop::MyWrapper::getLoop
GUIInstantInductLoop & getLoop()
Returns the detector itself.
Definition: GUIInstantInductLoop.cpp:152
GUIInstantInductLoop::buildDetectorGUIRepresentation
virtual GUIDetectorWrapper * buildDetectorGUIRepresentation()
Returns this detector's visualisation-wrapper.
Definition: GUIInstantInductLoop.cpp:53
GUIInstantInductLoop::GUIInstantInductLoop
GUIInstantInductLoop(const std::string &id, OutputDevice &od, MSLane *const lane, double positionInMeters, const std::string &vTypes)
Constructor.
Definition: GUIInstantInductLoop.cpp:43
Boundary
A class that stores a 2D geometrical boundary.
Definition: Boundary.h:41
Position
A point in 2D or 3D with translation and scaling methods.
Definition: Position.h:38
GUIDetectorWrapper.h
GUIInstantInductLoop::MyWrapper::drawGL
void drawGL(const GUIVisualizationSettings &s) const
Draws the object.
Definition: GUIInstantInductLoop.cpp:99
GUIInstantInductLoop::MyWrapper
A MSInductLoop-visualiser.
Definition: GUIInstantInductLoop.h:67
MSInstantInductLoop
An instantaneous induction loop.
Definition: MSInstantInductLoop.h:54
GUIInstantInductLoop::MyWrapper::operator=
MyWrapper & operator=(const MyWrapper &)
Invalidated assignment operator.
GUIInstantInductLoop::myLock
FXMutex myLock
Mutex preventing parallel read/write access to internal MSInductLoop state.
Definition: GUIInstantInductLoop.h:137
Position.h
GUIMainWindow
Definition: GUIMainWindow.h:46
GUIInstantInductLoop::~GUIInstantInductLoop
~GUIInstantInductLoop()
Destructor.
Definition: GUIInstantInductLoop.cpp:49
config.h
GUIInstantInductLoop::MyWrapper::getCenteringBoundary
Boundary getCenteringBoundary() const
Returns the boundary to which the view shall be centered in order to show the object.
Definition: GUIInstantInductLoop.cpp:75
GUIVisualizationSettings
Stores the information about how to visualize structures.
Definition: GUIVisualizationSettings.h:345
GUIInstantInductLoop::MyWrapper::myFGRotation
double myFGRotation
The rotation in full-geometry mode.
Definition: GUIInstantInductLoop.h:121
GUIInstantInductLoop::MyWrapper::myBoundary
Boundary myBoundary
The detector's boundary.
Definition: GUIInstantInductLoop.h:115
GUIInstantInductLoop::MyWrapper::MyWrapper
MyWrapper(const MyWrapper &)
Invalidated copy constructor.
GUIInstantInductLoop::MyWrapper::MyWrapper
MyWrapper(GUIInstantInductLoop &detector, double pos)
Constructor.
Definition: GUIInstantInductLoop.cpp:61