[Snap 8.0] javax.media.opengl.GLException

Hi all.
I installed version 8.0 of Snap on my laptop with Ubuntu 20.04 LTS, 32 GB of RAM, and at startup I have this error:

javax.media.opengl.GLException: Profiles [GL4bc, GL3bc, GL2, GLES1] not available on device null
	at javax.media.opengl.GLProfile.get(GLProfile.java:949)
	at javax.media.opengl.GLProfile.get(GLProfile.java:960)
	at javax.media.opengl.GLProfile.getMaxFixedFunc(GLProfile.java:713)
	at gov.nasa.worldwind.Configuration.getMaxCompatibleGLProfile(Configuration.java:658)
	at gov.nasa.worldwind.Configuration.getRequiredGLCapabilities(Configuration.java:671)
	at gov.nasa.worldwind.awt.WorldWindowGLCanvas.<init>(WorldWindowGLCanvas.java:96)
	at org.esa.snap.worldwind.AppPanel.<init>(AppPanel.java:69)
	at org.esa.snap.worldwind.WWBaseToolView.createWWPanel(WWBaseToolView.java:48)
[catch] at org.esa.snap.worldwind.WWWorldViewToolView$1.doInBackground(WWWorldViewToolView.java:116)
	at javax.swing.SwingWorker$1.call(SwingWorker.java:295)
	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
	at javax.swing.SwingWorker.run(SwingWorker.java:334)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
	at java.lang.Thread.run(Thread.java:748)

I tryed to switch to WorldWind flat mode but without succes. Reading some issue on stackoverflow I intend that maybe there is an incompatibility with JOGL.

Any suggestion?


You should mention your graphics hardware, the linux driver, and whether you use Wayland or X11.

NASA WorldWind used to have extensive installation instructions that dealt with OpenGL issues. The current version targets Java 11. I assume SNAP is using an older version.
In the past I have used JOGL Demos and WorldWind Demos to sort out linux graphics issues independ of SNAP.

Thanks for reply. I’m using X11 and may graphics hardwere is an integrated Intel UHD Graphics 620

costantino@lavoro:~$ sudo lshw -c video
[sudo] password di costantino: 
       description: VGA compatible controller
       product: UHD Graphics 620 (Whiskey Lake)
       vendor: Intel Corporation
       physical id: 2
       bus info: pci@0000:00:02.0
       version: 02
       width: 64 bits
       clock: 33MHz
       capabilities: pciexpress msi pm vga_controller bus_master cap_list rom
       configuration: driver=i915 latency=0
       resources: irq:145 memory:a0000000-a0ffffff memory:90000000-9fffffff ioport:2000(size=64) memory:c0000-dffff
costantino@lavoro:~$ echo $XDG_SESSION_TYPE

I will try with your links, thanks

A couple things that may help with troubleshooting:

  • Does glxgears work?

  • Have you installed the current updates to your linux distro, in particular Mesa?

  • Does the error go away if you use export LIBGL_ALWAYS_SOFTWARE=1 and then
    run snap from the same terminal (so it will see the changed environment)?

I have the same problem on SNAP 9.

  • it used to work on SNAP 8 AFAICT (I can check if needed)
  • Switching to the flat Earth projection in settings doesn’t help
  • I’m using GNOME/Wayland
  • I’m on Arch Linux, so I have recent versions of everything
  • LIBGL_ALWAYS_SOFTWARE=1 does nothing
  • OpenGL works fine on my system:
OpenGL vendor string: AMD
OpenGL renderer string: AMD Radeon RX 6800 XT (sienna_cichlid, LLVM 14.0.6, DRM 3.47, 5.19.12-arch1-1)
OpenGL core profile version string: 4.6 (Core Profile) Mesa 22.1.7
OpenGL core profile shading language version string: 4.60
OpenGL core profile context flags: (none)
OpenGL core profile profile mask: core profile
OpenGL core profile extensions:
OpenGL version string: 4.6 (Compatibility Profile) Mesa 22.1.7
OpenGL shading language version string: 4.60
OpenGL context flags: (none)
OpenGL profile mask: compatibility profile
OpenGL extensions:
OpenGL ES profile version string: OpenGL ES 3.2 Mesa 22.1.7
OpenGL ES profile shading language version string: OpenGL ES GLSL ES 3.20
OpenGL ES profile extensions:

Found a workaround:

$ cp /usr/lib/libstdc++.so.6.0.30 ~/.snap/auxdata/gdal/gdal-3-2-1/lib/jni/libstdc++.so.6