16 class DtExternalNextFrameState;
34 return myStateDataManager;
42 void setObjectName(
const DtString& objectName);
43 void setSidc(
const DtString& objectName);
44 const DtString& nextFrameObjectName();
45 void setEntityType(
const DtEntityType& et);
46 void setEntityId(
const DtEntityIdentifier&);
47 void setLabel(
const DtString& objectName);
48 void setForceType(DtForceType);
49 void setWorldPosition(
const DtVector&);
50 void setWorldOrientation(
const DtTaitBryan&);
51 void setAppearance(
int);
53 void removeExtendedData(
const DtString& key);
54 void setExtendedData(
const std::map<std::string, std::string>&);
55 void setExtendedData(
const std::map<DtString, DtString>&);
56 void setUserData(
unsigned long long);
65 void setPenStyle(
int);
66 void setColor(
unsigned int);
67 void setFillStyle(
int);
68 void setLineWidth(
int);
69 void setPhysicalLineWidth(
double);
70 void setPhysicalLineHeight(
double);
72 void setProjected(
bool);
73 void setClosedFigure(
bool);
78 virtual std::shared_ptr<DtGuiLocalObject> guiLocalObjectReference();
82 virtual void resetReference();
85 template <
typename T_Component>
90 T_Component* comp = myExternalNextFrameState->addStateComponent<T_Component>(checkWritable, isRemote);
116 void setHostId(
const std::string&);
117 void setHostId(
const DtUUID&);
123 void setCapabilities(
int);
124 void setGuise(
const DtEntityType&);
127 void setWorldVertices(
const std::vector<DtVector>&);
128 void setLocalVertices(
const std::vector<DtVector>&);
130 template <
typename T_Component>
133 if (myExternalNextFrameState)
135 return myExternalNextFrameState->hasStateComponent<T_Component>();
138 return DtGuiSimObject::hasStateComponent<T_Component>();
143 if (myNextFrameSimulatedObjectStateComponent)
145 return myNextFrameSimulatedObjectStateComponent;
147 else if (!myCachedComponents && hasStateComponent<DtSimulatedObjectStateComponent>())
149 return getNextFrameStateComponent<DtSimulatedObjectStateComponent>();
159 if (myNextFrameLocationStateComponent)
161 return myNextFrameLocationStateComponent;
163 else if (!myCachedComponents && hasStateComponent<DtLocationStateComponent>())
165 return getNextFrameStateComponent<DtLocationStateComponent>();
175 if (myNextFrameVrfStateComponent)
177 return myNextFrameVrfStateComponent;
179 else if (!myCachedComponents && hasStateComponent<DtVrfStateComponent>())
181 return getNextFrameStateComponent<DtVrfStateComponent>();
191 if (myNextFrameVrfGeometryStateComponent)
193 return myNextFrameVrfGeometryStateComponent;
195 else if (!myCachedComponents && hasStateComponent<DtVrfGeometryStateComponent>())
197 return getNextFrameStateComponent<DtVrfGeometryStateComponent>();
207 if (myNextFrameEnvironmentalStateComponent)
209 return myNextFrameEnvironmentalStateComponent;
211 else if (!myCachedComponents && hasStateComponent<DtEnvironmentalStateComponent>())
213 return getNextFrameStateComponent<DtEnvironmentalStateComponent>();
223 if (myNextFrameStatePropertiesStateComponent)
225 return myNextFrameStatePropertiesStateComponent;
227 else if (!myCachedComponents && hasStateComponent<DtStatePropertiesStateComponent>())
229 return getNextFrameStateComponent<DtStatePropertiesStateComponent>();
239 if (myNextFrameEntityStateComponent)
241 return myNextFrameEntityStateComponent;
243 else if (!myCachedComponents && hasStateComponent<DtEntityStateComponent>())
245 return getNextFrameStateComponent<DtEntityStateComponent>();
254 template <
typename T_Component>
257 if (myExternalNextFrameState)
259 return myExternalNextFrameState->getStateComponent<T_Component>();
266 template <
typename T_Component>
269 const T_Component* comp = DtGuiSimObject::getStateComponent<T_Component>();
273 comp =
const_cast<DtGuiLocalObject*
>(
this)->getNextFrameStateComponent<T_Component>();
280 LocalObjectModifiedSignalMap::const_iterator iter = myLocalObjectModifiedSignalMap.find(comp);
282 if (iter != myLocalObjectModifiedSignalMap.end())
284 return ((*iter->second.get()).num_slots() > 0);
291 template <
typename T_Component>
294 return signalWhenModified(T_Component::ComponentType());
299 LocalObjectModifiedSignalMap::iterator iter = myLocalObjectModifiedSignalMap.find(comp);
301 if (iter == myLocalObjectModifiedSignalMap.end())
304 iter = myLocalObjectModifiedSignalMap.find(comp);
307 return *(iter->second.get());
313 virtual void setUUID(
const DtUUID&)
override;
318 virtual void cacheComponents()
override;
319 virtual void clearCachedComponents()
override;
320 virtual void slot_localStateDataModified();
321 virtual void completeLocalStateModified(std::set<int> modifiedStateComponentTypes);
322 virtual void slot_stateDataDeleted();
unsigned int StateComponentType
Definition: stateComponent.h:56
UUID is a unique ID wrapper class.
Definition: uuid.h:59
LocalObjectModifiedSignal & signalWhenModified() const
Definition: guiLocalObject.h:292
1) Define the interface class that will be used to represent the next and curent frames. The UNDEFINED_ macros are convenience macros that will define methods that throw exceptions (until they are implemented)
Definition: statePropertiesStateComponent.h:106
Exception thrown when a required method has not been implemented.
Definition: stateDataTypes.h:30
DtExternalNextFrameState * myExternalNextFrameState
Definition: guiLocalObject.h:333
DtEntityStateComponent * nextFrameEntityStateComponent()
Definition: guiLocalObject.h:237
boost::signals2::scoped_connection myStateDataDeletedConnection
Definition: guiLocalObject.h:341
The DtLocationStateComponent interface contains the interface that all DtLocationStateComponents can ...
Definition: locationStateComponent.h:25
virtual void setIsRemoteComponent(bool b)
Sets whether this component represents a remote (non-authoritative) entity.
Definition: stateComponent.h:151
Abstract base interface for the entity state component.
Definition: entityStateComponent.h:141
DtGuiLocalObject(makVrv::DtDe &de, const DtStateDataManager *simManager, const DtEntityIdentifier &id)
Definition: guiLocalObject.h:28
The DtSimulatedObjectStateComponent is an interface that all main components (those that are consider...
Definition: simulatedObjectStateComponent.h:21
DtSimObjectReference mySimObjectReference
Definition: guiLocalObject.h:338
Definition: guiSimObject.h:28
boost::signals2::signal< void(DtGuiLocalObject *)> LocalObjectModifiedSignal
Definition: guiLocalObject.h:290
DtLocationStateComponent * nextFrameLocationStateComponent()
Definition: guiLocalObject.h:157
boost::signals2::signal< void(DtGuiLocalObject *)> signal_localObjectAboutToBeRemoved
Definition: guiLocalObject.h:310
Write-access view of the next-frame state components within a DtStateData. Only the simulation (contr...
Definition: stateData.h:180
virtual DtString markingText() override
Definition: guiLocalObject.h:354
T_Component * getNextFrameStateComponent()
General call to get any component that does not have a method.
Definition: guiLocalObject.h:255
boost::signals2::scoped_connection myStateDataModifiedConnection
Definition: guiLocalObject.h:342
#define DT_DLL_VRFGUICORE
Contains DLL export macros.
Definition: vrfGuiCore.h:25
1) Define the interface class that will be used to represent the next and current frames...
Definition: vrfGeometryStateComponent.h:65
std::map< int, std::unique_ptr< LocalObjectModifiedSignal > > LocalObjectModifiedSignalMap
Definition: guiLocalObject.h:335
bool hasStateComponent() const
Definition: guiLocalObject.h:131
static const DtUUID & nullUUID()
1) Define the interface class that will be used to represent the next and curent frames. The UNDEFINED_ macros are convenience macros that will define methods that throw exceptions (until they are implemented)
Definition: vrfStateComponent.h:72
DtStateData * myStateData
Definition: guiLocalObject.h:345
The overall structure of the DtStateData mechanism is: The DtStateData contains a list of double buff...
Definition: stateData.h:513
boost::signals2::connection myPostTickConnection
Definition: guiLocalObject.h:337
std::shared_ptr< DtGuiLocalObject > myGuiLocalObjectReference
Definition: guiLocalObject.h:339
makVrv::DtDe & myDe
Definition: guiLocalObject.h:334
const T_Component * getStateComponent() const
General call to get any component that does not have a method.
Definition: guiLocalObject.h:267
std::set< const DtFrameStateInterface * > myManagedStateComponents
Definition: guiLocalObject.h:340
DtVrfStateComponent * nextFrameVrfStateComponent()
Definition: guiLocalObject.h:173
T_Component * addStateComponent(bool checkWritable=false, bool isRemote=false)
Adds the given state component by its intrinsic type.
Definition: guiLocalObject.h:86
LocalObjectModifiedSignalMap myLocalObjectModifiedSignalMap
Definition: guiLocalObject.h:336
Definition: guiLocalObject.h:18
Definition: stateComponent.h:52
DtVrfGeometryStateComponent * nextFrameVrfGeometryStateComponent()
Definition: guiLocalObject.h:189
DtStatePropertiesStateComponent * nextFrameStatePropertiesStateComponent()
Definition: guiLocalObject.h:221
DtEnvironmentalStateComponent * nextFrameEnvironmentalStateComponent()
Definition: guiLocalObject.h:205
virtual DtUUIDMarkingTextProvider * clone() const override
Definition: guiLocalObject.h:355
boost::signals2::signal< void(DtGuiLocalObject *)> signal_stateDataDeleted
Definition: guiLocalObject.h:311
DtStateData * stateData()
Definition: guiLocalObject.h:37
DtSimulatedObjectStateComponent * nextFrameSimulatedObjectStateComponent()
Definition: guiLocalObject.h:141
bool wantsModificationSignal(int comp) const
Definition: guiLocalObject.h:278
A list of properties. A DtPropertyInterface object that is a specialized version of DtRwVariableBindi...
Definition: rwProperties.h:122
The DtDe is the core component of any VR-Vantage application. It owns a DtRenderer, DtDeCommunicator, as well as a DtDisplay and other things.
Definition: DtDe.h:76
DtGuiLocalObject(makVrv::DtDe &de, const DtStateDataManager *simManager, const DtUUID &uuid)
Definition: guiLocalObject.h:27
const DtStateDataManager * stateDataManager() const
Definition: guiLocalObject.h:32
DtGuiLocalObjectMarkingTextProvider(const DtGuiLocalObjectMarkingTextProvider &rhs)
Definition: guiLocalObject.h:352
LocalObjectModifiedSignal & signalWhenModified(int comp) const
Definition: guiLocalObject.h:297
Base interface for accessing current or next frame state in a double-buffered state component...
Definition: stateComponent.h:354
DtGuiLocalObjectMarkingTextProvider(const DtGuiLocalObject &lo)
Definition: guiLocalObject.h:351
To allow for faster marking text lookups, the DtUUIDMarkingTextProvider class wraps an object that wi...
Definition: uuid.h:30
Definition: guiLocalObject.h:348
1) Define the interface class that will be used to represent the next and curent frames. The UNDEFINED_ macros are convenience macros that will define methods that throw exceptions (until they are implemented)
Definition: environmentalStateComponent.h:122
This class holds the state data that represents each simulation object in the system.
Definition: stateDataManager.h:76