OSVR-Core
Public Types | Public Member Functions | Static Public Member Functions | Protected Attributes | Friends | List of all members
Eigen::Translation< _Scalar, _Dim > Class Template Reference

More...

#include <Translation.h>

Public Types

enum  { Dim = _Dim }
 dimension of the space
 
enum  { Dim = _Dim }
 dimension of the space
 
typedef _Scalar Scalar
 the scalar type of the coefficients
 
typedef Matrix< Scalar, Dim, 1 > VectorType
 corresponding vector type
 
typedef Matrix< Scalar, Dim, Dim > LinearMatrixType
 corresponding linear transformation matrix type
 
typedef Scaling< Scalar, Dim > ScalingType
 corresponding scaling transformation type
 
typedef Transform< Scalar, Dim > TransformType
 corresponding affine transformation type
 
typedef _Scalar Scalar
 the scalar type of the coefficients
 
typedef Matrix< Scalar, Dim, 1 > VectorType
 corresponding vector type
 
typedef Matrix< Scalar, Dim, Dim > LinearMatrixType
 corresponding linear transformation matrix type
 
typedef Transform< Scalar, Dim, AffineAffineTransformType
 corresponding affine transformation type
 
typedef Transform< Scalar, Dim, IsometryIsometryTransformType
 corresponding isometric transformation type
 

Public Member Functions

 Translation ()
 Default constructor without initialization. More...
 
 Translation (const Scalar &sx, const Scalar &sy)
 
 Translation (const Scalar &sx, const Scalar &sy, const Scalar &sz)
 
 Translation (const VectorType &vector)
 Constructs and initialize the scaling transformation from a vector of scaling coefficients.
 
const VectorTypevector () const
 
VectorTypevector ()
 
Translation operator* (const Translation &other) const
 Concatenates two translation.
 
TransformType operator* (const ScalingType &other) const
 Concatenates a translation and a scaling.
 
TransformType operator* (const LinearMatrixType &linear) const
 Concatenates a translation and a linear transformation.
 
template<typename Derived >
TransformType operator* (const RotationBase< Derived, Dim > &r) const
 
TransformType operator* (const TransformType &t) const
 Concatenates a translation and an affine transformation.
 
VectorType operator* (const VectorType &other) const
 Applies translation to vector.
 
Translation inverse () const
 
Translationoperator= (const Translation &other)
 
template<typename NewScalarType >
internal::cast_return_type< Translation, Translation< NewScalarType, Dim > >::type cast () const
 
template<typename OtherScalarType >
 Translation (const Translation< OtherScalarType, Dim > &other)
 Copy constructor with scalar type conversion.
 
bool isApprox (const Translation &other, typename NumTraits< Scalar >::Real prec=precision< Scalar >()) const
 
 Translation ()
 Default constructor without initialization. More...
 
 Translation (const Scalar &sx, const Scalar &sy)
 
 Translation (const Scalar &sx, const Scalar &sy, const Scalar &sz)
 
 Translation (const VectorType &vector)
 Constructs and initialize the translation transformation from a vector of translation coefficients.
 
Scalar x () const
 Retruns the x-translation by value. More...
 
Scalar y () const
 Retruns the y-translation by value. More...
 
Scalar z () const
 Retruns the z-translation by value. More...
 
Scalarx ()
 Retruns the x-translation as a reference. More...
 
Scalary ()
 Retruns the y-translation as a reference. More...
 
Scalarz ()
 Retruns the z-translation as a reference. More...
 
const VectorTypevector () const
 
VectorTypevector ()
 
const VectorTypetranslation () const
 
VectorTypetranslation ()
 
Translation operator* (const Translation &other) const
 Concatenates two translation.
 
AffineTransformType operator* (const UniformScaling< Scalar > &other) const
 Concatenates a translation and a uniform scaling.
 
template<typename OtherDerived >
AffineTransformType operator* (const EigenBase< OtherDerived > &linear) const
 Concatenates a translation and a linear transformation.
 
template<typename Derived >
IsometryTransformType operator* (const RotationBase< Derived, Dim > &r) const
 Concatenates a translation and a rotation.
 
template<int Mode, int Options>
Transform< Scalar, Dim, Mode > operator* (const Transform< Scalar, Dim, Mode, Options > &t) const
 Concatenates a translation and a transformation.
 
VectorType operator* (const VectorType &other) const
 Applies translation to vector.
 
Translation inverse () const
 
Translationoperator= (const Translation &other)
 
template<typename NewScalarType >
internal::cast_return_type< Translation, Translation< NewScalarType, Dim > >::type cast () const
 
template<typename OtherScalarType >
 Translation (const Translation< OtherScalarType, Dim > &other)
 Copy constructor with scalar type conversion.
 
bool isApprox (const Translation &other, const typename NumTraits< Scalar >::Real &prec=NumTraits< Scalar >::dummy_precision()) const
 

