VR-Vantage 3.0 API Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
exampleSimEngine.h
Go to the documentation of this file.
1 /*****************************************************************************
2  * Copyright (c) 2021 MAK Technologies, Inc.
3  * All rights reserved.
4  *****************************************************************************/
5 
9 
10 #pragma once
11 
15 
17 #include <vrvUtil/DtUnicode.h>
18 
19 #include <matrix/vlTaitBryan.h>
20 #include <matrix/vlVector.h>
21 
22 #include <string>
23 
24 //#define SIM_IS_SHIP
25 
26 namespace makVrv
27 {
28  class DtEntity3dFacade;
29  class DtEntityHATLineFacade;
30  class DtDe;
31  class DtCoordinateSystem;
32 }
33 
48 {
49 public:
50 
54 
56  virtual ~DtExampleSimEngine();
57 
61  bool init();
62 
65  bool uninit();
66 
70  bool tick(double simTime);
71 
72 protected:
74 
75 
76 
77 
78 
79 
80 
81 
82 
83 
85  const makVrv::DtSelectionManager::IdSet& pinOrUnpinList,
86  bool pinAllLabels);
87 
90  virtual void setHoverSignalsActive(bool active);
91 
93  virtual void setEntityInfoWidgetActive(bool active);
94 
96  virtual makVrv::DtUnicode generateInfoString() const;
97 
99  virtual void updatePosition(double simTime);
100 
101 #ifdef SIM_IS_SHIP
102  // For the ship, need to pass dT so we can determine velocity
103  virtual void repositionShip(DtVector position, DtTaitBryan ori, double dT);
104 #else
105 
106  virtual void repositionAircraft(DtVector position, DtTaitBryan ori);
107 #endif
108 
110  virtual void slot_coordinateSystemChanged();
111 
112 protected:
114 
119 
122 
123  DtTaitBryan myOrientation;
124  DtVector myPosition;
125 
126 #ifdef SIM_IS_SHIP
127  // For the ship, need our last (local) position to determine our velocity
128  DtVector myLastPosition;
129 #endif
130  double myHeading;
131 
132  double myLastCommLineTime;
133  double myLastUpdateTime;
134 
135  DtVector myOrbitCenter;
136  double myAngularVelocity;
137  double myClockAngle;
138  double myRadius;
139  double myRoll;
140 
141 
143 
147 };


Copyright © 2005-2021 MAK Technologies. All Rights Reserved (www.mak.com)