Re: JOGL Shader VM Crash
Posted by François Coupal on Mar 07, 2011; 3:43pm
URL: https://forum.jogamp.org/JOGL-Shader-VM-Crash-tp2638696p2646583.html
I had a very similar problem. The solution may very well be to upgrades the drivers, but I managed to craft an hypothesis as to why.
Thing is, the hasGL() method may return true, but some GL extensions may not be supported (such as GL_MULTISAMPLE) that your shader code will try to use. So when you create the program, during the linking process, it will try to find an internal method with this extension, and will probably create a segmentation fault, thereby crashing your JVM.
That ONLY workaround I've found so far, one that does not rely on the driver not to implode when trying to compile a Shader, is to pre-check the extensions, then decide if you will even try to compile the shader.
Granted, it's a royal pain in the ass to find which extensions will be used by a particular shader. So far, I've only been able to using trial and error. Extension lists documentation for OpenGL are very hard to find.