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.dev/sumo
3 // Copyright (C) 2001-2024 German Aerospace Center (DLR) and others.
4 // This program and the accompanying materials are made available under the
5 // terms of the Eclipse Public License 2.0 which is available at
6 // https://www.eclipse.org/legal/epl-2.0/
7 // This Source Code may also be made available under the following Secondary
8 // Licenses when the conditions for such availability set forth in the Eclipse
9 // Public License 2.0 are satisfied: GNU General Public License, version 2
10 // or later which is available at
11 // https://www.gnu.org/licenses/old-licenses/gpl-2.0-standalone.html
12 // SPDX-License-Identifier: EPL-2.0 OR GPL-2.0-or-later
13 /****************************************************************************/
18 // The gui-version of the MSInstantInductLoop
19 /****************************************************************************/
20 #pragma once
21 #include <config.h>
22 
25 #include <utils/geom/Position.h>
26 #include "GUIDetectorWrapper.h"
27 
28 
29 // ===========================================================================
30 // class definitions
31 // ===========================================================================
37 public:
45  GUIInstantInductLoop(const std::string& id, OutputDevice& od,
46  MSLane* const lane, double positionInMeters,
47  const std::string name, const std::string& vTypes,
48  const std::string& nextEdges);
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 
76 
77 
86  GUIMainWindow& app, GUISUMOAbstractView& parent);
87 
89  double getExaggeration(const GUIVisualizationSettings& s) const;
90 
97 
102  void drawGL(const GUIVisualizationSettings& s) const;
104 
107 
108  private:
111 
114 
117 
119  double myFGRotation;
120 
122  double myPosition;
123 
124  private:
127 
130 
131  };
132 
133 
135  mutable FXMutex myLock;
136 
137 };
A class that stores a 2D geometrical boundary.
Definition: Boundary.h:39
A MSInductLoop-visualiser.
Position myFGPosition
The position in full-geometry mode.
double getExaggeration(const GUIVisualizationSettings &s) const
return exaggeration associated with this GLObject
MyWrapper(GUIInstantInductLoop &detector, double pos)
Constructor.
Boundary myBoundary
The detector's boundary.
MyWrapper & operator=(const MyWrapper &)
Invalidated assignment operator.
GUIInstantInductLoop & myDetector
The wrapped detector.
Boundary getCenteringBoundary() const
Returns the boundary to which the view shall be centered in order to show the object.
GUIParameterTableWindow * getParameterWindow(GUIMainWindow &app, GUISUMOAbstractView &parent)
Returns an own parameter window.
double myFGRotation
The rotation in full-geometry mode.
double myPosition
The position on the lane.
void drawGL(const GUIVisualizationSettings &s) const
Draws the object.
MyWrapper(const MyWrapper &)
Invalidated copy constructor.
GUIInstantInductLoop & getLoop()
Returns the detector itself.
The gui-version of the MSInstantInductLoop.
GUIInstantInductLoop(const std::string &id, OutputDevice &od, MSLane *const lane, double positionInMeters, const std::string name, const std::string &vTypes, const std::string &nextEdges)
Constructor.
FXMutex myLock
Mutex preventing parallel read/write access to internal MSInductLoop state.
virtual GUIDetectorWrapper * buildDetectorGUIRepresentation()
Returns this detector's visualisation-wrapper.
A window containing a gl-object's parameter.
Stores the information about how to visualize structures.
An instantaneous induction loop.
Representation of a lane in the micro simulation.
Definition: MSLane.h:84
Static storage of an output device and its base (abstract) implementation.
Definition: OutputDevice.h:61
A point in 2D or 3D with translation and scaling methods.
Definition: Position.h:37