VR-Forces 4.1.1 Class Documentation
List of all members | Public Member Functions | Protected Attributes
DtVectorOffset3D Class Reference

VectorOffset3D is a direction vector that is relative to some direction specified by a Vector3D. More...

Inheritance diagram for DtVectorOffset3D:
Inheritance graph
[legend]

Public Member Functions

 DtVectorOffset3D ()
 DtVectorOffset3D (const DtVector &vect)
 DtVectorOffset3D (const DtVectorOffset3D &orig)
 ~DtVectorOffset3D ()
DtVectorOffset3Doperator= (const DtVectorOffset3D &orig)
 DtVectorOffset3D (double right, double forward, double up)
 Constructor visible to the script.
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
double getRight (void) const
 Get and set functions for components.
void setRight (const double right)
 Get and set functions for components.
double getForward (void) const
 Get and set functions for components.
void setForward (const double forward)
 Get and set functions for components.
double getUp (void) const
 Get and set functions for components.
void setUp (const double up)
 Get and set functions for components.
DtVectorOffset3D getScaled (const double scale) const
 Vector modification functions.
DtVectorOffset3D getNegated (void) const
 Vector modification functions.
DtVectorOffset3D getUnit (void) const
 Vector modification functions.
- 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 ()

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 DtAsciiSerializablecreator ()
 Returns a new object of this type with default values.

Detailed Description

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.

Constructor & Destructor Documentation

DtVectorOffset3D::DtVectorOffset3D ( )
DtVectorOffset3D::DtVectorOffset3D ( const DtVector vect)
DtVectorOffset3D::DtVectorOffset3D ( const DtVectorOffset3D orig)
DtVectorOffset3D::~DtVectorOffset3D ( )
DtVectorOffset3D::DtVectorOffset3D ( double  right,
double  forward,
double  up 
)

Constructor visible to the script.

Member Function Documentation

DtVectorOffset3D& DtVectorOffset3D::operator= ( const DtVectorOffset3D orig)
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.

DtString DtVectorOffset3D::objectType ( ) const
virtual

Inherited from DtAsciiSerializable.

Returns "DtVectorOffset3D"

Implements DtAsciiSerializable.

DtString DtVectorOffset3D::serialize ( )
virtual

Returns a string serialized version of this class.

Implements DtAsciiSerializable.

bool DtVectorOffset3D::deserialize ( const DtString data)
virtual

Returns true if it could fill its members with the data contained in the string.

False otherwise.

Implements DtAsciiSerializable.

static DtAsciiSerializable* DtVectorOffset3D::creator ( )
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)

Get and set functions for components.

double DtVectorOffset3D::getForward ( void  ) const

Get and set functions for components.

void DtVectorOffset3D::setForward ( const double  forward)

Get and set functions for components.

double DtVectorOffset3D::getUp ( void  ) const

Get and set functions for components.

void DtVectorOffset3D::setUp ( const double  up)

Get and set functions for components.

DtVectorOffset3D DtVectorOffset3D::getScaled ( const double  scale) const

Vector modification functions.

Return a new vector.

DtVectorOffset3D DtVectorOffset3D::getNegated ( void  ) const

Vector modification functions.

Return a new vector.

DtVectorOffset3D DtVectorOffset3D::getUnit ( void  ) const

Vector modification functions.

Return a new vector.

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

Member Data Documentation

DtVector DtVectorOffset3D::myVector
protected

Stores components right, forward, and up.


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

Document ID: Generated on Mon Apr 8 19:24:01 EDT 2013 from SVN revision 125877
Copyright © 2005-2013 VT MÄK. All Rights Reserved (www.mak.com)