diff --git a/glslUtil/glslUtil.c b/glslUtil/glslUtil.c index d36f07e..f7b716d 100644 --- a/glslUtil/glslUtil.c +++ b/glslUtil/glslUtil.c @@ -27,7 +27,7 @@ void guMatrixMult(guMatrix4x4 *m, guMatrix4x4 *a, guMatrix4x4 *b) { for (j = 0; j < 4; j++) { - float v = 0.0; + GLfloat v = 0.0; for (p = 0; p < 4; p++) { v += (*a)[i][p] * (*b)[p][j]; @@ -37,7 +37,7 @@ void guMatrixMult(guMatrix4x4 *m, guMatrix4x4 *a, guMatrix4x4 *b) } } -void guMatrixTranslate(guMatrix4x4 *m, float x, float y, float z) +void guMatrixTranslate(guMatrix4x4 *m, GLfloat x, GLfloat y, GLfloat z) { int i; for (i = 0; i < 4; i++) @@ -46,12 +46,12 @@ void guMatrixTranslate(guMatrix4x4 *m, float x, float y, float z) } } -void guMatrixScale(guMatrix4x4 *m, float x, float y, float z) +void guMatrixScale(guMatrix4x4 *m, GLfloat x, GLfloat y, GLfloat z) { int i; for (i = 0; i < 4; i++) { - float *base = &(*m)[i][0]; + GLfloat *base = &(*m)[i][0]; base[0] *= x; base[1] *= y; base[2] *= z; @@ -59,9 +59,9 @@ void guMatrixScale(guMatrix4x4 *m, float x, float y, float z) } void guMatrixFrustum(guMatrix4x4 *m, - float left, float right, - float bottom, float top, - float near, float far) + GLfloat left, GLfloat right, + GLfloat bottom, GLfloat top, + GLfloat near, GLfloat far) { int i, j; guMatrix4x4 mult; diff --git a/glslUtil/glslUtil.h b/glslUtil/glslUtil.h index 93653cf..1d961d2 100644 --- a/glslUtil/glslUtil.h +++ b/glslUtil/glslUtil.h @@ -8,7 +8,7 @@ #include #endif -typedef float guMatrix4x4[4][4]; +typedef GLfloat guMatrix4x4[4][4]; #ifdef __cplusplus extern "C" { @@ -16,12 +16,12 @@ extern "C" { void guMatrixLoadIdentity(guMatrix4x4 *m); void guMatrixMult(guMatrix4x4 *m, guMatrix4x4 *a, guMatrix4x4 *b); -void guMatrixTranslate(guMatrix4x4 *m, float x, float y, float z); -void guMatrixScale(guMatrix4x4 *m, float x, float y, float z); +void guMatrixTranslate(guMatrix4x4 *m, GLfloat x, GLfloat y, GLfloat z); +void guMatrixScale(guMatrix4x4 *m, GLfloat x, GLfloat y, GLfloat z); void guMatrixFrustum(guMatrix4x4 *m, - float left, float right, - float bottom, float top, - float near, float far); + GLfloat left, GLfloat right, + GLfloat bottom, GLfloat top, + GLfloat near, GLfloat far); #ifdef __cplusplus }