![]() |
VR-Forces 4.5 Class Documentation
|
! VectorOffset3D is a direction vector that is relative to some direction specified by a Vector3D. More...

Public Member Functions | |
| DtVectorOffset3D () | |
| DtVectorOffset3D (const DtVector &vect) | |
| This constructor assumes the vector has components in the order right, forward, up. | |
| DtVectorOffset3D (const DtVectorOffset3D &orig) | |
| ~DtVectorOffset3D () | |
| DtVectorOffset3D & | operator= (const DtVectorOffset3D &orig) |
| DtVectorOffset3D (double right, double forward, double up) | |
| Constructor visible to the script. | |
| void | setFromBodyVector (const DtVector &vect) |
| Set the component values from a DIS body vector; the vector components here should be forward-right-down. | |
| DtVectorOffset3D | makeCopy () const |
| The assignment operator and copy constructor above, are useful in the expected way for C++ code, but Lua just copies the references to objects, so a special copy function is needed. | |
| DtVectorOffset3D | addOffset (const DtVectorOffset3D offset) const |
| Add another offset vector. | |
| DtVectorOffset3D | crossVectorOffset3D (const DtVectorOffset3D &vec) const |
| Takes the cross product of given vector with this one. | |
| double | dotVectorOffset3D (const DtVectorOffset3D &vec) const |
| Takes the dot product of the given vector with this one. | |
| DtVector3D | makeVectorRefToDirection (const DtVector3D dirVect) const |
| Make this offset into an earth-referenced vector by transforming it to the direction of the provided vector. | |
| DtVector | vector () const |
| bool | operator== (const DtVectorOffset3D &) const |
| bool | operator!= (const DtVectorOffset3D &orig) const |
| double | getRight (void) const |
| Get and set functions for components. | |
| void | setRight (const double right) |
| double | getForward (void) const |
| void | setForward (const double forward) |
| double | getUp (void) const |
| void | setUp (const double up) |
| DtVectorOffset3D | getScaled (const double scale) const |
| Vector modification functions. | |
| DtVectorOffset3D | getNegated (void) const |
| DtVectorOffset3D | getUnit (void) const |
Public Member Functions inherited from DtAsciiSerializable | |
| DtAsciiSerializable () | |
| The implementer of this interface should be sure to create a creator function to create an empty object that returns a pointer to this interface. | |
| DtAsciiSerializable (const DtAsciiSerializable &orig) | |
| virtual | ~DtAsciiSerializable () |
| virtual std::string | objectTypeC () const |
| Returns a std::string version of the objectType. | |
| virtual void | init (void *userData) |
| This function is called right after the object is constructed during the deserialization process, but before deserialize() is called. | |
Protected Attributes | |
| DtVector | myVector |
| Stores components right, forward, and up. | |
| DtString | objectType () const |
| Inherited from DtAsciiSerializable. | |
| DtString | serialize () |
| Returns a string serialized version of this class. | |
| bool | deserialize (const DtString &data) |
| Returns true if it could fill its members with the data contained in the string. | |
| static DtAsciiSerializable * | creator () |
| Returns a new object of this type with default values. | |
Additional Inherited Members | |
Static Public Member Functions inherited from DtObjectDebugger< DtAsciiSerializable > | |
| static DtObjectCounter::CounterType | ObjectCount () |
| static const DtObjectContainer * | ObjectContainer () |
Static Public Member Functions inherited from DtObjectDebugger< DtVectorOffset3D > | |
| static DtObjectCounter::CounterType | ObjectCount () |
| static const DtObjectContainer * | ObjectContainer () |
Protected Member Functions inherited from DtObjectDebugger< DtAsciiSerializable > | |
| DtObjectDebugger () | |
| DtObjectDebugger (const DtObjectDebugger &) | |
| ~DtObjectDebugger () | |
Protected Member Functions inherited from DtObjectDebugger< DtVectorOffset3D > | |
| DtObjectDebugger () | |
| DtObjectDebugger (const DtObjectDebugger &) | |
| ~DtObjectDebugger () | |
! VectorOffset3D is a direction vector that is relative to some direction specified by a Vector3D.
E.g. this may be a "body" vector that is situated on an entity oriented in the world. A vectorOffset3D can be used to generate a direction in the world by transforming it to the direction of a vector3D or adding it to a vector3D.
| DtVectorOffset3D::DtVectorOffset3D | ( | ) |
| DtVectorOffset3D::DtVectorOffset3D | ( | const DtVector & | vect | ) |
This constructor assumes the vector has components in the order right, forward, up.
| DtVectorOffset3D::DtVectorOffset3D | ( | const DtVectorOffset3D & | orig | ) |
| DtVectorOffset3D::~DtVectorOffset3D | ( | ) |
Constructor visible to the script.
| DtVectorOffset3D& DtVectorOffset3D::operator= | ( | const DtVectorOffset3D & | orig | ) |
| void DtVectorOffset3D::setFromBodyVector | ( | const DtVector & | vect | ) |
Set the component values from a DIS body vector; the vector components here should be forward-right-down.
| DtVectorOffset3D DtVectorOffset3D::makeCopy | ( | ) | const |
The assignment operator and copy constructor above, are useful in the expected way for C++ code, but Lua just copies the references to objects, so a special copy function is needed.
|
virtual |
|
virtual |
Returns a string serialized version of this class.
Implements DtAsciiSerializable.
Returns true if it could fill its members with the data contained in the string.
False otherwise.
Implements DtAsciiSerializable.
|
static |
Returns a new object of this type with default values.
| double DtVectorOffset3D::getRight | ( | void | ) | const |
Get and set functions for components.
| void DtVectorOffset3D::setRight | ( | const double | right | ) |
| double DtVectorOffset3D::getForward | ( | void | ) | const |
| void DtVectorOffset3D::setForward | ( | const double | forward | ) |
| double DtVectorOffset3D::getUp | ( | void | ) | const |
| void DtVectorOffset3D::setUp | ( | const double | up | ) |
| DtVectorOffset3D DtVectorOffset3D::getScaled | ( | const double | scale | ) | const |
Vector modification functions.
Return a new vector.
| DtVectorOffset3D DtVectorOffset3D::getNegated | ( | void | ) | const |
| DtVectorOffset3D DtVectorOffset3D::getUnit | ( | void | ) | const |
| DtVectorOffset3D DtVectorOffset3D::addOffset | ( | const DtVectorOffset3D | offset | ) | const |
Add another offset vector.
| DtVectorOffset3D DtVectorOffset3D::crossVectorOffset3D | ( | const DtVectorOffset3D & | vec | ) | const |
Takes the cross product of given vector with this one.
| double DtVectorOffset3D::dotVectorOffset3D | ( | const DtVectorOffset3D & | vec | ) | const |
Takes the dot product of the given vector with this one.
| DtVector3D DtVectorOffset3D::makeVectorRefToDirection | ( | const DtVector3D | dirVect | ) | const |
Make this offset into an earth-referenced vector by transforming it to the direction of the provided vector.
"Direction" assumes no roll.
| DtVector DtVectorOffset3D::vector | ( | ) | const |
| bool DtVectorOffset3D::operator== | ( | const DtVectorOffset3D & | ) | const |
|
inline |
|
protected |
Stores components right, forward, and up.