VR-Link API Documentation for HLA 1.3
designatePdu.h
Go to the documentation of this file.
1 /*******************************************************************************
2 ** Copyright (c) 1992-2010 VT MAK
3 ** All rights reserved.
4 *******************************************************************************/
5 
8 
9 #ifndef DtDesignatorPdu_H_
10 #define DtDesignatorPdu_H_
11 
12 #if DtDIS
13 
14 #include "hostStructs.h"
15 #include "stateMsg.h"
16 #include <matrix/vlMath.h>
17 #include "packets/designateP.h"
18 
19 
20 class DtExerciseConn;
21 class DtDesignatorPdu;
22 
24 typedef void (*DtDesignatorPduCb)( DtDesignatorPdu* pdu, void* usr );
25 
29 class DT_DLL_VL DtDesignatorPdu : public DtStateMsg
30 {
31 public:
33  enum {
34  DtDesignatorStaticSizeVERS5 = 88,
35  DtDesignatorStaticSizeVERS4 = 72
36  };
37 
39  enum { PduStaticSize = DtDesignatorStaticSizeVERS5 };
40 
41 public:
43  DtDesignatorPdu( DtBufferPtr buffer = DtUSE_INTERNAL_BUFFER );
44 
46  DtDesignatorPdu( const DtNetDesignatorPdu* initial,
48 
51  static DtPdu* create( const DtNetPacket* initial,
53 
55  static void addCallback( DtExerciseConn* conn,
56  DtDesignatorPduCb cb, void* usr );
57 
59  static void removeCallback( DtExerciseConn* conn,
60  DtDesignatorPduCb cb, void* usr );
61 
63 
64  const DtEntityIdentifier& designatingEntityId() const;
65  void setDesignatingEntityId( const DtEntityIdentifier& id );
67 
69 
70  DtDesignatorCodeName codeName() const;
71  void setCodeName( DtDesignatorCodeName name );
73 
75 
76  const DtEntityIdentifier& designatedEntityId() const;
77  void setDesignatedEntityId( const DtEntityIdentifier& id );
79 
81 
82  DtDesignatorCode designatorCode() const;
83  void setDesignatorCode( DtDesignatorCode code );
85 
87 
88  float power() const;
89  void setPower( float power );
91 
93 
94  float wavelength() const;
95  void setWavelength( float wavelength );
97 
99 
100  const DtVector& designatorSpotRelative() const;
101  void setDesignatorSpotRelative( const DtVector& loc );
103 
105 
106 
107  const DtVector& designatorSpotWorld() const;
108  void setDesignatorSpotWorld( const DtVector& loc );
110 
112 
113  DtDeadReckonTypes deadReckoningAlgorithm() const;
114  void setDeadReckoningAlgorithm( DtDeadReckonTypes alg );
116 
118 
119  const DtVector& linearAcceleration() const;
120  void setLinearAcceleration( const DtVector& acc );
122 
124  virtual void printData() const;
126 
128  virtual void printDataToStream(std::ostream& stream) const;
130 
131 protected:
132  DtPduKind internalGetPduKind() const { return DtDesignatorPduKind; }
133  DtEntityIdentifier theId;
134  DtVector loc;
135 };
136 
137 #endif
138 #endif
139 
140 

Document ID: Generated on Wed Aug 14 15:35:11 EDT 2013 from SVN revision 130445
Copyright © 2005-2013 VT MÄK. All Rights Reserved (www.mak.com)