00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020 #ifndef GLUONGRAPHICS_MATH_H
00021 #define GLUONGRAPHICS_MATH_H
00022
00023 #include "gluon_graphics_export.h"
00024
00025 #include <QtGui/QMatrix4x4>
00026 #include <QtGui/QVector3D>
00027 #include <QtGui/QQuaternion>
00028
00029 namespace GluonGraphics
00030 {
00034 class GLUON_GRAPHICS_EXPORT Math
00035 {
00036 public:
00051 static void qmatrixToGLMatrix( const QMatrix4x4& matrix, float* out );
00052
00063 static QMatrix4x4 calculateModelViewProj( const QMatrix4x4& model, const QMatrix4x4& view, const QMatrix4x4& projection );
00064
00078 static void qImageToGL( const QImage& image, uchar* out );
00079
00083 static const QVector3D VECTOR_UNIT_X;
00087 static const QVector3D VECTOR_UNIT_Y;
00091 static const QVector3D VECTOR_UNIT_Z;
00095 static const QVector3D VECTOR_UNIT_SCALE;
00096 };
00097
00098 }
00099
00100 #endif // GLUONGRAPHICS_MATH_H