in the newer versions it was split up between rotatef and rotated? Both do what rotate did?

No, it's always been split up like that - at least since OpenGL 1.0 anyway. I don't know about IRIS GL as I never used it.

Quote

which would imply that i am still waiting for documentation when the real version comes out (lwjgl 1.0)

Well, "rotate" is just pure OpenGL, so I wouldn't wait for LWJGL docs for that kind of thing. Just find a downloadable copy of the OpenGL Redbook (up to version 1.2 I think is now freely available), or pull the OpenGL specs from http://www.opengl.org/developers/documentation/specs.html.

So the double version is just for added precision. If you don't need it just stick with floats. The "usual" way of using this method is just to use 1.0f on the axis you want to rotate around, so a rotation of 45 degrees about the Z-axis would be "gl.rotatef(45.0f, 0.0f, 0.0f, 1.0f)".

It's all very well having an API that allows you to do loads of different things, but there are some things you either shouldn't do or shouldn't bother doing, like transforming your viewing matrix or assuming your target platform has an AUX buffer or using unnecessary precision. That'd be useful.

DESCRIPTION glRotate produces a rotation of angle degrees around the vector (x,y,z). The current matrix (see glMatrixMode) is multiplied by a rotation matrix with the product replacing the current matrix, as if glMultMatrix were called with the following matrix as its argument:

x2(1-c)+c xy(1-c)-zs xz(1-c)+ys 0

yx(1-c)+zs y2(1-c)+c yz(1-c)-xs 0

( )

xz(1-c)-ys yz(1-c)+xs z2(1-c)+c 0

0 0 0 1

Where c=cos(angle), s=sin(angle), and ||(x,y,z)||=1 (if not, the GL will normalize this vector).

If the matrix mode is either GL_MODELVIEW or GL_PROJECTION, all objects drawn after glRotate is called are rotated. Use glPushMatrix and glPopMatrix to save and restore the unrotated coordinate system.

NOTES This rotation follows the right-hand rule, so if the vector (x,y,z) points toward the user, the rotation will be counterclockwise.

ERRORS GL_INVALID_OPERATION is generated if glRotate is executed between the execution of glBegin and the corresponding execution of glEnd.

I'll just used multMatrix anyway, since eventually I had to do it that way. Byt the way, princec? Want that quaternion class(I mean the whole thing)? It is done in the same way as lwgjl Vector4f, except that it is quaternion. I have the most used primitive methods. in there. I think it is quite understandable and easy to use. I'll look through my math books tonight and figure out some possible optimizations.

java-gaming.org is not responsible for the content posted by its members, including references to external websites,
and other references that may or may not have a relation with our primarily
gaming and game production oriented community.
inquiries and complaints can be sent via email to the info‑account of the
company managing the website of java‑gaming.org