core/vnl/vnl_rotation_matrix.h
Go to the documentation of this file.
00001 // This is core/vnl/vnl_rotation_matrix.h
00002 #ifndef vnl_rotation_matrix_h_
00003 #define vnl_rotation_matrix_h_
00004 //:
00005 //  \file
00006 //  \brief Functions to create a 3x3 rotation matrix
00007 //
00008 // The result is a (special) orthogonal 3x3 matrix which is a
00009 // rotation about the axis, by an angle equal to ||axis||.
00010 //
00011 // \verbatim
00012 //  Modifications:
00013 //   12-Jan-2007 Peter Vanroose - Added vnl_matrix_fixed interface
00014 // \endverbatim
00015 
00016 template <class T> class vnl_vector;
00017 template <class T> class vnl_matrix;
00018 template <class T, unsigned int n> class vnl_vector_fixed;
00019 template <class T, unsigned int num_rows, unsigned int num_cols> class vnl_matrix_fixed;
00020 
00021 bool vnl_rotation_matrix(double const axis[3], double** R);
00022 bool vnl_rotation_matrix(double const axis[3], double* R0, double* R1, double* R2);
00023 bool vnl_rotation_matrix(double const axis[3], double R[3][3]);
00024 bool vnl_rotation_matrix(vnl_vector<double> const &axis, vnl_matrix<double>& R);
00025 bool vnl_rotation_matrix(vnl_vector_fixed<double,3> const& axis, vnl_matrix_fixed<double,3,3>& R);
00026 
00027 //: Returns an orthogonal 3x3 matrix which is a rotation about the axis, by an angle equal to ||axis||.
00028 // \relatesalso vnl_matrix_fixed
00029 vnl_matrix_fixed<double,3,3> vnl_rotation_matrix(vnl_vector_fixed<double,3> const& axis);
00030 
00031 //: Returns an orthogonal 3x3 matrix which is a rotation about the axis, by an angle equal to ||axis||.
00032 // \relatesalso vnl_matrix
00033 vnl_matrix<double> vnl_rotation_matrix(vnl_vector<double> const& axis);
00034 
00035 #endif // vnl_rotation_matrix_h_