GLU Gripe

Started by Orangy Tang, March 07, 2005, 09:20:40

Previous topic - Next topic

Orangy Tang

Ages ago, I used LWJGL's glu, and all was good. However I've since had to use gluProject and can't help notice that its a real pain to use now. :shock:

As some nice person has ported gluProject to java code, they seem to have buggered around with the method signiture, which now takes a collection of float[], float[][] and int[] (rather than Float/IntBuffers). This is a real pain because now I've got to glGet into a set of buffer, create a bunch of native arrays, unpack them (while trying to remember the collumn ordering for OpenGL) and then finally use gluProject.

Before it was much easier because you could just go straight from glGet to gluProject with no messing around with conversion (in fact the OpenGL docs even say "The current projection matrix (as from a glGetDoublev call)."

Can we please have one of:
1. A gluProject with the 'old' method signiture back (even if this just wraps the current version).
2. Some utils to convert between FloatBuffer etc. and native arrays/matrices (I don't see anything in the Matrix etc. classes).
3. The original (native) version back.

'1' is probably less than ideal, as you'd need some dynamic new'ing of native arrays. '3' makes porting harder I guess, so 2 would be nice.