Rev | Line | |
---|

[2] | 1 | // %flair:license{ |
---|

[13] | 2 | // This file is part of the Flair framework distributed under the |
---|

| 3 | // CECILL-C License, Version 1.0. |
---|

[2] | 4 | // %flair:license} |
---|

| 5 | /*! |
---|

| 6 | * \file RotationMatrix.h |
---|

| 7 | * \brief Class defining a rotation matrix |
---|

| 8 | * \author Guillaume Sanahuja, Copyright Heudiasyc UMR UTC/CNRS 7253 |
---|

| 9 | * \date 2016/02/09 |
---|

| 10 | * \version 4.0 |
---|

| 11 | */ |
---|

| 12 | #ifndef ROTATIONMATRIX_H |
---|

| 13 | #define ROTATIONMATRIX_H |
---|

| 14 | |
---|

| 15 | #include <stddef.h> |
---|

| 16 | |
---|

| 17 | namespace flair { |
---|

| 18 | namespace core { |
---|

[13] | 19 | class Euler; |
---|

[36] | 20 | class Quaternion; |
---|

[2] | 21 | |
---|

[13] | 22 | /*! \class RotationMatrix |
---|

| 23 | * |
---|

| 24 | * \brief Class defining a rotation matrix |
---|

| 25 | */ |
---|

| 26 | class RotationMatrix { |
---|

| 27 | public: |
---|

| 28 | /*! |
---|

| 29 | * \brief Constructor |
---|

| 30 | * |
---|

| 31 | * Construct an identity rotation matrix |
---|

| 32 | * |
---|

| 33 | */ |
---|

| 34 | RotationMatrix(); |
---|

[2] | 35 | |
---|

[13] | 36 | /*! |
---|

| 37 | * \brief Destructor |
---|

| 38 | * |
---|

| 39 | */ |
---|

| 40 | ~RotationMatrix(); |
---|

[2] | 41 | |
---|

[13] | 42 | /*! |
---|

| 43 | * \brief Convert to euler angles |
---|

| 44 | * |
---|

| 45 | * \param euler output euler angles |
---|

| 46 | */ |
---|

| 47 | void ToEuler(Euler &euler) const; |
---|

[2] | 48 | |
---|

[13] | 49 | /*! |
---|

| 50 | * \brief Convert to euler angles |
---|

| 51 | * |
---|

| 52 | * \return euler angles |
---|

| 53 | */ |
---|

| 54 | Euler ToEuler(void) const; |
---|

[36] | 55 | |
---|

[13] | 56 | /*! |
---|

[36] | 57 | * \brief Convert to quaternion |
---|

| 58 | * |
---|

| 59 | * \param quaternion output quaternion |
---|

| 60 | */ |
---|

| 61 | void ToQuaternion(Quaternion &quaternion) const; |
---|

| 62 | |
---|

| 63 | /*! |
---|

| 64 | * \brief Convert to quaternion |
---|

| 65 | * |
---|

| 66 | * \return quaternion |
---|

| 67 | */ |
---|

| 68 | Quaternion ToQuaternion(void) const; |
---|

| 69 | |
---|

| 70 | /*! |
---|

[13] | 71 | * \brief matrix |
---|

| 72 | * |
---|

| 73 | */ |
---|

| 74 | float m[3][3]; |
---|

[2] | 75 | |
---|

[13] | 76 | float &operator()(size_t row, size_t col); |
---|

| 77 | const float &operator()(size_t row, size_t col) const; |
---|

| 78 | }; |
---|

[2] | 79 | |
---|

| 80 | } // end namespace core |
---|

| 81 | } // end namespace flair |
---|

| 82 | |
---|

| 83 | #endif // ROTATIONMATRIX_H |
---|

**Note:** See

TracBrowser
for help on using the repository browser.