Re: Negating some JNI call overhead by doing transformations in Java
Posted by Demoscene Passivist on Jul 21, 2011; 12:11pm
URL: https://forum.jogamp.org/Negating-some-JNI-call-overhead-by-doing-transformations-in-Java-tp3188212p3188364.html
>Most modern scenegraphs compute transforms on the CPU side and call
>glLoadMatrix and co. only in a very few cases (even never when using only shaders)
I guess Julien means "GPU side" not "CPU side". And he's absolutely right, as API call overhead is immense in general regardless of the programming language or graphics API u use (Direct3D has the same problem as OpenGL here). So JNI call overhead or Java isn't the problem here. As Julien already pointed out, a good approach is to offload as many calculations as possible to the GPU and only set a couple of uniforms and let a GLSL vertex/geometry shader do the transforms.