Basic Image AlgorithmS Library  2.8.0
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
PoseParametrizationCovariance.hh
1 /*
2 This file is part of the BIAS library (Basic ImageAlgorithmS).
3 
4 Copyright (C) 2003-2009 (see file CONTACT for details)
5  Multimediale Systeme der Informationsverarbeitung
6  Institut fuer Informatik
7  Christian-Albrechts-Universitaet Kiel
8 
9 
10 BIAS is free software; you can redistribute it and/or modify
11 it under the terms of the GNU Lesser General Public License as published by
12 the Free Software Foundation; either version 2.1 of the License, or
13 (at your option) any later version.
14 
15 BIAS is distributed in the hope that it will be useful,
16 but WITHOUT ANY WARRANTY; without even the implied warranty of
17 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 GNU Lesser General Public License for more details.
19 
20 You should have received a copy of the GNU Lesser General Public License
21 along with BIAS; if not, write to the Free Software
22 Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
23 */
24 #ifndef __PoseParametrizationCovariance_hh__
25 #define __PoseParametrizationCovariance_hh__
26 
27 #include <Base/Math/Matrix.hh>
28 #include <Base/Math/Matrix3x3.hh>
29 #include <Base/Math/Matrix4x4.hh>
30 
31 #define POSECOVARIANCE_TYPE double
32 
33 namespace BIAS {
34  // forward declarations
35  template <class T> class BIASMathBase_EXPORT Vector;
36  class PoseParametrization;
37 
38  /** @class PoseParametrizationCovariance
39  @ingroup g_math
40  @ingroup g_geometry
41  @brief class encapsulating the transfromations between different pose
42  parametrizations
43 
44  This class represents the covariance of a camerpose with
45  translation and rotation. The pose is assumed to be
46  tx,ty,tz,q1,q2,q3,q4 with translation t and rotation q as
47  quaternion. The covariance therefore must be 7x7.
48  @author woelk 03/2006 */
49  class BIASGeometryBase_EXPORT PoseParametrizationCovariance
50  : public Matrix<POSECOVARIANCE_TYPE>
51  {
52  public:
54  : Matrix<POSECOVARIANCE_TYPE>(7,7,T){};
55 
57 
59  : Matrix<POSECOVARIANCE_TYPE>(T){};
60 
62  : Matrix<POSECOVARIANCE_TYPE>(T){};
63 
65 
66  Matrix3x3<POSECOVARIANCE_TYPE> GetCovC() const;
67 
68  Matrix4x4<POSECOVARIANCE_TYPE> GetCovQ() const;
69 
70  inline void Clear() {}
71 
72  /** Given a 6D pose (position and euler angles) and its
73  associated covariance, the function transforms the covaruiance into
74  pose and quaternion parametrization. The 1st 3 entries of the 6D pose
75  must be the euclidean position coordinates and the last 3 entries
76  must be the Euler angles [Ax, Ay, Az] such that the final rotation
77  matrix is composed from Rz * Ry * Rx. Where Rx denotes the rotation
78  matrix describing the rotation around the x axis, ....
79  @author woelk 03/2006 */
80  //void SetFromEulerAngles(const Matrix<double>& cov_pose,
81  // const Vector<double>& pose);
82 
83  /** Transfroms the covariance associated with pose according to
84  the point transformation transf. Only affine transformations are
85  supported. result is "covRes = transf*this"
86  */
87  void Transform(const Matrix4x4<double>& transf);
88 
89 
90 
91  protected:
92  }; // class
93 
94 
95 
96 } // namespace
97 
98 
99 #endif // __PoseParametrizationCovariance_hh__
MatrixInitType
can be passed to matrix constructors to init the matrix with the most often used values ...
Definition: Matrix.hh:59
PoseParametrizationCovariance(const Matrix< POSECOVARIANCE_TYPE > &T)
class for column vectors with arbitrary size
Slim class bundeling pose parametrization and associated covariance matrix.
PoseParametrizationCovariance(const TNT::Matrix< POSECOVARIANCE_TYPE > &T)
is a &#39;fixed size&#39; quadratic matrix of dim.
Definition: Matrix.hh:54
matrix class with arbitrary size, indexing is row major.
class encapsulating the transfromations between different pose parametrizations
is a &#39;fixed size&#39; quadratic matrix of dim.
Definition: Matrix4x4.hh:54