![]() |
VR-Forces 4.0.4 Class Documentation
|
A controller which carries out the "Flight Command" tasks DtFlyHeadingTask, DtFlyAltitudeTask and DtFlyHeadingAndAltitudeTask for fixed wing aircraft. More...

Public Member Functions | |
| DtFixedWingFlightCommandController (const DtString &name, DtVrfObject *owner, DtSimManager *simManager, DtComponentDescriptor *desc=0, DtReaderWriterRegistry *parentRegistry=0) | |
| (const DtString&,DtVrfObject*,DtSimManager*, | |
| virtual | ~DtFixedWingFlightCommandController () |
| destructor | |
| virtual bool | init () |
| Initializes myFixedWingEntityState. | |
| virtual bool | beginProcessingTask (const DtTaskMessage &task, DtSimTaskStatePtr taskState) |
| Called by the task manager when this controller should start executing the specified task. | |
| virtual void | tick () |
| Only gets actuator values the first time it's called. | |
| virtual DtString | type () const |
| Returns a string identifies the class type of component. | |
| virtual bool | showCurrentTaskInGui () const |
| Overridden from parent class in order to display the current task even after it has completed and is the current default behavior. | |
Static Public Member Functions | |
| static DtSimComponent * | creator (const DtString &name, DtVrfObject *owner, DtSimManager *simManager, DtComponentDescriptor *desc=0, DtReaderWriterRegistry *parentRegistry=0) |
| (const DtString&,DtVrfObject*,DtSimManager*, | |
Protected Member Functions | |
| virtual void | clearTask () |
| Overridden to deactivate the port group when this controller completes a task. | |
Private Member Functions | |
| DtFixedWingFlightCommandController () | |
| Not implemented. | |
| DtFixedWingFlightCommandController (const DtFixedWingFlightCommandController &orig) | |
| Not implemented. | |
| DtFixedWingFlightCommandController & | operator= (const DtFixedWingFlightCommandController &orig) |
| Not implemented. | |
| virtual void | processTaskNotify (const DtSimTask &task, const DtSimComponent ¬ifier) |
| Receive notifications of other tasks starting on the entity so this default behavior can be stopped. | |
| static void | taskNotiyCallback (const DtSimTask &task, const DtSimComponent ¬ifier, void *usr) |
| Receive notifications of other tasks starting on the entity so this default behavior can be stopped. | |
A controller which carries out the "Flight Command" tasks DtFlyHeadingTask, DtFlyAltitudeTask and DtFlyHeadingAndAltitudeTask for fixed wing aircraft.
This controller works slightly differently from most task controllers in the way the tasks interact. Specifically, portions of a previous task are remembered if a number of these tasks are issues in succession. For example, if a Fly Heading task is issued, followed by a Fly Altitude task before the Fly Heading task is complete, the aircraft will continue to turn to the original desired heading while also climbing/descending to the new desired altitude. Additionally, this controller will replace the default behavior of the entity following the completion of any of these tasks. Once the aircraft reaches the desired heading and altitude from the task, taskComplete() will be called, and the task will be considered complete (so the next plan statement will be executed, if a plan is in use) however, the controller will continue to fly the aircraft on the heading and altitude specified until another task takes priority.
| DtFixedWingFlightCommandController::DtFixedWingFlightCommandController | ( | const DtString & | name, |
| DtVrfObject * | owner, | ||
| DtSimManager * | simManager, | ||
| DtComponentDescriptor * | desc = 0, |
||
| DtReaderWriterRegistry * | parentRegistry = 0 |
||
| ) |
(const DtString&,DtVrfObject*,DtSimManager*,
| name | Reader writer name of this component. |
| owner | The DtVrfObject that owns this component |
| simManager | The simulation manager (provides access to terrain, message interface, simulation clock). |
| desc | The component descriptor used to initialize this component. |
| parentRegistry | Pointer to the parent reader writer registry (the containing object that reads/writes this object). |
| virtual DtFixedWingFlightCommandController::~DtFixedWingFlightCommandController | ( | ) | [virtual] |
destructor
Not implemented.
| DtFixedWingFlightCommandController::DtFixedWingFlightCommandController | ( | const DtFixedWingFlightCommandController & | orig | ) | [private] |
Not implemented.
| virtual bool DtFixedWingFlightCommandController::init | ( | ) | [virtual] |
Initializes myFixedWingEntityState.
Reimplemented from DtFixedWingPilotController.
| virtual bool DtFixedWingFlightCommandController::beginProcessingTask | ( | const DtTaskMessage & | task, |
| DtSimTaskStatePtr | taskState | ||
| ) | [virtual] |
Called by the task manager when this controller should start executing the specified task.
| taskState | Used to convey at what point the task should begin execution. If taskState exists, execution of task may begin at some point other than the logical start of the task. If taskState is 0, begin processing at the logical start of the task. |
Reimplemented from DtSingleTaskControllerComponent.
| virtual void DtFixedWingFlightCommandController::tick | ( | ) | [virtual] |
Only gets actuator values the first time it's called.
Call lookupAndCacheProcessSR(), to look up myProcessState, if it hasn't already been found.
Reimplemented from DtFixedWingPilotController.
| virtual DtString DtFixedWingFlightCommandController::type | ( | ) | const [virtual] |
Returns a string identifies the class type of component.
Type values are defined in compTypes.h. DtSimComponent creation functions are registered with the DtSimComponentFactory using the type values as the key.
Reimplemented from DtFixedWingPilotController.
| virtual bool DtFixedWingFlightCommandController::showCurrentTaskInGui | ( | ) | const [virtual] |
Overridden from parent class in order to display the current task even after it has completed and is the current default behavior.
Reimplemented from DtTaskControllerComponent.
| static void DtFixedWingFlightCommandController::taskNotiyCallback | ( | const DtSimTask & | task, |
| const DtSimComponent & | notifier, | ||
| void * | usr | ||
| ) | [static] |
Receive notifications of other tasks starting on the entity so this default behavior can be stopped.
| virtual void DtFixedWingFlightCommandController::processTaskNotify | ( | const DtSimTask & | task, |
| const DtSimComponent & | notifier | ||
| ) | [virtual] |
Receive notifications of other tasks starting on the entity so this default behavior can be stopped.
| static DtSimComponent* DtFixedWingFlightCommandController::creator | ( | const DtString & | name, |
| DtVrfObject * | owner, | ||
| DtSimManager * | simManager, | ||
| DtComponentDescriptor * | desc = 0, |
||
| DtReaderWriterRegistry * | parentRegistry = 0 |
||
| ) | [static] |
(const DtString&,DtVrfObject*,DtSimManager*,
| name | Reader writer name of this component. |
| owner | The DtVrfObject that owns this component |
| simManager | The simulation manager (provides access to terrain, message interface, simulation clock). |
| desc | The component descriptor used to initialize this component. |
| parentRegistry | Pointer to the parent reader writer registry (the containing object that reads/writes this object). |
Reimplemented from DtFixedWingPilotController.
| virtual void DtFixedWingFlightCommandController::clearTask | ( | ) | [protected, virtual] |
Overridden to deactivate the port group when this controller completes a task.
Reimplemented from DtFixedWingPilotController.
| DtFixedWingFlightCommandController& DtFixedWingFlightCommandController::operator= | ( | const DtFixedWingFlightCommandController & | orig | ) | [private] |
Not implemented.