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 /****************************************************************************/
15 // The gui-version of the MSInstantInductLoop
16 /****************************************************************************/
17 #ifndef GUIInstantInductLoop_h
18 #define GUIInstantInductLoop_h
19 
20 
21 // ===========================================================================
22 // included modules
23 // ===========================================================================
24 #include <config.h>
25 
26 #include <fx.h>
28 #include <utils/geom/Position.h>
29 #include "GUIDetectorWrapper.h"
30 
31 
32 // ===========================================================================
33 // class definitions
34 // ===========================================================================
40 public:
48  GUIInstantInductLoop(const std::string& id, OutputDevice& od,
49  MSLane* const lane, double positionInMeters, const std::string& vTypes);
50 
51 
54 
55 
56 
61 
62 
63 public:
68  class MyWrapper : public GUIDetectorWrapper {
69  public:
71  MyWrapper(GUIInstantInductLoop& detector, double pos);
72 
74  ~MyWrapper();
75 
76 
78 
79 
88  GUIMainWindow& app, GUISUMOAbstractView& parent);
89 
90 
97 
98 
103  void drawGL(const GUIVisualizationSettings& s) const;
105 
106 
109 
110 
111  private:
114 
117 
120 
122  double myFGRotation;
123 
125  double myPosition;
126 
127  private:
129  MyWrapper(const MyWrapper&);
130 
132  MyWrapper& operator=(const MyWrapper&);
133 
134  };
135 
136 
138  mutable FXMutex myLock;
139 
140 };
141 
142 
143 #endif
144 
145 /****************************************************************************/
146 
GUIInstantInductLoop::MyWrapper::getParameterWindow
GUIParameterTableWindow * getParameterWindow(GUIMainWindow &app, GUISUMOAbstractView &parent)
Returns an own parameter window.
Definition: GUIInstantInductLoop.cpp:85
GUIParameterTableWindow
A window containing a gl-object's parameter.
Definition: GUIParameterTableWindow.h:63
GUISUMOAbstractView
Definition: GUISUMOAbstractView.h:73
MSLane
Representation of a lane in the micro simulation.
Definition: MSLane.h:83
GUIDetectorWrapper
Definition: GUIDetectorWrapper.h:43
OutputDevice
Static storage of an output device and its base (abstract) implementation.
Definition: OutputDevice.h:64
MSInstantInductLoop.h
GUIInstantInductLoop::MyWrapper::~MyWrapper
~MyWrapper()
Destructor.
Definition: GUIInstantInductLoop.cpp:72
GUIInstantInductLoop::MyWrapper::myDetector
GUIInstantInductLoop & myDetector
The wrapped detector.
Definition: GUIInstantInductLoop.h:113
GUIInstantInductLoop
The gui-version of the MSInstantInductLoop.
Definition: GUIInstantInductLoop.h:39
GUIInstantInductLoop::MyWrapper::myPosition
double myPosition
The position on the lane.
Definition: GUIInstantInductLoop.h:125
GUIInstantInductLoop::MyWrapper::myFGPosition
Position myFGPosition
The position in full-geometry mode.
Definition: GUIInstantInductLoop.h:119
GUIInstantInductLoop::MyWrapper::getLoop
GUIInstantInductLoop & getLoop()
Returns the detector itself.
Definition: GUIInstantInductLoop.cpp:153
GUIInstantInductLoop::buildDetectorGUIRepresentation
virtual GUIDetectorWrapper * buildDetectorGUIRepresentation()
Returns this detector's visualisation-wrapper.
Definition: GUIInstantInductLoop.cpp:54
GUIInstantInductLoop::GUIInstantInductLoop
GUIInstantInductLoop(const std::string &id, OutputDevice &od, MSLane *const lane, double positionInMeters, const std::string &vTypes)
Constructor.
Definition: GUIInstantInductLoop.cpp:44
Boundary
A class that stores a 2D geometrical boundary.
Definition: Boundary.h:42
Position
A point in 2D or 3D with translation and scaling methods.
Definition: Position.h:39
GUIDetectorWrapper.h
GUIInstantInductLoop::MyWrapper::drawGL
void drawGL(const GUIVisualizationSettings &s) const
Draws the object.
Definition: GUIInstantInductLoop.cpp:100
GUIInstantInductLoop::MyWrapper
A MSInductLoop-visualiser.
Definition: GUIInstantInductLoop.h:68
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:138
Position.h
GUIMainWindow
Definition: GUIMainWindow.h:47
GUIInstantInductLoop::~GUIInstantInductLoop
~GUIInstantInductLoop()
Destructor.
Definition: GUIInstantInductLoop.cpp:50
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:76
GUIVisualizationSettings
Stores the information about how to visualize structures.
Definition: GUIVisualizationSettings.h:346
GUIInstantInductLoop::MyWrapper::myFGRotation
double myFGRotation
The rotation in full-geometry mode.
Definition: GUIInstantInductLoop.h:122
GUIInstantInductLoop::MyWrapper::myBoundary
Boundary myBoundary
The detector's boundary.
Definition: GUIInstantInductLoop.h:116
GUIInstantInductLoop::MyWrapper::MyWrapper
MyWrapper(GUIInstantInductLoop &detector, double pos)
Constructor.
Definition: GUIInstantInductLoop.cpp:62