Login  Register

Re: Incorrect context on GLCanvas drawable

Posted by MarcoNL on Nov 15, 2021; 8:13am
URL: https://forum.jogamp.org/Incorrect-context-on-GLCanvas-drawable-tp4041391p4041494.html

Hi Martin,

thank you for your feedback, I appreciate.

Well, I confirm that an OpenGL 4.6 context is returned both in the case the noddraw system property is NOT passed, and in the case opengl=true is passed. This happens because, for some reason, in both cases just a single GraphicsConfiguration is returned for each GraphicsDevice.

On the other side, with noddraw=true, 6 GraphicsConfiguration are returned for each GraphicsDevice, and this seems to be the actual source of problems for the GLContext of my GLCanvas. BTW, these 6 GraphicsConfiguration are "similar" but not identical, as they only differ for their "pixel format" attribute.

Unfortunately, both workarounds (1. avoiding passing noddraw=true, 2. passing opengl=true) are NOT viable solutions for me.

In fact:

1) If I don't pass noddraw=true, I have rendering issues both with JOGL and within the rest of my application.

2) If I pass opengl=true, with many graphics adapters' device drivers I have Swing rendering artifacts and issues within my application. E.g., incorrect painting of toolbar buttons, etc.

So, I need to return to my initial question: why in the case 6 GraphicsConfigurations are returned, and getConfigurations() is called, then GLCanvas is initialized with an Open GL 1.1 context (at least with all NVIDIA adapters)? Is this something which can be corrected in JOGL?

I am looking forward to hearing from you.
Thanks and best regards,

Marco Sambin