VR-Forces Developer's Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
DtExampleSimEngine.h
Go to the documentation of this file.
1 /*****************************************************************************
2  * Copyright (c) 2023 MAK Technologies, Inc.
3  * All rights reserved.
4  *****************************************************************************/
5 
9 
10 #pragma once
11 
15 
17 #include <vrvUtil/DtUnicode.h>
18 #include <vrvUtil/signalslib.h>
19 
20 #include <matrix/vlTaitBryan.h>
21 #include <matrix/vlVector.h>
22 
23 #include <string>
24 
25 namespace makVrv
26 {
27  class DtEntity3dFacade;
28  class DtEntityHATLineFacade;
29  class DtCoordinateSystem;
30 }
31 
33 
49 {
50 public:
51 
55 
57  virtual ~DtExampleSimEngine();
58 
62  bool init();
63 
66  bool uninit();
67 
71  bool tick( double simTime );
72 
73 protected:
86  const makVrv::DtSelectionManager::IdSet& pinOrUnpinList,
87  bool pinAllLabels);
89 
90 
92  virtual void setHoverSignalsActive( bool active );
93 
95  virtual void setEntityInfoWidgetActive( bool active );
96 
98  virtual makVrv::DtUnicode generateInfoString() const;
99 
101  virtual void updatePosition( double simTime );
102 
104  virtual void repositionAircraft( DtVector position, DtTaitBryan ori );
105 
107  virtual void slot_coordinateSystemChanged();
108 protected:
110 
115 
116  std::string myEntityDisplayName;
118 
119  DtTaitBryan myOrientation;
121 
123  double myAngularVelocity;
124 
125  double myLastCommLineTime;
126  double myLastUpdateTime;
127  double myClockAngle;
128  double myHeading;
129  double myRadius;
130  double myRoll;
132 
136 
137  makVrv::vrvSignalsLib::connection myMouseEnterConnection;
138  makVrv::vrvSignalsLib::connection myMouseLeaveConnection;
139 };
double myLastUpdateTime
local clone of the system wide coordinate system. for thread safety.
Definition: DtExampleSimEngine.h:138
DtVector myOrbitCenter
local clone of the system wide coordinate system. for thread safety.
Definition: DtExampleSimEngine.h:140
makVrv::vrvSignalsLib::connection myMouseEnterConnection
local clone of the system wide coordinate system. for thread safety.
Definition: DtExampleSimEngine.h:152
A unicode string. DtUnicode stores a UTF-16 encoded unicode string. Code Point, a Unicode character...
Definition: DtUnicode.h:33
double myLastCommLineTime
local clone of the system wide coordinate system. for thread safety.
Definition: DtExampleSimEngine.h:137
Contains makVrv::DtEntityIndicatorWidget class.
virtual ~DtExampleSimEngine()
DTOR.
virtual void setEntityInfoWidgetActive(bool active)
Sets whether the entity info widget is displayed or not.
Contains makVrv:DtSelectionManager class.
DtVector myPosition
local clone of the system wide coordinate system. for thread safety.
Definition: DtExampleSimEngine.h:129
bool myEntityInfoWidgetPinnedFlag
local clone of the system wide coordinate system. for thread safety.
Definition: DtExampleSimEngine.h:126
virtual void updatePosition(double simTime)
Updates the current position / orientation of the entity.
bool uninit()
Destroy what was created in init()
bool init()
Initialize the simulation engine. In this case, the entity facade, indicators, and hat line are creat...
bool tick(double simTime)
Perform updates param[in] simTime is he current simulation time.
void slot_infoLabelsArePinned(const makVrv::DtSelectionManager::IdSet &pinOrUnpinList, bool pinAllLabels)
Boost slots.
Class for height above terrain line to show height above terrain line and label.
Definition: DtEntityHATLineFacade.h:34
makVrv::vrvSignalsLib::connection myMouseLeaveConnection
local clone of the system wide coordinate system. for thread safety.
Definition: DtExampleSimEngine.h:153
makVrv::DtCoordinateSystem * myCoordinateSystem
local clone of the system wide coordinate system. for thread safety.
Definition: DtExampleSimEngine.h:150
virtual void slot_coordinateSystemChanged()
slot for when the coordinate system changes
DtExampleSimulationConnection & mySimulationConnection
Definition: DtExampleSimEngine.h:109
DtTaitBryan myOrientation
local clone of the system wide coordinate system. for thread safety.
Definition: DtExampleSimEngine.h:128
DtEntityInfoWidget is the object proxy for 2D distributed entity info (label) objects.
Definition: DtEntityInfoWidget.h:27
Class to manage disconnection of boost connections on deletion.
Definition: DtSignalConnectionManager.h:20
double myClockAngle
local clone of the system wide coordinate system. for thread safety.
Definition: DtExampleSimEngine.h:142
The DtEntity3dFacade is a facade around agents that make up an entity in the 3D model set...
Definition: DtEntity3dFacade.h:39
double myHeading
local clone of the system wide coordinate system. for thread safety.
Definition: DtExampleSimEngine.h:135
The DtCoordinateSystem is used to manage the current coordinate system of the scene.
Definition: DtCoordinateSystem.h:40
The indicator widget.
Definition: DtEntityIndicatorWidget.h:29
Contains makVrv::DtEntityInfoWidget class.
double myRadius
local clone of the system wide coordinate system. for thread safety.
Definition: DtExampleSimEngine.h:143
Base class to provide boost signal/slot management.
virtual void repositionAircraft(DtVector position, DtTaitBryan ori)
Positions the aircraft at the given position with the given orientation.
DtExampleSimulationConnection.
Definition: DtExampleSimulationConnection.h:35
DtExampleSimEngine(makVrv::DtDe &de)
CTOR.
makVrv::DtEntity3dFacade * myEntityFacade
local clone of the system wide coordinate system. for thread safety.
Definition: DtExampleSimEngine.h:120
makVrv::DtEntityIndicatorWidget * myEntityIndicator
local clone of the system wide coordinate system. for thread safety.
Definition: DtExampleSimEngine.h:121
virtual void setHoverSignalsActive(bool active)
Sets whether the sim engine is listening for mouseover events or not in its entity indicator...
double myRoll
local clone of the system wide coordinate system. for thread safety.
Definition: DtExampleSimEngine.h:144
makVrv::DtEntityHATLineFacade * myEntityHATLineFacade
local clone of the system wide coordinate system. for thread safety.
Definition: DtExampleSimEngine.h:123
std::string myEntityDisplayName
local clone of the system wide coordinate system. for thread safety.
Definition: DtExampleSimEngine.h:125
std::set< DtUniqueID > IdSet
Definition: DtSelectionManager.h:32
double myAngularVelocity
local clone of the system wide coordinate system. for thread safety.
Definition: DtExampleSimEngine.h:141
makVrv::DtEntityInfoWidget * myEntityInfoWidget
local clone of the system wide coordinate system. for thread safety.
Definition: DtExampleSimEngine.h:122
virtual makVrv::DtUnicode generateInfoString() const
Generates the information string displayed in the entity info widget.
Provide a basic sim engine to use in an example showing how to embed a sim engine into a driver that ...
Definition: DtExampleSimEngine.h:48
makVrv::DtSignalConnectionManager mySignalConnections
local clone of the system wide coordinate system. for thread safety.
Definition: exampleSimEngine.h:143

Document ID: Generated on Wed Mar 27 22:49:11 EDT 2024 from SVN revision 264633
Copyright © 2005-2024 MAK Technologies. All Rights Reserved (www.mak.com)