summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIan Romanick <ian.d.romanick@intel.com>2009-12-02 18:11:52 -0800
committerIan Romanick <ian.d.romanick@intel.com>2009-12-03 11:50:09 -0800
commit89feae7c12dd703804c93f784f9bd7e39fcc7f60 (patch)
tree054ef01d7fc1cc8191999af5c3aebb0e14c1ff2f
parent19f7c8d47e747ec2e80bf21d76cada0c991505d6 (diff)
Fix parameter ordering of projection matrix functions
The GL and (classic) GLU functions that these emulate have bottom before top. Reorder the parameters to these functions to match.
-rw-r--r--include/glu3.h12
-rw-r--r--src/matrix.c10
2 files changed, 11 insertions, 11 deletions
diff --git a/include/glu3.h b/include/glu3.h
index 5d30911..f67c554 100644
--- a/include/glu3.h
+++ b/include/glu3.h
@@ -480,8 +480,8 @@ void gluLookAt4v(GLUmat4 *result, const GLUvec4 *eye, const GLUvec4 *center,
* If either\c near or \c far are negative, the function returns without
* writing any value to \c result.
*/
-void gluFrustum6f(GLUmat4 *result, GLfloat left, GLfloat right, GLfloat top,
- GLfloat bottom, GLfloat near, GLfloat far);
+void gluFrustum6f(GLUmat4 *result, GLfloat left, GLfloat right, GLfloat bottom,
+ GLfloat top, GLfloat near, GLfloat far);
/**
* Calculate a perspective projection matrix
@@ -539,8 +539,8 @@ void gluPerspective4f(GLUmat4 *result, GLfloat fovy, GLfloat aspect,
*
* \sa gluOrtho6f
*/
-void gluOrtho4f(GLUmat4 *result, GLfloat left, GLfloat right, GLfloat top,
- GLfloat bottom);
+void gluOrtho4f(GLUmat4 *result, GLfloat left, GLfloat right, GLfloat bottom,
+ GLfloat top);
/**
* Generate an orthographic projection matrix
@@ -570,8 +570,8 @@ void gluOrtho4f(GLUmat4 *result, GLfloat left, GLfloat right, GLfloat top,
*
* \s gluOrtho4f
*/
-void gluOrtho6f(GLUmat4 *result, GLfloat left, GLfloat right, GLfloat top,
- GLfloat bottom, GLfloat near, GLfloat far);
+void gluOrtho6f(GLUmat4 *result, GLfloat left, GLfloat right, GLfloat bottom,
+ GLfloat top, GLfloat near, GLfloat far);
/*@}*/
/**
diff --git a/src/matrix.c b/src/matrix.c
index 9fb356d..e2f02e4 100644
--- a/src/matrix.c
+++ b/src/matrix.c
@@ -157,7 +157,7 @@ void gluRotate4v(GLUmat4 *result, const GLUvec4 *_axis, GLfloat angle)
void
gluFrustum6f(GLUmat4 *result,
- GLfloat left, GLfloat right, GLfloat top, GLfloat bottom,
+ GLfloat left, GLfloat right, GLfloat bottom, GLfloat top,
GLfloat near, GLfloat far)
{
if ((right == left) || (top == bottom) || (near == far)
@@ -206,7 +206,7 @@ gluPerspective4f(GLUmat4 *result,
void
gluOrtho6f(GLUmat4 *result,
- GLfloat left, GLfloat right, GLfloat top, GLfloat bottom,
+ GLfloat left, GLfloat right, GLfloat bottom, GLfloat top,
GLfloat near, GLfloat far)
{
if ((right == left) || (top == bottom) || (near == far))
@@ -224,8 +224,8 @@ gluOrtho6f(GLUmat4 *result,
void
-gluOrtho4f(GLUmat4 *result, GLfloat left, GLfloat right, GLfloat top,
- GLfloat bottom)
+gluOrtho4f(GLUmat4 *result, GLfloat left, GLfloat right, GLfloat bottom,
+ GLfloat top)
{
- gluOrtho6f(result, left, right, top, bottom, -1.0, 1.0);
+ gluOrtho6f(result, left, right, bottom, top, -1.0, 1.0);
}