VR-Forces 4.5 Class Documentation
Home
Modules
Namespaces
Classes
Files
Examples
Behavior Models
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Groups
Pages
include
vrfExtObjects
extDiGuyCustomPduDecoder.h
Go to the documentation of this file.
1
/*********************************************************************
2
** Copyright (c) 2016 VT MAK
3
** All rights reserved.
4
*********************************************************************/
5
6
#pragma once
7
8
#if DtDIS
9
10
#include <
vrfExtObjects/vrfExtObjectsDefines.h
>
11
#include <vl/diGuyCustomPduDecoder.h>
12
13
// Because there's a limit to the range of values defined inside VR-Link and we need more
14
enum
DtExtDIGuyCustomPduMsgId
15
{
16
DtExtDIGuyMsgIdEscapeReserved
= 0,
17
DtExtDIGuyMsgIdSetCharType
= 1,
18
DtExtDIGuyMsgIdSetCharAppearance
= 2,
19
DtExtDIGuyMsgIdSetCharAction
= 3,
20
DtExtDIGuyMsgIdSetCharVisible
= 4,
21
DtExtDIGuyMsgIdBeginAppearanceEffect
= 34,
22
DtExtDIGuyMsgIdEndAppearanceEffect
,
23
DtExtDIGuyMsgIdStopAppearanceEffect
,
24
DtExtDIGuyMsgIdExecuteGesture
= 41,
25
DtExtDIGuyMsgIdCharacterScale
,
26
DtExtDIGuyMsgIdSetShapeVariation2
,
27
DtExtDIGuyMsgIdEndGesture
,
28
};
29
30
// ======================================================================================
31
// Note: the PDU-decoding code that exists here should be kept in sync with the PDU code
32
// that lives in bdiDisInterface and bdiExerciseInterfaceDis in DI-Guy.
33
// ======================================================================================
34
35
/*
36
This class extends the decoder in VR-Link. It exists only as a home for several
37
static encoder functions, which will replace the original ones in the parent class.
38
39
Instructions for developers who come here in the future:
40
41
Go to c:\mak-dev\vrvantage-for-forces\include\vrvVrl\DtEntityExistenceListener.inl
42
The code in processDiGuyPdu() must be moved here. Unfortunately, the stuff with
43
the listener doesn't translate well -- we'll need to update the DI-Guy ESR to support
44
appearance effects, gestures, variations, and so forth.
45
*/
46
class
DT_DLL_vrfExtObjects
DtExtDIGuyCustomPduDecoder
:
public
DtDIGuyCustomPduDecoder
47
{
48
public
:
49
DtExtDIGuyCustomPduDecoder
();
50
virtual
~
DtExtDIGuyCustomPduDecoder
();
51
55
virtual
void
decode
(
DtPdu
* pdu,
DtEntityStateRepository
* stateRep);
56
virtual
DtPduDecoder* clone()
const
;
57
virtual
void
clearCallbacks();
58
61
virtual
void
addDiGuyPduCallback(
DtExtDIGuyCustomPduMsgId
k, DtDIGuyPduCallbackFcn info);
62
virtual
void
removeDiGuyPduCallback(
DtExtDIGuyCustomPduMsgId
k,
const
DtDIGuyPduCallbackFcn& info);
63
64
public
:
65
static
void
processDiGuyAppearance(DtDIGuyCustomPdu* pdu,
DtEntityStateRepository
* pEsr);
66
static
void
processDiGuyType(DtDIGuyCustomPdu* pdu,
DtEntityStateRepository
* pEsr);
67
static
void
processDiGuyAction(DtDIGuyCustomPdu* pdu,
DtEntityStateRepository
* pEsr);
68
69
protected
:
70
71
// We're replacing the array in the parent class because it wasn't big enough.
72
// (std::set isn't expandable)
73
#define DtEXTMAX_DIGUYMSG_KINDS 50
74
std::set<DtDIGuyPduCallbackFcn> myExtDiGuyCbList[
DtEXTMAX_DIGUYMSG_KINDS
];
75
76
};
77
78
#endif //DtDIS
Document ID: Generated on Thu Mar 23 18:54:12 EDT 2017 from SVN revision 174804
Copyright © 2005-2017 VT MÄK. All Rights Reserved (
www.mak.com
)