Public Member Functions | Private Attributes | Static Private Attributes
vpQuaternionVector Class Reference

Defines a quaternion and its basic operations. More...

#include <vpQuaternionVector.h>

List of all members.

Public Member Functions

void buildFrom (const vpRotationMatrix &R)
vpQuaternionVector operator* (const double l)
 Multiplication by scalar. Returns a quaternion defined by (lx,ly,lz,lw).
vpQuaternionVector operator* (vpQuaternionVector &rq)
 Multiply two quaternions.
vpQuaternionVector operator+ (vpQuaternionVector &q)
vpQuaternionVector operator- (vpQuaternionVector &q)
vpQuaternionVector operator- ()
 Negate operator. Returns a quaternion defined by (-x,-y,-z-,-w).
vpQuaternionVectoroperator= (vpQuaternionVector &q)
 Copy operator. Allow operation such as Q = q.
void set (const double x, const double y, const double z, const double w)
unsigned int size ()
 vpQuaternionVector ()
 vpQuaternionVector (const double x, const double y, const double z, const double w)
 Constructor from doubles.
 vpQuaternionVector (const vpQuaternionVector &q)
 vpQuaternionVector (const vpRotationMatrix &R)
double w () const
 returns w-component of the quaternion
double x () const
 returns x-component of the quaternion
double y () const
 returns y-component of the quaternion
double z () const
 returns z-component of the quaternion

Private Attributes

double r [4]

Static Private Attributes

static const double minimum = 0.0001

Detailed Description

Defines a quaternion and its basic operations.

This class allows to compute a quaternion from a rotation matrix using either vpQuaternionVector(const vpRotationMatrix &) contructor or buildFrom() method.

It also defines common operations on a quaternion such as:

Definition at line 80 of file vpQuaternionVector.h.


Constructor & Destructor Documentation

Definition at line 61 of file vpQuaternionVector.cpp.

vpQuaternionVector::vpQuaternionVector ( const double  x,
const double  y,
const double  z,
const double  w 
)

Constructor from doubles.

Definition at line 64 of file vpQuaternionVector.cpp.

Copy constructor.

Parameters:
q,:quaternion to construct from.

Definition at line 85 of file vpQuaternionVector.cpp.

vpQuaternionVector::vpQuaternionVector ( const vpRotationMatrix &  R)

Constructs a quaternion from a rotation matrix.

Parameters:
R,:Matrix containing a rotation.

Definition at line 76 of file vpQuaternionVector.cpp.


Member Function Documentation

void vpQuaternionVector::buildFrom ( const vpRotationMatrix &  R)

Constructs a quaternion from a rotation matrix.

Parameters:
R,:Rotation matrix.

Definition at line 163 of file vpQuaternionVector.cpp.

vpQuaternionVector vpQuaternionVector::operator* ( const double  l)

Multiplication by scalar. Returns a quaternion defined by (lx,ly,lz,lw).

Definition at line 138 of file vpQuaternionVector.cpp.

vpQuaternionVector vpQuaternionVector::operator* ( vpQuaternionVector rq)

Multiply two quaternions.

Definition at line 144 of file vpQuaternionVector.cpp.

vpQuaternionVector vpQuaternionVector::operator+ ( vpQuaternionVector q)

Quaternion addition.

Adds two quaternions. Addition is component-wise.

Parameters:
q,:quaternion to add.

Definition at line 115 of file vpQuaternionVector.cpp.

vpQuaternionVector vpQuaternionVector::operator- ( vpQuaternionVector q)

Quaternion substraction.

Substracts a quaternion from another. Substraction is component-wise.

Parameters:
q,:quaternion to substract.

Definition at line 126 of file vpQuaternionVector.cpp.

vpQuaternionVector vpQuaternionVector::operator- ( )

Negate operator. Returns a quaternion defined by (-x,-y,-z-,-w).

Definition at line 132 of file vpQuaternionVector.cpp.

vpQuaternionVector & vpQuaternionVector::operator= ( vpQuaternionVector q)

Copy operator. Allow operation such as Q = q.

Definition at line 152 of file vpQuaternionVector.cpp.

void vpQuaternionVector::set ( const double  x,
const double  y,
const double  z,
const double  w 
)

Manually change values of a quaternion.

Parameters:
x,:x quaternion parameter.
y,:y quaternion parameter.
z,:z quaternion parameter.
w,:w quaternion parameter.

Definition at line 98 of file vpQuaternionVector.cpp.

unsigned int vpQuaternionVector::size ( ) [inline]

Definition at line 95 of file vpQuaternionVector.h.

double vpQuaternionVector::w ( ) const [inline]

returns w-component of the quaternion

Definition at line 103 of file vpQuaternionVector.h.

double vpQuaternionVector::x ( ) const [inline]

returns x-component of the quaternion

Definition at line 97 of file vpQuaternionVector.h.

double vpQuaternionVector::y ( ) const [inline]

returns y-component of the quaternion

Definition at line 99 of file vpQuaternionVector.h.

double vpQuaternionVector::z ( ) const [inline]

returns z-component of the quaternion

Definition at line 101 of file vpQuaternionVector.h.


Member Data Documentation

const double vpQuaternionVector::minimum = 0.0001 [static, private]

Definition at line 83 of file vpQuaternionVector.h.

double vpQuaternionVector::r[4] [private]

Definition at line 84 of file vpQuaternionVector.h.


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


visp_bridge
Author(s): Filip Novotny
autogenerated on Fri Aug 28 2015 13:36:28