Is there a LWJGL port for Android available? (does not matter if the phone needs to rooted)
4 Answers
Things have happened since this question was answered in 2011.
It is new that LWJGL has support for Android.
The linked repo has the setup instructions and the demo, the actual code is in the LWJGL3 repo under the Android branch.
I've been using it for a while now, and this library has a bunch of useful features that aren't just connected to OpenGLES, OpenAL, OpenVR and Vulkan, but it also has a lot of utilities for things like 3D model loading, layouts, dialogs, fonts and a lot more. Meaning the Android port of LWJGL is a considerable add-on to the current OpenGL ES support.
As for other libraries though, you can use no libraries because of the native support. Alternatively, you can use LibGDX or jMonkeyEngine, those are the only two others I know of and have used. Note that these are frameworks and not libraries like LWJGL, meaning they set up a given system you have to follow (one of the reasons I dislike them). It's harder implementing custom features without having to bring out a lot of other parts of the framework that aren't that well documented.

- 27,060
- 21
- 118
- 148
One of LWJGL's main features is its OpenGL support. Android natively supports OpenGL ES so there's basically no need for LWJGL. As for the rest of LWJGL, it doesn't apply on the Android platform anyway - for example there is obviously no mouse to an Android device - so I don't see a direct LWJGL port ever being developed.
Check out the Android reference, especially the android.opengl package, for a good starting point.

- 33,368
- 30
- 112
- 143
-
12but a port of LWJGL would make it easier to devetop cross platform on Android and Desktop. – Arne Sep 04 '11 at 19:17
-
Perhaps, but since LWJGL was not architected for that from the beginning, it would probably require some big changes in LWJGL. I would recommend [libgdx](http://code.google.com/p/libgdx/) for cross-platform desktop/Android development. Alternately just organize your project as a library project, a desktop project and an Android project. I'm currently doing that for a project of mine (but it's not using OpenGL so it's easy for me to divide it that way). – Ricket Sep 05 '11 at 16:49
-
An Android device may have a pointer if a mouse is connected XD – Cliff Burton May 30 '17 at 13:11
-
@CliffBurton Good point! The first version of Android to feature USB host support, for mice and other accessories, was 3.1 Honeycomb, which was released several months after I wrote this answer. I'm also not sure if this answer is otherwise up to date, it might need updating to account for the past 6 years of progress... – Ricket Jun 09 '17 at 22:03
A good 3D and 2D engine that uses LWJGL and works well for Android development (and also Desktop and Web Apps) is libGDX.

- 118
- 1
- 12

- 1,717
- 1
- 17
- 30
I can't say for sure, but during last autumn I was searching for quite a long time for that and couldn't find anything. So I would say no, but don't bank on that.
-
1Ok... Is there then any 3D gaming java library that does work on mobile devices? And is there a way to "convert" them easily over, or does it take complete rewriting of the code? – Deniz Zoeteman Jan 03 '11 at 20:39
-
Maybe jMonkey can do the job of integrating native java games to android. – Thiago Macedo Feb 14 '13 at 04:42