00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011 #ifndef __QUATERNION_H__
00012 #define __QUATERNION_H__
00013
00014 #include "Common/CommonDll.h"
00015 #include "Common/Vector.h"
00016 #include "Common/Matrix.h"
00017
00018
00019 class COMMON_API KQuaternion
00020 {
00021 public:
00022 float m_W;
00023 float m_X;
00024 float m_Y;
00025 float m_Z;
00026
00027 KQuaternion();
00028 KQuaternion( float W, float X, float Y, float Z );
00029
00030 void SetAxis( float Angle, KVector& Axe );
00031 void SetEuler( float Angle, float Pitch, float Roll, float Yaw );
00032
00033 void GetEuler( float* pAngle, float* pPitch, float* pRoll, float* pYaw );
00034 void GetAxis( float* pAngle, KVector* pAxe );
00035 KMatrix GetMatrix();
00036
00037 KQuaternion operator *( KQuaternion& Q );
00038 };
00039
00040 #endif __QUATERNION_H__