VR-Forces Developer's Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
rotaryWingFlightPSR.h
Go to the documentation of this file.
1 /*******************************************************************************
2 ** Copyright (c) 2015 MAK Technologies, Inc.
3 ** All rights reserved.
4 *******************************************************************************/
5 
8 
9 #pragma once
10 
12 #include "vrfobjcore/simObject.h"
13 #include <readerWriter/rwString.h>
14 #include <readerWriter/rwBoolean.h>
15 #include "readerWriter/rwVector.h"
17 #include <readerWriter/rwInt.h>
18 #include <readerWriter/rwReal.h>
19 #include <vrfutil/rwUUID.h>
21 
26 
28 
31 {
32 public:
35  {
43  StateLanding
44  };
45 
48  const DtString& rwName = DtString::nullString(),
49  DtReaderWriterRegistry* parentRegistry = 0);
50 
53  const DtString& rwName = DtString::nullString(),
54  DtReaderWriterRegistry* parentRegistry = 0);
55 
57  virtual ~DtRotaryWingFlightPSR();
58 
61 
64  const DtString& rwName = DtString::nullString(),
65  DtReaderWriterRegistry* parentRegistry = 0) const;
66 
69  virtual DtString type() const;
70 
74  virtual void setControlObject(const DtUUID&);
75 
77  virtual DtSimObjectReference controlObject() const;
78 
81  virtual void setRoute(const DtUUID&);
82 
84  virtual DtSimObjectReference route() const;
85 
89  virtual void setRouteVertices(const DtLocalVectorIterator& routeIterator,
90  bool useCurrentVertex = false);
91  virtual const DtLocalVertexList& routeVertices() const;
92 
94  virtual void emptyRouteVertices();
95 
98  virtual DtLocalVectorIterator* routeState() const;
99 
102  virtual void setWasMovingToward(bool flag);
103  virtual bool wasMovingToward() const;
104 
107  virtual void setStartingPoint(const DtVector& startingPoint);
108  virtual const DtVector& startingPoint() const;
109 
112  virtual void setDoContinueMoving(const bool go);
113  virtual bool doContinueMoving() const;
114 
116  virtual void setReverseFlag(bool flag);
117  virtual bool reverseFlag() const;
118 
120  virtual void setHeadingToTurnTo(double);
121  virtual double headingToTurnTo() const;
122 
126  virtual void setWorldAimingPoint(const DtVector& pnt);
127  virtual const DtVector& worldAimingPoint() const;
128 
130  virtual void setFirstWaypoint(const DtUUID&);
131  virtual DtSimObjectReference firstWaypoint() const;
132 
134  virtual void setSecondWaypoint(const DtUUID&);
135  virtual DtSimObjectReference secondWaypoint() const;
136 
138  virtual void setEntityToFollow(const DtUUID&);
139  virtual DtSimObjectReference entityToFollow() const;
140 
143  virtual void setFollowOffset(const DtVector& offset);
144  virtual const DtVector& followOffset() const;
145 
147  virtual void setMovingToAltitude(bool movingToAlt);
149  virtual bool movingToAltitude() const;
150 
152  virtual void setMoveToAltitudeValue(double altitude);
154  virtual double moveToAltitudeValue() const;
155 
157  virtual void setOrbitRadius(const double r);
158  virtual double orbitRadius() const;
159 
162  virtual void setLandingState(DtRotaryWingLandingControllerState state);
163  virtual DtRotaryWingLandingControllerState landingState() const;
165 
167 
168  virtual bool isSpinningUp() const;
169  virtual void setIsSpinningUp(bool b);
171 
173 
174  virtual double spinupCompleteTime() const;
175  virtual void setSpinupCompleteTime(double t);
177 
179  virtual void putSelf(std::string& fp, int indentLevel = 0,
180  bool writeUnspecified = false, const DtFilename& path = DtReaderWriter::appPath());
181 
182 public:
183 
185  static DtVrfProcessStateRepository* creator (const DtString& rwName,
186  DtLocalObject* vrfObject, DtReaderWriterRegistry* parentRegistry);
187 
188 protected:
189 
195 
209 
213 
216 
220 
224 
231 
240 
243 
246 
248 
250 
256 };
UUID is a unique ID wrapper class.
Definition: uuid.h:59
DtRwReal myOrbitRadius
Definition: rotaryWingFlightPSR.h:247
DtRwBoolean myMovingToAltitude
Definition: rotaryWingFlightPSR.h:244
DtRwBoolean myDoContinueMoving
A flag to indicate if the entity should continue moving when it reaches its goal. ...
Definition: rotaryWingFlightPSR.h:219
File: lclVecIter.h.
Definition: localVectorIterator.h:25
DtRwBoolean myReverseFlag
Moved here from DtRotaryWingPatrolRouteController (rotWingPtrlRt.h).
Definition: rotaryWingFlightPSR.h:223
The DtSimObjectReference is a shared pointer that can be used amongst many object for access to the u...
Definition: simObjectReference.h:26
Definition: rotaryWingFlightPSR.h:30
DtRwInt myCurrentVertex
Read/write variables to capture route state.
Definition: rotaryWingFlightPSR.h:208
Definition: readerWriterRegistry.h:39
Contains the DtUUID class declaration.
DtRwInt myLandingState
Definition: rotaryWingFlightPSR.h:249
DtLocalVertexList myVertices
my copy of the current route
Definition: rotaryWingFlightPSR.h:206
DtRwReal mySpinupCompleteTime
If myIsSpinningUp is true, this is the simulation time at which spinup is complete.
Definition: rotaryWingFlightPSR.h:255
DtRwSimObjectReference mySecondWaypoint
Definition: rotaryWingFlightPSR.h:227
DtRwVector myFollowOffsetVector
Following offset vector (in body coordinates of the entity to follow, in meters). ...
Definition: rotaryWingFlightPSR.h:239
DtLocalVectorIterator * myRouteState
Route state used to get info about the current route we&#39;re trying to follow (e.g. which vertex to mov...
Definition: rotaryWingFlightPSR.h:204
Definition: rwVector.h:23
Specialized reader/writer version of the shared object reference that will encapsulate the actual sha...
Definition: rwSimObjectReference.h:21
#define DT_DLL_vrfobjcore
This file is used to determine how to build.
Definition: vrfobjcoreDefines.h:24
DtRwSimObjectReference myFirstWaypoint
Moved here from DtRotaryWingPatrolBetweenController (rotWngPtlBtwn.h).
Definition: rotaryWingFlightPSR.h:226
DtRwBoolean myIsSpinningUp
True if the RW is currently in the processing of spinning up.
Definition: rotaryWingFlightPSR.h:253
DtRwSimObjectReference myControlObject
Moved here from DtRotaryWingMoveToControllerComponent (rotWngMvToCtl.h).
Definition: rotaryWingFlightPSR.h:194
Description: Readable, Writable int.
Definition: rwInt.h:25
Zeroing out pitch movement at the settling location.
Definition: rotaryWingFlightPSR.h:41
virtual DtVrfProcessStateRepository * clone(const DtString &rwName=DtString::nullString(), DtReaderWriterRegistry *parentRegistry=0) const =0
Moving to a point attached to a parent, or the end of a route, or a settling location above the landi...
Definition: rotaryWingFlightPSR.h:39
DtRotaryWingLandingControllerState
State for the DtRotaryWingLandingController.
Definition: rotaryWingFlightPSR.h:34
DtRwVector myWorldAimingPoint
World point for move to location tasks.
Definition: rotaryWingFlightPSR.h:242
DtRwReal myMoveToAltitudeValue
Definition: rotaryWingFlightPSR.h:245
virtual void putSelf(std::string &fp, int indentLevel=0, bool writeUnspecified=false, const DtFilename &path=DtFilename::nullFilename())
Top level call to write itself to file. If write unspecified is true, will write entries that are uns...
DtRwSimObjectReference myEntityToFollow
Set when a patrol between task is received. Reuse the myReverseFlag from DtRotaryWingPatrolRouteContr...
Definition: rotaryWingFlightPSR.h:236
Description: Readable, Writable DtReal (double)
Definition: rwReal.h:27
Class DtVrfProcessStateRepository: Abstract base class for all process state repositories. Process state repositories represent (potentially) shared, savable information for one or more components functioning together to achieve some process or set of processes; such as aiming and firing a weapon; moving an object; or just waiting a specified amount of time.
Definition: vrfProcessStateRepository.h:45
Description: Readable, Writable bool.
Definition: rwBoolean.h:26
DtRwBoolean myWasMovingToward
A flag indicating whether or not the last tick was moving toward the current waypoint.
Definition: rotaryWingFlightPSR.h:212
DtRwReal myHeadingToTurnTo
Definition: rotaryWingFlightPSR.h:251
virtual DtString type() const =0
Returns the string type of the repository, as defined in procSRTypes.h.
Definition: rotaryWingFlightPSR.h:36
voidpf uLong offset
Definition: ioapi.h:42
class DtLocalVertexList:
Definition: localVertexList.h:20
DtRwVector myStartingPoint
A vector indicating the starting point of the current segment.
Definition: rotaryWingFlightPSR.h:215
File: rwVector.h.
static const DtFilename & appPath()
Gets the current working directory. The first time this accessor is called, it determines the current...
const DtVrfProcessStateRepository & operator=(const DtVrfProcessStateRepository &orig)
A locally simulated VRF object. Holds all internal and external data for the object, and provides access to both the current frame and next frame state data for the object. All current frame data is read-only, and next-frame data can be written to. No thread safety guarantees are made on this object during the simulation frame and it should only be accessed by the thread that is simulating the object.
Definition: localObject.h:86
DtRwSimObjectReference myRoute
Moved here from DtRotaryWingMoveAlongControllerComponent (rotaryWingFlightPSR.h). ...
Definition: rotaryWingFlightPSR.h:201

Document ID: Generated on Wed Mar 27 22:49:11 EDT 2024 from SVN revision 264633
Copyright © 2005-2024 MAK Technologies. All Rights Reserved (www.mak.com)