Public Types | Public Member Functions | Public Attributes | Protected Attributes

TRTK::Fit3D< T > Class Template Reference

Base class for 3D fitting algorithms where fitting is done to a 3D point set. More...

#include <Fit3D.hpp>

Inheritance diagram for TRTK::Fit3D< T >:
Collaboration diagram for TRTK::Fit3D< T >:

List of all members.

Public Types

typedef super::ArrayXT ArrayXT
 General-purpose array of arbitrary size with value type T.
typedef super::MatrixXT MatrixXT
 Matrix of arbitrary size with value type T.
typedef super::VectorXT VectorXT
 Column vector of arbitrary size with value type T.
typedef super::Vector2T Vector2T
 2D column vector with value type T.
typedef super::Vector3T Vector3T
 3D column vector with value type T.
typedef super::Vector4T Vector4T
 4D column vector with value type T.
typedef super::Matrix2T Matrix2T
 2 x 2 matrix with value type T.
typedef super::Matrix3T Matrix3T
 3 x 3 matrix with value type T.
enum  Error {
  DATA_POINTS_TOO_SIMILAR, INFINITY_NOT_AVAILABLE, NAN_NOT_AVAILABLE, NOT_ENOUGH_POINTS,
  UNKNOWN_ERROR, WRONG_POINT_SIZE
}

Public Member Functions

 Fit3D ()
 Constructs a new initialized instance of this class.
virtual ~Fit3D ()
 Deletes the instance.
void compute ()=0
 Performs the regression analysis.
getDistanceTo (const Coordinate< T > &point) const =0
 Returns the distance/deviation of the given data point to the estimated model.
getRMS () const =0
 Returns the root mean square error of the model fitting.
unsigned getNumberPointsRequired () const =0
 Returns the minimum number of data points required to compute a model.
void setPoints (const std::vector< Coordinate< T > > &)
 Sets the point set.
void setPoints (const std::vector< Vector3T > &)
 Sets the point set.
void setPoints (const std::vector< Vector4T, Eigen::aligned_allocator< Vector4T > > &)
 Sets the point set.

Public Attributes

EIGEN_MAKE_ALIGNED_OPERATOR_NEW
typedef T 
value_type
 Internally used value type (should be a floating point type).

Protected Attributes

MatrixXT m_points

Detailed Description

template<class T>
class TRTK::Fit3D< T >

Base class for 3D fitting algorithms where fitting is done to a 3D point set.

Note:
Some functions might throw an error object. See the appropriate function for more details.
See also:
Fit
Author:
Fabian Killus, Christoph Haenisch
Version:
0.3.0
Date:
2012-03-29

Definition at line 53 of file Fit3D.hpp.


Member Enumeration Documentation

template<class T>
enum TRTK::Fit::Error [inherited]
Enumerator:
DATA_POINTS_TOO_SIMILAR 

The data points are to similar.

INFINITY_NOT_AVAILABLE 

The type T cannot represent infinity (see std::numeric_limits<T>).

NAN_NOT_AVAILABLE 

The type T cannot represent NaN (see std::numeric_limits<T>).

NOT_ENOUGH_POINTS 

More points are required to estimate the transformation.

UNKNOWN_ERROR 

An unknown error occured.

WRONG_POINT_SIZE 

One or more points have a wrong size.

Definition at line 69 of file Fit.hpp.


Constructor & Destructor Documentation

template<class T >
TRTK::Fit3D< T >::Fit3D (  )

Constructs a new initialized instance of this class.

Template Parameters:
Tscalar type of the coordinates

Definition at line 105 of file Fit3D.hpp.

template<class T >
TRTK::Fit3D< T >::~Fit3D (  ) [virtual]

Deletes the instance.

Template Parameters:
Tscalar type of the coordinates

Definition at line 116 of file Fit3D.hpp.


Member Function Documentation

template<class T >
void TRTK::Fit3D< T >::setPoints ( const std::vector< Vector4T, Eigen::aligned_allocator< Vector4T > > &  points )

Sets the point set.

Template Parameters:
Tscalar type of the coordinates
Parameters:
[in]points4D homogeneous coordinates.

Definition at line 187 of file Fit3D.hpp.

template<class T >
void TRTK::Fit3D< T >::setPoints ( const std::vector< Coordinate< T > > &  points ) [virtual]

Sets the point set.

Template Parameters:
Tscalar type of the coordinates
Parameters:
[in]pointsThe points can either be plain 3D or 4D homogeneous coordinates.
Exceptions:
ErrorObjIf there are any coordinates other than 3D or 4D coordinates, an error object is thrown and its error code is set to WRONG_POINT_SIZE.

Implements TRTK::Fit< T >.

Definition at line 135 of file Fit3D.hpp.

template<class T >
void TRTK::Fit3D< T >::setPoints ( const std::vector< Vector3T > &  points )

Sets the point set.

Template Parameters:
Tscalar type of the coordinates
Parameters:
[in]points3D coordinates.

Definition at line 168 of file Fit3D.hpp.


The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines