VR-Link API Documentation for HLA 1516
Home
Namespaces
Classes
Files
Examples
Libraries
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Groups
Pages
include
vlpi
netStructs.h
Go to the documentation of this file.
1
/*********************************************************************
2
** Copyright (c) 1992-2010 VT MAK
3
** All rights reserved.
4
*********************************************************************/
5
6
#pragma once
7
8
#include <
vlutil/vlTime.h
>
9
#include <
matrix/vlMath.h
>
10
#include <
matrix/vlTaitBryan.h
>
11
#include <
vlutil/vlNetTypes.h
>
12
#include <
vlutil/vlNetTimeStamp.h
>
13
#include "
oldTStamp.h
"
14
17
18
19
class
DT_DLL_VLPROTIND
DtEntityIdentifier
;
20
class
DT_DLL_VLPROTIND
DtBurstDescriptor
;
21
class
DT_DLL_VLPROTIND
DtEventId
;
22
class
DT_DLL_VLPROTIND
DtEntityType
;
23
class
DT_DLL_VLPROTIND
DtRadioEntityType
;
24
class
DT_DLL_VLPROTIND
DtSimulationAddress
;
25
26
typedef
DtSimulationAddress
DtFederateId
;
27
28
class
DT_DLL_VLPROTIND
DtNetFederateId
29
{
30
public
:
31
DtNetU16
site
;
32
DtNetU16
app
;
33
34
DtFederateId
operator=(
const
DtFederateId
&);
35
DtNetFederateId
& operator=(
const
DtNetFederateId
&);
36
};
37
38
39
class
DT_DLL_VLPROTIND
DtNetEntityMarking
40
{
41
public
:
42
DtNetU8
DtCharacterSet
;
43
#define DtMaxEntityMarkingLength 11
44
DtNetU8
DtText[
DtMaxEntityMarkingLength
];
45
};
46
47
class
DT_DLL_VLPROTIND
DtNetAggregateMarking
48
{
49
public
:
50
DtNetU8
DtCharacterSet
;
51
#define DtMaxAggregateMarkingLength 31
52
DtNetU8
DtText[
DtMaxAggregateMarkingLength
];
53
};
54
55
class
DT_DLL_VLPROTIND
DtNetEntityType
56
{
57
public
:
58
DtNetU8
DtEntityKind
;
59
DtNetU8
DtDomain
;
60
DtNetU16
DtCountry
;
61
DtNetU8
DtCategory
;
62
DtNetU8
DtSubCategory
;
63
DtNetU8
DtSpecific
;
64
DtNetU8
DtExtra
;
65
66
DtEntityType
operator=(
const
DtEntityType
&);
67
DtNetEntityType
& operator=(
const
DtNetEntityType
&);
68
};
69
70
class
DT_DLL_VLPROTIND
DtNetRadioEntityType
71
{
72
public
:
73
DtNetU8
kind
;
74
DtNetU8
domain
;
75
DtNetU16
country
;
76
DtNetU8
category
;
77
DtNetU8
nomenclatureVersion
;
78
DtNetU16
nomenclature
;
79
80
DtRadioEntityType
operator=(
const
DtRadioEntityType
&);
81
DtNetRadioEntityType
&operator=(
const
DtNetRadioEntityType
&);
82
};
83
84
class
DT_DLL_VLPROTIND
DtNetBurstDescriptor
85
{
86
public
:
87
DtNetEntityType
DtMunition
;
88
DtNetU16
DtWarhead
;
89
DtNetU16
DtFuze
;
90
DtNetU16
DtQuantity
;
91
DtNetU16
DtRate
;
92
93
DtBurstDescriptor
operator=(
const
DtBurstDescriptor
&);
94
DtNetBurstDescriptor
& operator=(
const
DtNetBurstDescriptor
&);
95
};
96
97
class
DT_DLL_VLPROTIND
DtNetSimulationAddress
98
{
99
public
:
100
DtNetU16
DtSite
;
101
DtNetU16
DtHost
;
102
103
DtSimulationAddress
operator=(
const
DtSimulationAddress
&);
104
DtNetSimulationAddress
& operator=(
const
DtNetSimulationAddress
&);
105
bool
operator==
(
const
DtNetSimulationAddress
& rhs)
const
106
{
107
return
(DtSite == rhs.
DtSite
)
108
&& (DtHost == rhs.
DtHost
);
109
}
110
bool
operator!=
(
const
DtNetSimulationAddress
& rhs)
const
111
{
112
return
!
operator==
(rhs);
113
}
114
};
115
116
class
DT_DLL_VLPROTIND
DtNetEntityIdentifier
117
{
118
public
:
119
DtNetSimulationAddress
DtSimulator
;
120
DtNetU16
DtEntity
;
121
122
DtEntityIdentifier
operator=(
const
DtEntityIdentifier
&);
123
DtNetEntityIdentifier
& operator=(
const
DtNetEntityIdentifier
&);
124
bool
operator==
(
const
DtNetEntityIdentifier
& rhs)
const
125
{
126
return
(DtSimulator == rhs.
DtSimulator
)
127
&& (DtEntity == rhs.
DtEntity
);
128
}
129
bool
operator!=
(
const
DtNetEntityIdentifier
& rhs)
const
130
{
131
return
!
operator==
(rhs);
132
}
133
};
134
135
136
139
class
DT_DLL_VLPROTIND
DtNet64Vector
140
{
141
public
:
142
DtNet64Vector
()
143
{rep[0] = rep[1] = rep[2] = 0.0;}
144
DtNet64Vector
(
const
DtVector
&vec)
145
{rep[0] = vec[0]; rep[1] = vec[1]; rep[2] = vec[2];}
146
DtVector
operator=(
const
DtVector
&vec)
147
{rep[0] = vec[0]; rep[1] = vec[1]; rep[2] = vec[2];
return
vec;}
148
operator
DtVector
()
const
{
return
DtVector
(rep[0], rep[1], rep[2]);}
149
DtNetFloat64
&
operator[]
(
int
i) {
return
rep[i];}
150
DtNetFloat64
operator[]
(
int
i)
const
{
return
rep[i];}
151
private
:
152
DtNetFloat64
rep[3];
153
};
154
157
class
DT_DLL_VLPROTIND
DtNet32Vector
158
{
159
public
:
160
DtNet32Vector
()
161
{rep[0] = rep[1] = rep[2] = (float)0.0;}
162
DtNet32Vector
(
const
DtVector
&vec)
163
{rep[0] = (float)vec[0]; rep[1] = (float)vec[1]; rep[2] = (float)vec[2];}
164
DtVector
operator=(
const
DtVector
&vec)
165
{rep[0] = (float)vec[0]; rep[1] = (float)vec[1]; rep[2] = (float)vec[2];
return
vec;}
166
operator
DtVector
()
const
167
{
return
DtVector
((
DtFloat32
) rep[0], (
DtFloat32
) rep[1], (
DtFloat32
) rep[2]);}
168
DtNetFloat32
&
operator[]
(
int
i) {
return
rep[i];}
169
DtNetFloat32
operator[]
(
int
i)
const
{
return
rep[i];}
170
private
:
171
DtNetFloat32
rep[3];
172
};
173
174
class
DT_DLL_VLPROTIND
DtNetEulerAngles
175
{
176
public
:
177
DtNetEulerAngles
() { psi = theta = phi = (float)0.0;}
178
DtNetEulerAngles
(
const
DtTaitBryan
&tait)
179
{psi = (
DtFloat32
)tait.
psi
(); theta = (
DtFloat32
)tait.
theta
(); phi = (
DtFloat32
)tait.
phi
();}
180
DtTaitBryan
operator=(
const
DtTaitBryan
&tait)
181
{psi = (
DtFloat32
)tait.
psi
(); theta = (
DtFloat32
)tait.
theta
(); phi = (
DtFloat32
)tait.
phi
();
return
tait;}
182
operator
DtTaitBryan
()
const
{
return
DtTaitBryan
(psi, theta, phi);}
183
DtNetFloat32
psi
;
/* Counter clockwise about z */
184
DtNetFloat32
theta
;
/* Counter clockwise about y */
185
DtNetFloat32
phi
;
/* Counter clockwise about x */
186
};
187
188
/***************************************************************
189
These structures don't need to be C++ classes even on little endian machines.
190
****************************************************************/
191
192
typedef
struct
DtNetArtParamRecordRPR1
193
{
194
DtNetU8
myChange
;
195
DtNetU8
padding
;
196
DtNetU16
myAttachedTo
;
197
DtNetU32
myArtOrAttached
;
198
DtNetU32
myClass
;
199
DtNetU32
myTypeMetric
;
200
DtNetFloat32
myValue
;
201
}
DtNetArtParamRecordRPR1
;
202
203
typedef
struct
DtNetArtParamRecord
204
{
205
DtNetU8
artOrAttached
;
206
DtNetU8
DtChange
;
207
DtNetU16
DtAttachedTo
;
208
DtNetU32
DtType
;
209
DtNet64Bits
DtValue
;
210
}
DtNetArtParamRecord
;
211
212
typedef
DtNetArtParamRecord
DtArticulatedParts
;
213
typedef
DtNetArtParamRecord
DtNetArtPartRecord
;
214
215
typedef
struct
DtNetEntityAssociationRecord
216
{
217
DtNetU8
myArtOrAttached
;
218
DtNetU8
myChange
;
219
DtNetU8
myAssociationStatus
;
220
DtNetU8
myAssociationType
;
221
DtNetEntityIdentifier
myEntityId
;
222
DtNetU16
myOwnStationLocation
;
223
DtNetU8
myPhysicalConnectionType
;
224
DtNetU8
myGroupMemberType
;
225
DtNetU16
myGroupNumber
;
226
}
DtNetEntityAssociationRecord
;
227
228
typedef
struct
DtNetEntityTypeRecord
229
{
230
DtNetU8
myArtOrAttached
;
231
DtNetU8
myChange
;
232
DtNetEntityType
myEntityType
;
233
DtNetU16
padding16
;
234
DtNetU32
padding32
;
235
}
DtNetEntityTypeRecord
;
236
237
typedef
struct
DtNetSeparationRecord
238
{
239
DtNetU8
myArtOrAttached
;
240
DtNetU8
mySeparationReason
;
241
DtNetU8
myPreEntityIndicator
;
242
DtNetU8
padding8
;
243
DtNetEntityIdentifier
myParentEntityId
;
244
DtNetU16
padding16
;
245
DtNetU16
myStationName
;
246
DtNetU16
myStationNumber
;
247
}
DtNetSeparationRecord
;
248
249
typedef
struct
DtNetAttachedPartRPR1
250
{
251
DtNetU8
myChange
;
252
DtNetU8
padding
;
253
DtNetU16
myAttachedTo
;
254
DtNetU32
myArtOrAttatched
;
255
DtNetU32
myStation
;
256
DtNetEntityType
myType
;
257
}
DtNetAttachedPartRPR1
;
258
259
typedef
struct
DtNetAttachedPart
260
{
261
262
DtNetU8
myArtOrAttached
;
263
DtNetU8
myChange
;
264
DtNetU16
myAttachedTo
;
265
DtNetU32
myStation
;
266
DtNetEntityType
myType
;
267
}
DtNetAttachedPart
;
268
269
typedef
struct
DtNetVPRecord
270
{
271
DtNetU8
myVPType
;
272
DtNetU8
myUnused1
;
273
DtNetU16
myUnused2
;
274
DtNetU32
myUnused3
;
275
DtNetU32
myUnused4
;
276
DtNetU32
myUnused5
;
277
}
DtNetVPRecord
;
278
279
typedef
struct
DtNetAngularVelocity
280
{
281
DtNetFloat32
wx
;
282
DtNetFloat32
wy
;
283
DtNetFloat32
wz
;
284
}
DtNetAngularVelocity
;
285
286
typedef
struct
DtNetLinearVelocity
287
{
288
bool
operator==
(
const
DtNetLinearVelocity
& rhs)
const
289
{
290
return
(
DtX
== rhs.
DtX
)
291
&& (
DtY
== rhs.
DtY
)
292
&& (
DtZ
== rhs.
DtZ
);
293
}
294
bool
operator!=
(
const
DtNetLinearVelocity
& rhs)
const
295
{
296
return
!
operator==
(rhs);
297
}
298
DtNetFloat32
DtX
;
299
DtNetFloat32
DtY
;
300
DtNetFloat32
DtZ
;
301
}
DtNetLinearVelocity
;
302
303
typedef
struct
DtNetLinearAcceleration
304
{
305
bool
operator==
(
const
DtNetLinearAcceleration
& rhs)
const
306
{
307
return
(
DtX
== rhs.
DtX
)
308
&& (
DtY
== rhs.
DtY
)
309
&& (
DtZ
== rhs.
DtZ
);
310
}
311
bool
operator!=
(
const
DtNetLinearAcceleration
& rhs)
const
312
{
313
return
!
operator==
(rhs);
314
}
315
DtNetFloat32
DtX
;
316
DtNetFloat32
DtY
;
317
DtNetFloat32
DtZ
;
318
}
DtNetLinearAcceleration
;
319
320
typedef
struct
DtNetWorldCoordinates
321
{
322
bool
operator==
(
const
DtNetWorldCoordinates
& rhs)
const
323
{
324
return
(
DtX
== rhs.
DtX
)
325
&& (
DtY
== rhs.
DtY
)
326
&& (
DtZ
== rhs.
DtZ
);
327
}
328
bool
operator!=
(
const
DtNetWorldCoordinates
& rhs)
const
329
{
330
return
!
operator==
(rhs);
331
}
332
DtNetFloat64
DtX
;
333
DtNetFloat64
DtY
;
334
DtNetFloat64
DtZ
;
335
}
DtNetWorldCoordinates
;
336
337
typedef
struct
DtNetEntityCoordinates
338
{
339
bool
operator==
(
const
DtNetEntityCoordinates
& rhs)
const
340
{
341
return
(
DtX
== rhs.
DtX
)
342
&& (
DtY
== rhs.
DtY
)
343
&& (
DtZ
== rhs.
DtZ
);
344
}
345
bool
operator!=
(
const
DtNetEntityCoordinates
& rhs)
const
346
{
347
return
!
operator==
(rhs);
348
}
349
DtNetFloat32
DtX
;
350
DtNetFloat32
DtY
;
351
DtNetFloat32
DtZ
;
352
}
DtNetEntityCoordinates
;
353
354
typedef
struct
DtNetTopoUpCoord
355
{
356
DtNetFloat32
East
;
357
DtNetFloat32
North
;
358
DtNetFloat32
Up
;
359
}
DtNetTopoUpCoord
;
360
361
typedef
struct
362
{
363
DtNetInt32
hour
;
364
DtNetTimeStamp
hourFrac
;
365
}
DtNetClockTime
;
366
367
DT_DLL_VLPROTIND
DtTime
DtClockTime2AbsTime
(
const
DtNetClockTime
*clock);
368
DT_DLL_VLPROTIND
void
DtAbsTime2ClockTime
(
DtTime
absTime,
DtNetClockTime
*clock);
369
Document ID: Generated on Fri May 15 06:36:13 EDT 2015 from SVN revision 153263
Copyright © 2005-2014 VT MÄK. All Rights Reserved (
www.mak.com
)