VR-Forces Developer's Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
simIndividualLocalEntityNetInterface.h
Go to the documentation of this file.
1 /*******************************************************************************
2 ** Copyright (c) 2013 MAK Technologies, Inc.
3 ** All rights reserved.
4 *******************************************************************************/
5 
8 
14 
15 #pragma once
16 
18 
21 
32 
33 namespace makVrf
34 {
37  {
38  private:
41 
44 
46  const DtSimIndividualLocalEntityNetInterface & operator=(const
48 
49  public:
52  DtStateData* vrfObject, DtVrlinkNetworkInterface* mgr, bool publishObject = true);
55 
57  virtual void updateNet();
58 
60  virtual void forceUpdate();
61 
64  virtual void updatePublisher();
65 
67  virtual bool isUnit() const { return false; }
68  virtual bool isEntity() const { return true; }
69  virtual bool isEnvironmental() const {return false; }
70 
71  virtual bool wantsToCreatePublisher() const;
72 
78  virtual bool createPublisher(const DtEntityIdentifier& id = DtEntityIdentifier::nullId());
79 
81  void destroyPublisher();
82 
84  virtual DtObjectPublisher* publisher();
85 
95  virtual bool setEntityPublisher(DtVrfExtEntityPublisher * publisher);
96 
100  virtual void setupNetworkRepository();
101 
103  virtual DtVrfExtEntityPublisher * entityPublisher() const;
104 
107  virtual DtExtEntityStateRepository * individualNetworkState() const;
108 
110  virtual void updateUuid();
111 
112  virtual bool isAggregate() const { return false; }
113 
116  virtual DtString type() const;
117 
118  #if DtHLA
119  virtual RTI::ObjectClassHandle objectClassHandle() const;
121  #endif
122 
127  isIndividualLocalEntityNetInterface(const DtSimObjectNetInterface *
128  objNetInterface);
129 
130  static DtSimObjectNetInterface * creator(
131  DtStateData* vrfObject, DtVrlinkNetworkInterface* mgr, bool publishObject);
132 
133 #if DtDIS
134  virtual void sendFinalPduOnDestruction(bool) override;
136 #endif
137 
141  static void SetProfilePdus(bool onOf, double pduTimeCheck = 1.0, int numberOfPacketsOverTime = 0
142 #if DtDIS
143  , bool includeSummary = false
144 #endif
145  );
146 
147  protected:
148 
149  virtual bool updateVrfDataAsSeenByRemote();
150 
154  virtual void updateArtPartsNetState();
155 
156  virtual bool updateDIGuyState();
157 
158  virtual void updateAirVehicleLightingNetState();
159 
160  virtual void updateGroundVehicleLightingNetState();
161 
162  virtual void updateAisDataNetState();
163 
164  virtual void firstTimeInitialize();
165 
166  protected:
167 
169 
175 
176  int myNumberOfPdusSent = 0;
177  double myFirstTimePduSent = 0;
178 
179 #if DtDIS
180  typedef struct
181  {
182  int bits;
183  double simTime;
186  DtTaitBryan stateRepOrientation;
188  DtTaitBryan asSeenByOrientation;
190  double rotTrace;
193  } Changed;
194 
195  std::vector<Changed> myChangedBits;
196 #else
197  int myNumberOfAttributesPdusSent = 0;
198  double myFirstTimeAttributePduSent = 0;
199 #endif
200  };
201 }
int bits
Definition: simIndividualLocalEntityNetInterface.h:182
double orientationThreshold
Definition: simIndividualLocalEntityNetInterface.h:192
Definition: simLocalEntityNetInterface.h:48
Definition: simIndividualLocalEntityNetInterface.h:35
double rotTrace
Definition: simIndividualLocalEntityNetInterface.h:190
DtTaitBryan asSeenByOrientation
Definition: simIndividualLocalEntityNetInterface.h:188
virtual bool isEntity() const
Definition: simIndividualLocalEntityNetInterface.h:68
bool myIsFreezeMovementPublished
Definition: simIndividualLocalEntityNetInterface.h:174
Definition: simIndividualLocalEntityNetInterface.h:180
DtVector32 stateRepRotationalVelocity
Definition: simIndividualLocalEntityNetInterface.h:187
DtVector asSeenByLocation
Definition: simIndividualLocalEntityNetInterface.h:185
bool myFirstTimeInitialize
Definition: simIndividualLocalEntityNetInterface.h:173
bool myFirstTick
Definition: simIndividualLocalEntityNetInterface.h:171
DtVrfExtEntityPublisher * myEntityPublisher
Definition: simIndividualLocalEntityNetInterface.h:168
static DtTime theDiGuyCustomPduThreshold
Definition: simIndividualLocalEntityNetInterface.h:170
The overall structure of the DtStateData mechanism is: The DtStateData contains a list of double buff...
Definition: stateData.h:339
This class extends DtVrfEntityPublisher to support the publishing of VR-Forces state properties as ex...
Definition: vrfExtEntityPublisher.h:15
DtExtEntityStateRepository class extends the DtExtEntityBaseStateRepository to be able to handle exte...
Definition: extEntityStateRepository.h:25
Class Description: DtSimObjectNetInterface.
Definition: simObjectNetInterface.h:50
DtTaitBryan stateRepOrientation
Definition: simIndividualLocalEntityNetInterface.h:186
virtual bool isUnit() const
This network interface is for entities, in the DIS - HLA/RPR sense.
Definition: simIndividualLocalEntityNetInterface.h:67
double simTime
Definition: simIndividualLocalEntityNetInterface.h:183
std::vector< Changed > myChangedBits
Definition: simIndividualLocalEntityNetInterface.h:195
bool myPublishDIGuy
Definition: simIndividualLocalEntityNetInterface.h:172
DtVector32 asSeenByRotationalVelocity
Definition: simIndividualLocalEntityNetInterface.h:189
virtual bool isEnvironmental() const
Definition: simIndividualLocalEntityNetInterface.h:69
double translationThreshold
Definition: simIndividualLocalEntityNetInterface.h:191
DtVector stateRepLocation
Definition: simIndividualLocalEntityNetInterface.h:184
virtual bool isAggregate() const
Definition: simIndividualLocalEntityNetInterface.h:112

Document ID: Generated on Tue Sep 24 19:28:17 EDT 2024 from SVN revision 269799
Copyright © 2005-2024 MAK Technologies. All Rights Reserved (www.mak.com)