Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Are there any decent physics engines for Android? [closed]

Tags:

I've looked around for a physics engine that will play nicely with Android, but I've only been disappointed.

In terms of performance, I had heard that jbox2d was the best bet, but (from my understanding) ever since Android SDK V1.0, the Dalvik VM's verifier has become very strict and rejects some of the key classes and refuses to run. This problem persists after using the dx tool (although I might be using the tool improperly).

I know that the AndroidBox2D porting project exists to optimize jbox2d for the Android garbage collector, but the project page doesn't have any downloads and the gpl license isn't as attractive as the zlib license of the original.

Does anyone have any tips for making jbox2d work in Eclipse, or have any recommendations for where I should start looking?

like image 796
Marc Avatar asked Jun 23 '09 18:06

Marc


2 Answers

I don't know why Dalvik would reject classes unless they were obfuscated with some tool. Did you try recompiling Box2d from source?

The only other Java lib I've seen is http://www.cokeandcode.com/phys2d/

like image 73
sehugg Avatar answered Oct 17 '22 02:10

sehugg


I am getting good results with the Java version of APE using Fixed Point math rather than floats.

http://www.cove.org/ape/

like image 33
John Avatar answered Oct 17 '22 01:10

John