Hey!
I am looking into jogl and lwjgl at the moment, and i wonder why
they both need the use of nio buffers. I know opengl from c++ programming;
if I wanted to pass data to a function, I passed the pointer - very easy.
Now in java, I have to create a nio buffer… very unused to me, feels really
strange.
My question is: Why exactly are these buffers needed ? I suppose because
of different memory layouts of java arrays and c arrays, is that right ? If I put
an int into an IntBuffer, the format of the integer gets converted from java to c ?
I had a look into C# and the Tao framework, and it seems they don´t need it.
Tao allows to pass C# arrays directly to GL, which seems to be much more convenient.
Maybe I am to picky about these things, but I don´t really like these unstructured
primitive buffers… they feel a bit like a hack, but maybe I am wrong - tell me, please
thanks,
Frederick