Static Public Member Functions

static const Translation Identity ()
 

Protected Attributes

VectorType m_coeffs
 

Friends

TransformType operator* (const LinearMatrixType &linear, const Translation &t)
 Concatenates a linear transformation and a translation.
 
template<typename OtherDerived >
AffineTransformType operator* (const EigenBase< OtherDerived > &linear, const Translation &t)
 

Detailed Description

template<typename _Scalar, int _Dim>
class Eigen::Translation< _Scalar, _Dim >

Represents a translation transformation

Parameters
_Scalarthe scalar type, i.e., the type of the coefficients.
_Dimthe dimension of the space, can be a compile time value or Dynamic
Note
This class is not aimed to be used to store a translation transformation, but rather to make easier the constructions and updates of Transform objects.
See also
class Scaling, class Transform

Constructor & Destructor Documentation

§ Translation() [1/2]

template<typename _Scalar, int _Dim>
Eigen::Translation< _Scalar, _Dim >::Translation ( )
inline

Default constructor without initialization.

§ Translation() [2/2]

template<typename _Scalar, int _Dim>
Eigen::Translation< _Scalar, _Dim >::Translation ( )
inline

Default constructor without initialization.

Member Function Documentation

§ cast() [1/2]

template<typename _Scalar, int _Dim>
template<typename NewScalarType >
internal::cast_return_type<Translation,Translation<NewScalarType,Dim> >::type Eigen::Translation< _Scalar, _Dim >::cast ( ) const
inline
Returns
*this with scalar type casted to NewScalarType

Note that if NewScalarType is equal to the current scalar type of *this then this function smartly returns a const reference to *this.

§ cast() [2/2]

template<typename _Scalar, int _Dim>
template<typename NewScalarType >
internal::cast_return_type<Translation,Translation<NewScalarType,Dim> >::type Eigen::Translation< _Scalar, _Dim >::cast ( ) const
inline
Returns
*this with scalar type casted to NewScalarType

Note that if NewScalarType is equal to the current scalar type of *this then this function smartly returns a const reference to *this.

§ inverse() [1/2]

template<typename _Scalar, int _Dim>
Translation Eigen::Translation< _Scalar, _Dim >::inverse ( void  ) const
inline
Returns
the inverse translation (opposite)

§ inverse() [2/2]

template<typename _Scalar, int _Dim>
Translation Eigen::Translation< _Scalar, _Dim >::inverse ( void  ) const
inline
Returns
the inverse translation (opposite)

§ isApprox() [1/2]

template<typename _Scalar, int _Dim>
bool Eigen::Translation< _Scalar, _Dim >::isApprox ( const Translation< _Scalar, _Dim > &  other,
typename NumTraits< Scalar >::Real  prec = precision<Scalar>() 
) const
inline
Returns
true if *this is approximately equal to other, within the precision determined by prec.
See also
MatrixBase::isApprox()

§ isApprox() [2/2]

template<typename _Scalar, int _Dim>
bool Eigen::Translation< _Scalar, _Dim >::isApprox ( const Translation< _Scalar, _Dim > &  other,
const typename NumTraits< Scalar >::Real &  prec = NumTraits<Scalar>::dummy_precision() 
) const
inline
Returns
true if *this is approximately equal to other, within the precision determined by prec.
See also
MatrixBase::isApprox()

§ x() [1/2]

template<typename _Scalar, int _Dim>
Scalar Eigen::Translation< _Scalar, _Dim >::x ( ) const
inline

Retruns the x-translation by value.

§ x() [2/2]

template<typename _Scalar, int _Dim>
Scalar& Eigen::Translation< _Scalar, _Dim >::x ( )
inline

Retruns the x-translation as a reference.

§ y() [1/2]

template<typename _Scalar, int _Dim>
Scalar Eigen::Translation< _Scalar, _Dim >::y ( ) const
inline

Retruns the y-translation by value.

§ y() [2/2]

template<typename _Scalar, int _Dim>
Scalar& Eigen::Translation< _Scalar, _Dim >::y ( )
inline

Retruns the y-translation as a reference.

§ z() [1/2]

template<typename _Scalar, int _Dim>
Scalar Eigen::Translation< _Scalar, _Dim >::z ( ) const
inline

Retruns the z-translation by value.

§ z() [2/2]

template<typename _Scalar, int _Dim>
Scalar& Eigen::Translation< _Scalar, _Dim >::z ( )
inline

Retruns the z-translation as a reference.

Friends And Related Function Documentation

§ operator*

template<typename _Scalar, int _Dim>
template<typename OtherDerived >
AffineTransformType operator* ( const EigenBase< OtherDerived > &  linear,
const Translation< _Scalar, _Dim > &  t 
)
friend
Returns
the concatenation of a linear transformation l with the translation t

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