Login  Register

[SOLVED] Problem Moving from 1.1.1a -> 2.0

Posted by sorghumking on Mar 14, 2012; 7:04pm
URL: https://forum.jogamp.org/SOLVED-Problem-Moving-from-1-1-1a-2-0-tp3826486.html

Hi all,

I inherited a geology visualization project running against JOGL 1.1.1a.  Various drawing issues prompted me to give JOGL 2 a try, and to my great joy, it fixed nearly all of them!  However, it also introduced a new problem that has me puzzled.  The software is intended for use on multiple displays to provide a larger workspace (sediment cores can be very long).  As implemented, each display is assigned a GLCanvas embedded in a JFrame.  All canvases are constructed with a common GLContext in order to share textures, display lists, etc.  The first instantiated canvas works perfectly, but subsequent canvases exhibit two problems:

1. Primitives draw in black regardless of the most recent glColor() call
2. Text rendering, which is all display-list based, doesn't work at all

This worked correctly in 1.1.1a.  That said, I'm quite sure this is my problem, not JOGL's!  I've confirmed that the canvases are using the same GLContext, and repeated checks of glGetError() yield nothing.  It's been a whlie since I"ve worked with OpenGL, but some of the code looks a bit sloppy as far as consistent enabling/disabling of features, etc: is JOGL2 pickier about such things than 1.1.1a?  Another wrinkle that may be a factor: all rendering takes place in JNI calls rather than Java.

Does this issue sound familiar to anyone? Perhaps I overlooked something in the transition to 2.0?

Any ideas/suggestions would be greatly appreciated!