00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
#ifndef OPENCAL_RIGID_H
00012
#define OPENCAL_RIGID_H
00013
00014
00015
#include <OpenCAL/global.h>
00016
00017
#include <OpenCAL/Quaternion.h>
00018
using OpenCAL::Utils::Quaternion;
00019
00020
00021
namespace OpenCAL
00022 {
00023
00024
namespace Utils {
class Vector3; }
00025
using Utils::Vector3;
00026
00031 class OPENCAL_API Rigid
00032 {
00033
protected:
00034
00035 Quaternion m_rotation;
00036
00037
00038
00039
00040
00041
00042
public:
00043
00044
virtual ~Rigid();
00045
00046
00047
virtual const Quaternion &getRotation()
const {
return m_rotation; }
00048
virtual Quaternion *getRotationP() {
return &m_rotation; }
00049
00050
00051
virtual void setRotation(
const Quaternion &rotation) { m_rotation = rotation; }
00052
00053
00054
virtual void rotate(
const Vector3 &axis,
float degrees);
00055
virtual void rotateX(
float degrees);
00056
virtual void rotateY(
float degrees);
00057
virtual void rotateZ(
float degrees);
00058
00059
00060
00061
00062
00063
00064
00065
00066
00067
00068
protected:
00069
00070 Rigid();
00071 };
00072 }
00073
00074
#endif // OPENCAL_RIGID_H