I’m starting to get into libGDX game engine. I have copied this example and tried to run.
It runs ok as android application, but when i want it to run as java application it throws the following error.
Exception in thread “Thread-2” javax.media.opengl.GLException:
javax.media.opengl.GLException: Method “glActiveTexture” not available
Maybe you should change this line:
GL10 gl = Gdx.graphics.getGL10();toGL20 gl = Gdx.graphics.getGL20();. Because according to the official OpenGL documentation:The difference may lie in the fact that Windows by default gives a OpenGL 1.1 context and only offers all the additional functionality via extensions (i.e.
glActiveTextureARB()which the Java OpenGL might not use)