OpenSimulator Bullet Physics Library Logo Title

Bullet – physics installation for OpenSim

Introduction to Bullet:

Bullet is the modern physics engine that the OpenSim dev team are heading towards during the version 8.x builds of OpenSim. Although it’s only bullet version 2.x it provided a more robust collision detection for regions to make them feel more like the Second Life regions. It is uncertain of Bullet development will continue with the introduction of AviNations code-merge of their updated ODE Physics which allow for better prim sitting and vehicle crossing from region to region. Currently, although you can follow all of the steps and compile bullet onto your Arm based Pi. Bullet simple does not run and you must run Bullet in XNA mode which isn’t optimal.

How to install bullet physics onto your OpenSim metaverse environment:

modify your  OpenSim.ini as follows at around line 240:

    ;; Choose one of the physics engines below
    ;# {physics} {} {Select physics engine} {BulletSim OpenDynamicsEngine basicphysics POS} BulletSim
    ;; OpenDynamicsEngine was the previous default physics engine in OpenSimulator and before.
    ;; It continues to provide a workable physics implementation.  ODE does not currently support varregions.
    ;; basicphysics effectively does not model physics at all, making all objects phantom.
    ;; Default is BulletSim
    ; physics = OpenDynamicsEngine
    physics = BulletSim
    ; physics = basicphysics
    ; physics = POS

Errors of BulletSIM:

bullet physics - UNHANDLED EXCEPTION: System.DllNotFoundException: BulletSim errors!

As of OpenSim version 0.8.x and beyond the new physics standard is now “Bullet” and ODE or “OpenDynamicsEngine” physics has been demoted to a backup.

Installing BulletXNA (Bullet Managed Mode):

Open your /bin/OpenSim.ini file and add this to the bottom of your file.

    UseSeparatePhysicsThread = true
    BulletEngine = "bulletxna"

What this will do is you are telling the Mono engine to handle Bullet physics via XNA instead of relying on the linux libraries to handle the data back and forth. The results for prims and avatars is very good! However, users may encounter issues with mesh objects especially if the collision data is either lacking or not a perfect hull such as a ‘box’. The advantage is you now have bullet physics just like everyone else running OpenSim 0.8.x! Yay! The downside of bulletXNA is it eats up a lot more processor power as your relying on the heavy handed mono engine to do all of the heavy lifting for you.

This is a classic case of the libraries getting far more advanced then the application they support. Perhaps in the future the OpenSim dev team will link to natively so we do not have to rely on compiling the libraries on every Linux box ourselves. Until that time comes. This is the best solution I can come up with thus far.

Installing (Bullet Unmanaged Mode):

Compiling bullet underneath debian wheezy was virtually impossible generating tons and tons of hard-crash errors as described by this blog. However, with the introduction of Debian Jessie on newer model of Pi’s compiling bullet 2.82 onto the ARM processor not only compiles with no errors, but is also stable for OpenSim usage now too.

to compile your own file, it’s a two fold process. The first part is making the bullet libraries from 2.82 (both the .h and .a files necessary for compilation)

apt-get update
apt-get upgrade
tar -zxvf bullet-2.82-r2704.tgz
cd bullet-2.82-r2704
mkdir bullet-build
cd bullet-build
make -j4 
sudo make install

Now we need to download the opensim-libs and get libBulletSim:

git clone git://
cd /opensim-libs/trunk/unmanaged/BulletSim

Now before you type in make you may have to modify the “Makefile” to point to where the IDIR = /usr/local/include/bullet and LDIR = /usr/local/lib go to. Alternatively, you could simply bring all of the .a and .h files and make a /lib and /include folder inside of BulletSim accordingly.


if it compiles with no errors of files not found it should generate a brand spanky new

cp ./ /path/to/opensim/lib/

Open your /bin/OpenSim.ini file with your favorite editor such as nano and add this to the bottom of your file.

UseSeparatePhysicsThread = true
BulletEngine = "BulletUnmanaged"

Next open /bin/OpenSim.Region.PhysicsModule.BulletS.dll.config for OS9.x or /bin/Physics/OpenSim.Region.Physics.BulletSPlugin.dll for OS8.x and replace everything in there with the following:

  <dllmap dll="BulletSim" target="lib/" />

Like the ODE physics blog this will tell OpenSim where to look for said Physics file.

if everything goes well, it should find your new library and not have a horrible crash.

[quote]Can I just get the from you?[/quote]

Download Bone and Helper Files for StepMania Now! binary download.

Most people in the Linux community will give you the lecture of how pre-compiled binaries and slamming them into other linux environments can produce unstable results, and they are right! But for those who do not want to go through all of the “fun” of compiling the uploaded pre-compiled version is available right here. This is originally compiled on a Orange Pi running Debian Jessie. It does work on the banana Pi which has a ARMv7 processor and it works on the Raspberry Pi 2 as well. If you have a different processor other then ARM or running another flavor of Linux then the pre-compiled version will not work out for you.

What’s faster? Bullet Unmanaged or Bullet Managed?

it seems like performance between the two are almost the same. They both eat up around %20 processor power of one core on my Banana or Orange Pi. Although the collision matrix seems to be a lot more accurate other things like sitting on objects is still a little flakey with bullet.

OpenSimulator on Raspberry Pi - TitleClick here to return back to the OpenSim tutorial for Raspberry Pi.


Leave a Comment