Login  Register

Re: Need help debugging a texture issue

Posted by DamagedTiberius on May 19, 2020; 3:21pm
URL: https://forum.jogamp.org/Need-help-debugging-a-texture-issue-tp4040473p4040643.html

I finally figured out my issue.

It was due to the OpenGL context backing the GLJpanel being destroyed and replaced. It makes sense to me now, but I didn't realize I needed to destroy and recreate my textures (along with vertex buffers and any other GPU resources). It hadn't come up in the tutorials I followed, so I hadn't thought to look there.

This was the kind of general advice I was hoping someone might be able to offer. Something along the lines of: If you're seeing issues where something stops drawing correctly after [INSERT LIST OF ACTIONS CAUSING A CONTEXT TO BE REPLACED HERE], double check that you're destroying your OpenGL resources and regenerating them for the next render call.

I suspect that there are probably a handful of JOGL-specific concepts along these lines that someone new to the API needs to be very aware of but may not be clearly addressed in the various tutorials out in the wild. It could be incredibly helpful to have an FAQ/Troubleshooting document somewhere to point people towards.

gouessej wrote
Sven Gothel wrote
WorldWind is using our latest RC, they do maintain a source drop-in AFAIK.
This happened when they restarted their WorldWind efforts.

~Sven
Thank you for the reminder. Therefore, I advise the original poster to upgrade to the latest version of WorldWind in order to use the latest version of JOGL.
My customer prefers staying with the last official release of World Wind for the moment (simply part of the list of things not within my control right now). I'm very much looking forward to the next World Wind release though.