VR-Forces Developer's Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
List of all members | Public Types | Public Member Functions | Protected Member Functions | Protected Attributes | Friends
DtScriptedMovementPhase Class Reference

The DtScriptedMovementObject will contain information about an object that can be used for scripted movement. This file will contain classes to define the configuration for the csv file being loaded as well as the phases of deployment and movement of scripted objects.

Information is saved in XML format The DtScriptedMovementPhase class defines a deployment phase for this scripted object. Each phase will create a new object and assign a movement file to it. The phase will be considered to be started at the first rows time in the movement file, offset from when the scripted movement began. The times are considered simulation time offsets

Public Types

enum  CompletionRule {
  Detonate = 1, DetonateAndRemove, Remove, StayAroundAtCurrentSpeed,
  StayAroundAndStop
}
 
enum  ClampType {
  PhaseGroundClampHighFidelity = 1, PhaseGroundClampLowFidelity = 2, PhaseAltitudeIsAboveTerrain = 3, PhaseGroundClampGeodeticNone = 4,
  PhaseClampWhileAltitudeChangeIsZero = 5, PhasePhasedArrayRadarFaceCartesian = 6, PhaseGroundClampTopographicNone = 7
}
 

Public Member Functions

 DtScriptedMovementPhase ()
 
virtual ~DtScriptedMovementPhase ()
 
 DtScriptedMovementPhase (const DtScriptedMovementPhase &)
 
DtScriptedMovementPhaseoperator= (const DtScriptedMovementPhase &)
 
virtual void setMovementFile (const std::string &)
 
virtual const std::string & movementFile () const
 
virtual void setFileConfiguration (const std::string &)
 
virtual const std::string & fileConfiguration () const
 
virtual void setCompletionRule (CompletionRule)
 
virtual CompletionRule completionRule () const
 
virtual void setClampType (ClampType)
 
virtual ClampType clampType () const
 
virtual void setEntityType (const DtEntityType &)
 
virtual DtEntityType entityType () const
 
virtual bool canBePerformed (double deltaTime) const
 
virtual bool canStillBePerformed (double deltatTime) const
 
virtual bool loadMovementFile (const DtFilename &rootPath, const std::string &, int rowsToLoad=-1)
 
virtual bool isLoaded () const
 
virtual double simTime (int row) const
 
virtual DtVector bodyOffsetVector (int row) const
 
virtual DtTaitBryan orientationOffset (int row) const
 
virtual void setSimulationStartTimeOffset (double t)
 
virtual double simulationStartTimeOffset () const
 
virtual void setFileConfiguration (const DtString &)
 
const DtMovementFilemovementFileData () const
 
DtMovementFilemovementFileData ()
 

Protected Member Functions

template<class Archive >
void serialize (Archive &ar, const unsigned int version)
 

Protected Attributes

std::string myMovementFile
 
CompletionRule myCompletionRule
 
ClampType myClampType
 
std::string myEntityType
 
std::string myFileConfiguration
 
DtMovementFile myMovementFileData
 
DtScriptedMovementFileConfiguration myScriptedMovementFileConfiguration
 
double mySimulationStartTimeOffset
 

Friends

class boost::serialization::access
 

Member Enumeration Documentation

Enumerator
Detonate 
DetonateAndRemove 
Remove 
StayAroundAtCurrentSpeed 
StayAroundAndStop 
Enumerator
PhaseGroundClampHighFidelity 
PhaseGroundClampLowFidelity 
PhaseAltitudeIsAboveTerrain 
PhaseGroundClampGeodeticNone 
PhaseClampWhileAltitudeChangeIsZero 

If the altitude change is 0, clamp the entity to the ground at that location, else use as offset from location of last ground clamp position.

PhasePhasedArrayRadarFaceCartesian 
PhaseGroundClampTopographicNone 

Constructor & Destructor Documentation

DtScriptedMovementPhase::DtScriptedMovementPhase ( )

CTOR.

virtual DtScriptedMovementPhase::~DtScriptedMovementPhase ( )
virtual

DTOR.

DtScriptedMovementPhase::DtScriptedMovementPhase ( const DtScriptedMovementPhase )

Copy constructor.

Member Function Documentation

DtScriptedMovementPhase& DtScriptedMovementPhase::operator= ( const DtScriptedMovementPhase )

Assignment operator.

