Public Member Functions | Public Attributes | List of all members
AISNavigation::Quaternion< T > Struct Template Reference

#include <transformation3.h>

Public Member Functions

T angle () const
 
Vector3< Taxis () const
 
Quaternion< Tconjugated () const
 
Vector3< Tim () const
 
Quaternion< Tinverse () const
 
T norm () const
 
Quaternion< Tnormalized () const
 
 Quaternion ()
 
 Quaternion (const T _roll_x_phi, const T _pitch_y_theta, const T _yaw_z_psi)
 
 Quaternion (const T _w, const T _x, const T _y, const T _z)
 
 Quaternion (const Vector3< T > &axis, const T &angle)
 
 Quaternion (const Vector3< T > &pose)
 
T re () const
 
Quaternion< TrotatePoint (const Quaternion &p) const
 
Vector3< TrotatePoint (const Vector3< T > &p) const
 
Quaternion< TrotateThisAlong (const Vector3< T > &axis, const T alpha) const
 
Vector3< TtoAngles () const
 
Quaternion withRotation (const T alpha) const
 

Public Attributes

T w
 
T x
 
T y
 
T z
 

Detailed Description

template<class T>
struct AISNavigation::Quaternion< T >

A Quaternion can be used to either represent a rotational axis and a Rotation, or, the point which will be rotated

Definition at line 140 of file transformation3.h.

Constructor & Destructor Documentation

◆ Quaternion() [1/5]

template<class T >
AISNavigation::Quaternion< T >::Quaternion ( )

Default Constructor: w=x=y=z=0;

◆ Quaternion() [2/5]

template<class T >
AISNavigation::Quaternion< T >::Quaternion ( const Vector3< T > &  pose)

The Quaternion representation of the point "pose"

◆ Quaternion() [3/5]

template<class T >
AISNavigation::Quaternion< T >::Quaternion ( const T  _w,
const T  _x,
const T  _y,
const T  _z 
)

create a Quaternion by scalar w and the imaginery parts x,y, and z.

◆ Quaternion() [4/5]

template<class T >
AISNavigation::Quaternion< T >::Quaternion ( const T  _roll_x_phi,
const T  _pitch_y_theta,
const T  _yaw_z_psi 
)

create a rotational Quaternion, roll along x-axis, pitch along y-axis and yaw along z-axis

◆ Quaternion() [5/5]

template<class T >
AISNavigation::Quaternion< T >::Quaternion ( const Vector3< T > &  axis,
const T angle 
)
inline

Member Function Documentation

◆ angle()

template<class T >
T AISNavigation::Quaternion< T >::angle ( ) const
inline

◆ axis()

template<class T >
Vector3<T> AISNavigation::Quaternion< T >::axis ( ) const
inline

◆ conjugated()

template<class T >
Quaternion<T> AISNavigation::Quaternion< T >::conjugated ( ) const
inline
Returns
the conjugated version of this quaternion

◆ im()

template<class T >
Vector3<T> AISNavigation::Quaternion< T >::im ( ) const
inline
Returns
the imaginery part (== (x,y,z)) of this Quaternion

◆ inverse()

template<class T >
Quaternion<T> AISNavigation::Quaternion< T >::inverse ( ) const
inline
Returns
the inverse of this Quaternion

◆ norm()

template<class T >
T AISNavigation::Quaternion< T >::norm ( ) const
inline
Returns
the norm of this Quaternion

◆ normalized()

template<class T >
Quaternion<T> AISNavigation::Quaternion< T >::normalized ( ) const
inline
Returns
this quaternion, but normalized

◆ re()

template<class T >
T AISNavigation::Quaternion< T >::re ( ) const
inline
Returns
the real part (==w) of this Quaternion

◆ rotatePoint() [1/2]

template<class T >
Quaternion<T> AISNavigation::Quaternion< T >::rotatePoint ( const Quaternion< T > &  p) const
inline

if this Quaternion represents a rotational axis + rotation, use this function to rotate another point represented as a Quaternion p

Parameters
pthe point to be rotated by <this>. Point is represented as a Quaternion
Returns
rotated Point (represented as a Quaternion)

◆ rotatePoint() [2/2]

template<class T >
Vector3<T> AISNavigation::Quaternion< T >::rotatePoint ( const Vector3< T > &  p) const
inline

if this Quaternion represents a rotational axis + rotation, use this function to rotate another point

Parameters
pthe point to be rotated by <this>.
Returns
rotated Point

◆ rotateThisAlong()

template<class T >
Quaternion<T> AISNavigation::Quaternion< T >::rotateThisAlong ( const Vector3< T > &  axis,
const T  alpha 
) const
inline

if this Quaternion represents a point, use this function to rotate the point along <axis> with angle <alpha>

Parameters
axisthe rotational axis
alpharotational angle

◆ toAngles()

template<class T >
Vector3<T> AISNavigation::Quaternion< T >::toAngles ( ) const
inline

Given rotational axis x,y,z, get the rotation along these axis encoded in this Quaternion

Returns
rotation along x,y,z axis encoded in <this> Quaternion

◆ withRotation()

template<class T >
Quaternion AISNavigation::Quaternion< T >::withRotation ( const T  alpha) const
inline

if this Quaternion represents a rotational axis, add a rotation of angle <alpha> along <this> axis to the Quaternion

Parameters
alpharotational value
Returns
this Quaternion with included information about the rotation along <this> axis

Member Data Documentation

◆ w

template<class T >
T AISNavigation::Quaternion< T >::w

Definition at line 238 of file transformation3.h.

◆ x

template<class T >
T AISNavigation::Quaternion< T >::x

Definition at line 238 of file transformation3.h.

◆ y

template<class T >
T AISNavigation::Quaternion< T >::y

Definition at line 238 of file transformation3.h.

◆ z

template<class T >
T AISNavigation::Quaternion< T >::z

Definition at line 238 of file transformation3.h.


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


rtabmap
Author(s): Mathieu Labbe
autogenerated on Thu Jul 25 2024 02:50:26