Login  Register

Re: JOGL 2.0 (OpenGL/OpenGL-ES) backend for LibGDX

Posted by Xerxes Rånby on Feb 19, 2013; 11:47am
URL: https://forum.jogamp.org/JOGL-2-0-OpenGL-OpenGL-ES-backend-for-LibGDX-tp4027689p4028278.html

krishnak wrote
I modified the single line as per this commit in my JMonkeysource
https://github.com/noxo/jmonkey-engine-jogl-gles/commit/cbb22843dd98532cee1e2727049ca9f043158195

After rebuilding everything on the PC and making sure it works, I moved it to Pi
In the  PI, things are moving forward but  now I am getting a JOAL error - the native library is in the folder
pi@raspberrypi ~/jogamp $ java -jar test2.jar
...
        at mygame.HelloPhysics.main(HelloPhysics.java:28)
Caused by: java.lang.ExceptionInInitializerError
        at com.jogamp.openal.ALFactory.initialize(ALFactory.java:60)
...
EGLDisplayUtil.EGLDisplays: Shutdown (open: 1)
EGLDisplayUtil: Open EGL Display Connections: 1
EGLDisplayUtil: Open[0]: 0x1: refCnt 1
This time its the JOAL OpenAL-soft sound initialization that fail, you run into this because you try use the latest JogAmp test build.
We are actively working on this, currently we bundle OpenAL-soft with JOGL compiled for ARMv7, JogAmp needs to lower the cross compile C options to target ARMv6 in order to make the JogAmp JOAL builds fully RaspberryPi compatible, the RaspberryPi CPU is ARMv6.

The workaround for you is to pass -Djoal.openal.lib=system JOAL will then use the OpenAL library provided by your RaspberryPi linux distribution. Its possible that you may need to install the libopenal1 package.
sudo apt-get install libopenal1
For more information see BUG 662 or the following git commit:
https://github.com/sgothel/joal/commit/92e931caf64cf24e2b885d2552e64aebcf70a45a