VR-Vantage 3.0 API Documentation
Home
Modules
Namespaces
Classes
Files
Libraries
Examples
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Properties
Friends
Macros
Groups
Pages
examples
exampleDriverPlugin
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
12
#include <
vrvCore/DtEntityIndicatorWidget.h
>
13
#include <
vrvCore/DtSelectionManager.h
>
14
#include <
vrvCore/DtEntityInfoWidget.h
>
15
16
#include <
vrvUtil/DtSignalConnectionManager.h
>
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
47
class
DtExampleSimEngine
48
{
49
public
:
50
53
DtExampleSimEngine
(
makVrv::DtDe
& de);
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
84
void
slot_infoLabelsArePinned
(
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
:
113
makVrv::DtDe
&
myDe
;
114
115
makVrv::DtEntity3dFacade
*
myEntityFacade
;
116
makVrv::DtEntityIndicatorWidget
*
myEntityIndicator
;
117
makVrv::DtEntityInfoWidget
*
myEntityInfoWidget
;
118
makVrv::DtEntityHATLineFacade
*
myEntityHATLineFacade
;
119
120
std::string
myEntityDisplayName
;
121
bool
myEntityInfoWidgetPinnedFlag
;
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
142
makVrv::DtSignalConnectionManager
mySignalConnections
;
143
146
makVrv::DtCoordinateSystem
*
myCoordinateSystem
=
nullptr
;
147
};
Copyright © 2005-2022 MAK Technologies. All Rights Reserved (
www.mak.com
)