Advertisement

Havok 4 volumes: action at a distance


This week the main Second Life grid finally upgraded to Havok 4. Watching another user puzzling over a physics-based piece of gimcrackery that wasn't working properly, we decided to take a look at the way Havok 4 is processing collisions in a practical way. By making lots of physics things, and -- you know -- shoving them about to see what happened.

After about 30 minutes of experimentation it became clear that collision volumes for prims are being calculated very oddly indeed.

The collision volume, essentially is the size and shape that the physics engine thinks the prim is, as opposed to the size and shape of the graphical mesh. Obviously for best results, the two should be quite congruent.

As you'll see in the image above, we created three prims of various shapes and set them physical. The floor is a rectangular prim itself. Each prim floats 0.05 metres above the floor. Actually, my own avatar is about the same distance above the prim floor.

Furthermore if you try to push two physical prims together you will find that they will not approach closer than 0.05 metres apart before they 'collide'. The physics system thinks they are larger than they are. Exception: Spheres collide with other spheres visible-surface-to-visible-surface. All other shapes appear to have collision volumes that are larger than their visible extent.

It's the same for hollow shapes. Hollow out any prim and drop some physical spheres into it. The spheres all touch each-other, but stand away about 0.05 metres from the hollowed prim (even if that hollowed prim is a sphere itself -- only the external surface of a sphere has a collision volume that matches the visible prim extents.

In this image, the upper cube is physical and actually at rest on the lower one. The torus is pushed up against the cube as close as it can go.

All in all, it is a very interesting result. Is this a minor glitch or is this something that breaks your content?