In file include/csgeom/transfrm.h:

class csTransform

A class which defines a transformation from one coordinate system to another

Inheritance:


Public Methods

csTransform (const csMatrix3& other2this, const csVector3& origin_pos)
Initialize with the given transformation
csTransform ()
Initialize with the identity transformation
inline const csMatrix3& GetO2T ()
Get 'other' to 'this' transformation matrix
inline const csVector3& GetO2TTranslation ()
Get 'world' to 'this' translation
inline const csVector3& GetOrigin ()
Get origin of transformed coordinate system
static csTransform GetReflect (const csPlane& pl)
Return a transform that represents a mirroring across a plane
friend csTransform operator* (const csTransform& t1, const csReversibleTransform& t2)
Combine two transforms, rightmost first.
friend csPlane operator* (const csPlane& p, const csTransform& t)
Apply a transformation to a Plane.
friend csMatrix3 operator* (const csTransform& t, const csMatrix3& m)
Multiply a matrix with the transformation matrix.
friend csMatrix3 operator* (const csMatrix3& m, const csTransform& t)
Multiply a matrix with the transformation matrix.
friend csVector3 operator* (const csTransform& t, const csVector3& v)
Apply a transformation to a 3D vector.
friend csPlane operator* (const csTransform& t, const csPlane& p)
Apply a transformation to a Plane.
friend csVector3 operator* (const csVector3& v, const csTransform& t)
Apply a transformation to a 3D vector
friend csPlane& operator*= (csPlane& p, const csTransform& t)
Apply a transformation to a Plane.
friend csMatrix3& operator*= (csMatrix3& m, const csTransform& t)
Multiply a matrix with the transformation matrix.
friend csVector3& operator*= (csVector3& v, const csTransform& t)
Apply a transformation to a 3D vector.
inline csVector3 Other2This (const csVector3& v)
Transform vector in 'other' space v to a vector in 'this' space
void Other2This (const csPlane& p, const csVector3& point, csPlane& result)
Convert a plane in 'other' space to 'this' space
csPlane Other2This (const csPlane& p)
Convert a plane in 'other' space to 'this' space
csVector3 Other2ThisRelative (const csVector3& v)
Convert vector v in 'other' space to a vector in 'this' space
virtual void SetO2T (const csMatrix3& m)
Set 'other' to 'this' transformation matrix
inline void SetO2TTranslation (const csVector3& v)
Set 'world' to 'this' translation
inline void SetOrigin (const csVector3& v)
Set origin of transformed coordinate system
inline void Translate (const csVector3& v)
Move the 'other' to 'this' translation by a specified amount

Protected Fields

csMatrix3 m_o2t
Transformation matrix from 'other' space to 'this' space.
csVector3 v_o2t
Location of the origin for 'this' space.

Documentation

A class which defines a transformation from one coordinate system to another. The two coordinate systems are refered to as 'other' and 'this'. The transform defines a transformation from 'other' to 'this'.
csMatrix3 m_o2t
Transformation matrix from 'other' space to 'this' space.

csVector3 v_o2t
Location of the origin for 'this' space.

csTransform()
Initialize with the identity transformation

csTransform(const csMatrix3& other2this, const csVector3& origin_pos)
Initialize with the given transformation. The transformation is given as a 3x3 matrix and a vector. The transformation is defined to mean T=M*(O-V) with T the vector in 'this' space, O the vector in 'other' space, M the transformation matrix and V the transformation vector.

inline const csMatrix3& GetO2T()
Get 'other' to 'this' transformation matrix. This is the 3x3 matrix M from the transform equation T=M*(O-V).

inline const csVector3& GetO2TTranslation()
Get 'world' to 'this' translation. This is the vector V from the transform equation T=M*(O-V).

inline const csVector3& GetOrigin()
Get origin of transformed coordinate system

virtual void SetO2T(const csMatrix3& m)
Set 'other' to 'this' transformation matrix. this is the 3x3 matrix M from the transform equation T=M*(O-V).

inline void SetO2TTranslation(const csVector3& v)
Set 'world' to 'this' translation. This is the vector V from the transform equation T=M*(O-V).

inline void SetOrigin(const csVector3& v)
Set origin of transformed coordinate system

inline void Translate(const csVector3& v)
Move the 'other' to 'this' translation by a specified amount

inline csVector3 Other2This(const csVector3& v)
Transform vector in 'other' space v to a vector in 'this' space. This is the basic transform function.

csVector3 Other2ThisRelative(const csVector3& v)
Convert vector v in 'other' space to a vector in 'this' space. Use the origin of 'other' space.

csPlane Other2This(const csPlane& p)
Convert a plane in 'other' space to 'this' space

void Other2This(const csPlane& p, const csVector3& point, csPlane& result)
Convert a plane in 'other' space to 'this' space. This is an optimized version for which a point on the new plane is known (point). The result is stored in 'result'.

friend csVector3 operator* (const csVector3& v, const csTransform& t)
Apply a transformation to a 3D vector

friend csVector3 operator* (const csTransform& t, const csVector3& v)
Apply a transformation to a 3D vector.

friend csVector3& operator*= (csVector3& v, const csTransform& t)
Apply a transformation to a 3D vector.

friend csPlane operator* (const csPlane& p, const csTransform& t)
Apply a transformation to a Plane.

friend csPlane operator* (const csTransform& t, const csPlane& p)
Apply a transformation to a Plane.

friend csPlane& operator*= (csPlane& p, const csTransform& t)
Apply a transformation to a Plane.

friend csMatrix3 operator* (const csMatrix3& m, const csTransform& t)
Multiply a matrix with the transformation matrix.

friend csMatrix3 operator* (const csTransform& t, const csMatrix3& m)
Multiply a matrix with the transformation matrix.

friend csMatrix3& operator*= (csMatrix3& m, const csTransform& t)
Multiply a matrix with the transformation matrix.

friend csTransform operator* (const csTransform& t1, const csReversibleTransform& t2)
Combine two transforms, rightmost first.

static csTransform GetReflect(const csPlane& pl)
Return a transform that represents a mirroring across a plane. This function will return a csTransform which represents a reflection across the plane pl.


Direct child classes:
csReversibleTransform

alphabetic index hierarchy of classes


this page has been generated automatically by doc++

(c)opyright by Malte Zöckler, Roland Wunderling
contact: doc++@zib.de