diff --git a/qglview/gltypes.cpp b/qglview/gltypes.cpp index 1b393d5..d27782d 100644 --- a/qglview/gltypes.cpp +++ b/qglview/gltypes.cpp @@ -69,8 +69,8 @@ void glDrawQuad(QGLShaderProgram * prog, GLfloat x, GLfloat y, GLfloat w, GLfloa QMatrix4x4 getGLMatrix(GLenum matrix) { - GLfloat gm[16]; - glGetFloatv(matrix, gm); + GLdouble gm[16]; + glGetDoublev(matrix, gm); qreal qm[16]; for (int i = 0; i < 16; ++i) qm[i] = gm[i]; @@ -79,12 +79,12 @@ QMatrix4x4 getGLMatrix(GLenum matrix) { void setGLMatrix(QMatrix4x4 matrix) { - GLfloat gm[16]; + GLdouble gm[16]; qreal qm[16]; matrix.transposed().copyDataTo(qm); for (int i = 0; i < 16; ++i) gm[i] = qm[i]; - glLoadMatrixf(gm); + glLoadMatrixd(gm); }