Jump to content

  • Log In with Google      Sign In   
  • Create Account


erwincoumans

Member Since 24 Jul 2005
Offline Last Active Oct 26 2012 04:27 PM
-----

Posts I've Made

In Topic: ogrekit applyTorque orientation problem

26 October 2012 - 11:35 AM

You need to use the local X axis for example:

btVector3 torqueAxis = body->getWorldTransform().getBasis().getColumn(0);

Here is some modified BasicDemo that might help you, you can use the cursor keys to move and rotate a 'character' capsule:
http://bulletphysics.org/Bullet/phpBB3/viewtopic.php?p=29081#p29081

In Topic: Bullet Physics Changing RigidBody Position

26 October 2012 - 11:10 AM

Instead of directly changing the position, it is better to change the velocity.

Here is some sample code to show how this can work
http://bulletphysics.org/Bullet/phpBB3/viewtopic.php?p=29081#p29081

In Topic: Stopping 2 Rigid Bodies from Intersecting

26 October 2012 - 11:06 AM

Start with an unmodified Bullet demo, such as Bullet/Demos/BasicDemo and make sure the collisions work properly there.
Then compare the setup with your own, so find the problem.

Thanks,
Erwin

In Topic: Convex Hull 3D with gift wrapping - advanced

13 September 2011 - 09:39 AM

We implemented a robust convex hull in our open source Bullet physics library too. There is an option to create a convex hull of a point cloud, used for the separating axis test and contact clipping.

In a nutshell, we first compute the 3D convex hull, using integer arithmetic to avoid numerical issues. This can still generate coplanar faces. The algorithms we use (separating axis and contact clipping) can deal with those coplanar faces, so we could use this and have a robust solution. This implementation is used in the commercial 3D modeler Cinema 3D.

For optimization reasons, I added a second pass that searches coplanar faces and merges them using a 2d convex hull algorithm (Graham scan). To project the 3D faces in the 2D plane, I compute the shortest arc from the xy-plane normal to the face normal, and use that to rotate the 3D vertices into the xy plane, and manually clear the Z coordinate. This second pass is not perfectly robust, so it could create small gaps in the convex hull.

For more information, see http://code.google.c...s/detail?id=275 and Bullet/src/LinearMath/btConvexHullComputer.cpp and the initializePolyhedralFeatures method in Bullet/src/BulletCollision/CollisionShapes/btPolyhedralConvexShape.cpp

Do you have some unit tests with hard/degenerate cases that you can share?
Thanks,
Erwin

In Topic: Bullet: Character Controller falls through the ground when terrain is at maxs...

03 August 2011 - 08:34 AM

I tried to reply your question in the Bullet forums here:
http://bulletphysics.org/Bullet/phpBB3/viewtopic.php?f=9&t=7185


Note that everyone is busy, and the Bullet forums are not as active as gamedev.net, so you might not always get a reply.
Thanks,
Erwin

PARTNERS