virtual void DtScriptedMovementPhase::setMovementFile ( const std::string &  )
virtual

Sets the movement file to use. The file is considered relative to where the original scripted movement object was loaded from. If there is no path for the original scripted movement object the applications start path will be used.

virtual const std::string& DtScriptedMovementPhase::movementFile ( ) const
virtual
virtual void DtScriptedMovementPhase::setFileConfiguration ( const std::string &  )
virtual

Sets the configuration to use as defined in the configurations loaded at simulation startup. If configuration file does not exist will use default based on movement file extension.

virtual const std::string& DtScriptedMovementPhase::fileConfiguration ( ) const
virtual
virtual void DtScriptedMovementPhase::setCompletionRule ( CompletionRule  )
virtual

Sets what to do with the object when the movement is complete. Default is DetonateAndRemove.

virtual CompletionRule DtScriptedMovementPhase::completionRule ( ) const
virtual
virtual void DtScriptedMovementPhase::setClampType ( ClampType  )
virtual

Sets how to clamp the object.

virtual ClampType DtScriptedMovementPhase::clampType ( ) const
virtual
virtual void DtScriptedMovementPhase::setEntityType ( const DtEntityType &  )
virtual

Sets the type of object to create as part of this phase.

virtual DtEntityType DtScriptedMovementPhase::entityType ( ) const
virtual
virtual bool DtScriptedMovementPhase::canBePerformed ( double  deltaTime) const
virtual

Returns true if the phase can be performed at this simTime. Movement file must be loaded for this check to succeed.

virtual bool DtScriptedMovementPhase::canStillBePerformed ( double  deltatTime) const
virtual

Returns true if the phase can still be performed, even though it might not be able to be performed yet.

virtual bool DtScriptedMovementPhase::loadMovementFile ( const DtFilename &  rootPath,
const std::string &  ,
int  rowsToLoad = -1 
)
virtual

Load the movement file and return true if loaded. If rowsToLoad is -1 loads all rows, else just loads up the number of specified rows.

virtual bool DtScriptedMovementPhase::isLoaded ( ) const
virtual

Returns whether or not file is loaded.

virtual double DtScriptedMovementPhase::simTime ( int  row) const
virtual

Returns the sim time (in seconds) at the specified row. File must be loaded, else will return 0.

virtual DtVector DtScriptedMovementPhase::bodyOffsetVector ( int  row) const
virtual

Returns the body offset vector at the specified row. If file is not loaded will return NULL vector.

virtual DtTaitBryan DtScriptedMovementPhase::orientationOffset ( int  row) const
virtual

Returns the orientation offset for a given row. Assumed to be offset from current orientation. The orientation returned is in topographic projection.

virtual void DtScriptedMovementPhase::setSimulationStartTimeOffset ( double  t)
virtual

Offset time to add to the simTime in the given row. Default is 0.

virtual double DtScriptedMovementPhase::simulationStartTimeOffset ( ) const
virtual

Offset time.

virtual void DtScriptedMovementPhase::setFileConfiguration ( const DtString )
virtual

Sets a new file configuration for this phase.

const DtMovementFile& DtScriptedMovementPhase::movementFileData ( ) const
inline

Returns movement file.

DtMovementFile& DtScriptedMovementPhase::movementFileData ( )
inline
template<class Archive >
void DtScriptedMovementPhase::serialize ( Archive &  ar,
const unsigned int  version 
)
inlineprotected

When the class Archive corresponds to an output archive, the & operator is defined similar to <<. Likewise, when the class Archive is a type of input archive the & operator is defined similar to >>.

Friends And Related Function Documentation

friend class boost::serialization::access
friend

Serialization/Deserialization //!

Member Data Documentation

std::string DtScriptedMovementPhase::myMovementFile
protected
CompletionRule DtScriptedMovementPhase::myCompletionRule
protected
ClampType DtScriptedMovementPhase::myClampType
protected
std::string DtScriptedMovementPhase::myEntityType
protected
std::string DtScriptedMovementPhase::myFileConfiguration
protected
DtMovementFile DtScriptedMovementPhase::myMovementFileData
protected
DtScriptedMovementFileConfiguration DtScriptedMovementPhase::myScriptedMovementFileConfiguration
protected
double DtScriptedMovementPhase::mySimulationStartTimeOffset
protected

The documentation for this class was generated from the following file:

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)