VR-Link API Documentation for HLA 1.3
Home
Namespaces
Classes
Files
Examples
Libraries
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Groups
Pages
include
vl
link16Structs.h
Go to the documentation of this file.
1
/*********************************************************************
2
* ** Copyright (c) 2011 VT MAK
3
* ** All rights reserved.
4
* *********************************************************************/
5
/*********************************************************************
6
* ** $RCSfile: Link16Structs.h,v $ $Revision: 1.1 $ $State: Exp $
7
* *********************************************************************/
8
9
#ifdef DtHLA
10
11
#ifndef link16Structs_H_
12
#define link16Structs_H_
13
14
#include <
vlutil/vlNetTypes.h
>
15
16
const
DtU32
DtJtidsHeaderSize
= 6;
17
typedef
struct
DtJtidsHeaderStruct
18
{
19
DtU8
data
[
DtJtidsHeaderSize
];
20
}
DtJtidsHeaderStruct
;
21
22
const
DtU32
DtTadilJWordSize
= 10;
23
typedef
struct
DtTadilJWordStruct
24
{
25
DtU8
data
[
DtTadilJWordSize
];
26
}
DtTadilJWordStruct
;
27
28
const
DtU32
DtVoiceDataWordSize
= 10;
29
30
const
DtU32
DtLetHeaderSize
= 6;
31
typedef
struct
DtLetHeaderStruct
32
{
33
DtU8
data
[
DtLetHeaderSize
];
34
}
DtLetHeaderStruct
;
35
36
const
DtU32
DtRttabSize
= 6;
37
typedef
struct
DtRttabStruct
38
{
39
DtU8
data
[
DtRttabSize
];
40
}
DtRttabStruct
;
41
43
inline
void
networkByteArraySwap
(
DtU8
* byteArray,
int
size)
44
{
45
#if DT_LITTLE_ENDIAN
46
if
(
DtNetworkByteOrdering
() ==
DtBigEndian
)
47
{
48
#else
49
if
(
DtNetworkByteOrdering
() ==
DtLittleEndian
)
50
{
51
#endif
52
int
theEnd = 0;
53
for
(
int
i = 0; i < ( size >> 1 ); ++i )
54
{
55
theEnd = ( size - 1 ) - i;
56
byteArray[ i ] ^= byteArray[ theEnd ];
57
byteArray[ theEnd ] ^= byteArray[ i ];
58
byteArray[ i ] ^= byteArray[ theEnd ];
59
}
60
}
61
}
62
63
#endif
64
#endif
Document ID: Generated on Tue Mar 1 02:56:17 EST 2016 from SVN revision 162687
Copyright © 2005-2014 VT MÄK. All Rights Reserved (
www.mak.com
)