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);
54  virtual ~DtSimIndividualLocalEntityNetInterface() override;
55 
57  virtual void updateNet() override;
58 
60  virtual void forceUpdate() override;
61 
64  virtual void updatePublisher() override;
65 
67  virtual bool isUnit() const override { return false; }
68  virtual bool isEntity() const override { return true; }
69  virtual bool isEnvironmental() const override { return false; }
70 
71  virtual bool wantsToCreatePublisher() const override;
72 
78  virtual bool createPublisher(const DtEntityIdentifier& id = DtEntityIdentifier::nullId()) override;
79  virtual bool createPublisher(
80 #if DtHLA
81  DtHlaObjectWithStateRep* obj,
82  DtHlaObjectWithStateRep* extendedAttributes = nullptr
83 #else
85 #endif
86  ) override;
87 
89  virtual void destroyPublisher() override;
90 
92  virtual DtObjectPublisher* publisher() override;
93 
103  virtual bool setEntityPublisher(DtVrfExtEntityPublisher * publisher);
104 
108  virtual void setupNetworkRepository() override;
109 
111  virtual DtVrfExtEntityPublisher * entityPublisher() const;
112 
115  virtual DtExtEntityStateRepository * individualNetworkState() const;
116 
118  virtual void updateUuid() override;
119 
120  virtual bool isAggregate() const override { return false; }
121 
124  virtual DtString type() const override;
125 
126  #if DtHLA
127  virtual RTI::ObjectClassHandle objectClassHandle() const override;
129  #endif
130 
135  isIndividualLocalEntityNetInterface(const DtSimObjectNetInterface *
136  objNetInterface);
137 
138  static DtSimObjectNetInterface * creator(
139  DtStateData* vrfObject, DtVrlinkNetworkInterface* mgr, bool publishObject);
140 
141 #if DtDIS
142  virtual void sendFinalPduOnDestruction(bool) override;
144 #endif
145 
149  static void SetProfilePdus(bool onOf, double pduTimeCheck = 1.0, int numberOfPacketsOverTime = 0
150 #if DtDIS
151  , bool includeSummary = false
152 #endif
153  );
154 
155  virtual std::vector<DtGlobalObjectDesignator> associatedGlobalObjectDesignators() const override;
156 
157  protected:
158 
159  virtual bool updateVrfDataAsSeenByRemote();
160 
164  virtual void updateArtPartsNetState();
165 
166  virtual bool updateDIGuyState();
167 
168  virtual void updateAirVehicleLightingNetState();
169 
170  virtual void updateGroundVehicleLightingNetState();
171 
172  virtual void updateAisDataNetState();
173 
174  virtual void updateSurfaceVehicleLightingNetState();
175 
176  virtual void firstTimeInitialize();
177 
178  protected:
179 
181 
187 
188  int myNumberOfPdusSent = 0;
189  double myFirstTimePduSent = 0;
190 
191 #if DtDIS
192  typedef struct
193  {
194  int bits;
195  double simTime;
198  DtTaitBryan stateRepOrientation;
200  DtTaitBryan asSeenByOrientation;
202  double rotTrace;
205  } Changed;
206 
207  std::vector<Changed> myChangedBits;
208 #else
209  int myNumberOfAttributesPdusSent = 0;
210  double myFirstTimeAttributePduSent = 0;
211 #endif
212  };
213 }
int bits
Definition: simIndividualLocalEntityNetInterface.h:194
virtual bool isEnvironmental() const override
Definition: simIndividualLocalEntityNetInterface.h:69
double orientationThreshold
Definition: simIndividualLocalEntityNetInterface.h:204
Class Description: DtSimLocalEntityNetInterface Derived from DtSimEntityNetInterface, DtSimLocalEntityNetInterface provides an interface between a local entity and its network (VR-Link) representation. This is an abstract class whose deriving classes will represent different types of entities, such as individual, aggregate, and eventually, environmental.
Definition: simLocalEntityNetInterface.h:45
Definition: simIndividualLocalEntityNetInterface.h:35
double rotTrace
Definition: simIndividualLocalEntityNetInterface.h:202
DtTaitBryan asSeenByOrientation
Definition: simIndividualLocalEntityNetInterface.h:200
bool myIsFreezeMovementPublished
Definition: simIndividualLocalEntityNetInterface.h:186
Definition: simIndividualLocalEntityNetInterface.h:192
DtVector32 stateRepRotationalVelocity
Definition: simIndividualLocalEntityNetInterface.h:199
DtVector asSeenByLocation
Definition: simIndividualLocalEntityNetInterface.h:197
bool myFirstTimeInitialize
Definition: simIndividualLocalEntityNetInterface.h:185
bool myFirstTick
Definition: simIndividualLocalEntityNetInterface.h:183
DtVrfExtEntityPublisher * myEntityPublisher
Definition: simIndividualLocalEntityNetInterface.h:180
static DtTime theDiGuyCustomPduThreshold
Definition: simIndividualLocalEntityNetInterface.h:182
The overall structure of the DtStateData mechanism is: The DtStateData contains a list of double buff...
Definition: stateData.h:513
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:198
Contains the DtSimLocalEntityNetInterface class declaration.
virtual bool isUnit() const override
This network interface is for entities, in the DIS - HLA/RPR sense.
Definition: simIndividualLocalEntityNetInterface.h:67
double simTime
Definition: simIndividualLocalEntityNetInterface.h:195
std::vector< Changed > myChangedBits
Definition: simIndividualLocalEntityNetInterface.h:207
bool myPublishDIGuy
Definition: simIndividualLocalEntityNetInterface.h:184
DtVector32 asSeenByRotationalVelocity
Definition: simIndividualLocalEntityNetInterface.h:201
virtual bool isAggregate() const override
Definition: simIndividualLocalEntityNetInterface.h:120
double translationThreshold
Definition: simIndividualLocalEntityNetInterface.h:203
virtual bool isEntity() const override
Definition: simIndividualLocalEntityNetInterface.h:68
DtVector stateRepLocation
Definition: simIndividualLocalEntityNetInterface.h:196

Document ID: Generated on Thu Oct 15 21:27:02 EDT 2026 from SVN revision 296421
Copyright © 2005-2026 MAK Technologies. All Rights Reserved (www.mak.com)