Search found 15 matches
- Mon Nov 20, 2023 1:41 am
- Forum: General Bullet Physics Support and Feedback
- Topic: Recursive btCompoundShape oddities
- Replies: 0
- Views: 2122
Recursive btCompoundShape oddities
I've read that creating a hierarchy of btCompoundShapes should work, but I'm having an issue with it. My tree looks like this: btCompoundShape / | \ (btSphereShape, btCompoundShape) (btSphereShape, btCompoundShape) (btSphereShape, btCompoundShape) | | | (btSphereShape, btCompoundShape) (btSphereShap...
- Mon Nov 20, 2023 12:37 am
- Forum: General Bullet Physics Support and Feedback
- Topic: Using btIndexedMesh with btTriangleIndexVertexArray+btBvhTriangleMeshShape
- Replies: 3
- Views: 2076
Re: Using btIndexedMesh with btTriangleIndexVertexArray+btBvhTriangleMeshShape
Thank you!
That makes sense... sneaky. This language is no nuanced.
That makes sense... sneaky. This language is no nuanced.
- Tue Oct 31, 2023 7:19 pm
- Forum: General Bullet Physics Support and Feedback
- Topic: Using btIndexedMesh with btTriangleIndexVertexArray+btBvhTriangleMeshShape
- Replies: 3
- Views: 2076
Re: Using btIndexedMesh with btTriangleIndexVertexArray+btBvhTriangleMeshShape
Here is what I have found. Recall my face/triangle and vertex data are declared in the GeometryElement class interface as: std::vector<Vertex> _vertices; std::vector<Face> _faces; const std::vector<Vertex>& vertices() const; const std::vector<Face>& faces() const; I find that if I reference ...
- Sun Oct 29, 2023 5:19 pm
- Forum: General Bullet Physics Support and Feedback
- Topic: Using btIndexedMesh with btTriangleIndexVertexArray+btBvhTriangleMeshShape
- Replies: 3
- Views: 2076
Using btIndexedMesh with btTriangleIndexVertexArray+btBvhTriangleMeshShape
I am trying to create static physics bodies using btBvhTriangleMeshShape . This works fine if I copy vertex data into btTriangleMesh , and use that to create a btBvhTriangleMeshShape . However, copying is obviously not desirable. The approach I am currently trying is: Describe vertex layout using bt...
- Sun Jul 22, 2018 2:17 am
- Forum: General Bullet Physics Support and Feedback
- Topic: Squirrely dynamic bodies resting on flat static surface (video)
- Replies: 18
- Views: 9344
Re: Squirrely dynamic bodies resting on flat static surface (video)
GOT IT. rollingFriction needs to be 0. Apparently this parameter is there to allow things to not roll indefinitely.... (like pool balls): "the m_rollingFriction prevents rounded shapes, such as spheres, cylinders and capsules from rolling forever." I had (incorrectly) assumed it was kineti...
- Sat Jul 21, 2018 5:03 am
- Forum: General Bullet Physics Support and Feedback
- Topic: Squirrely dynamic bodies resting on flat static surface (video)
- Replies: 18
- Views: 9344
Re: Squirrely dynamic bodies resting on flat static surface (video)
I just tried the margin at 0 again but without luck. :\ I also did two other things: 1. Dropped a fresh source clone from the bullet repo into my extern/ directory and re-build the project (can't believe it built without CMake mods!). No change in behavior. 2. Instead of relying on a bunch of abstra...
- Sat Jul 21, 2018 2:45 am
- Forum: General Bullet Physics Support and Feedback
- Topic: Squirrely dynamic bodies resting on flat static surface (video)
- Replies: 18
- Views: 9344
Re: Squirrely dynamic bodies resting on flat static surface (video)
Thanks... plugged that in to replace my existing function:
mat4 GLMMat4FromBTTransform(const btTransform& from) {
mat4 glmMat;
from.getOpenGLMatrix(value_ptr(glmMat));
return glmMat;
}
Exacto-el-same-o.
mat4 GLMMat4FromBTTransform(const btTransform& from) {
mat4 glmMat;
from.getOpenGLMatrix(value_ptr(glmMat));
return glmMat;
}
Exacto-el-same-o.

- Sat Jul 21, 2018 2:15 am
- Forum: General Bullet Physics Support and Feedback
- Topic: Squirrely dynamic bodies resting on flat static surface (video)
- Replies: 18
- Views: 9344
Re: Squirrely dynamic bodies resting on flat static surface (video)
Thanks Chip. Probably a good idea.
I think I will try managing the physics simulation from the "client side" of my framework (as opposed to opaquely through a wrapper) first, then start from scratch. Weird stuff.
I think I will try managing the physics simulation from the "client side" of my framework (as opposed to opaquely through a wrapper) first, then start from scratch. Weird stuff.
- Sat Jul 21, 2018 2:13 am
- Forum: General Bullet Physics Support and Feedback
- Topic: Squirrely dynamic bodies resting on flat static surface (video)
- Replies: 18
- Views: 9344
Re: Squirrely dynamic bodies resting on flat static surface (video)
A little more info... Everything with configuring the world, creating shapes and rigid bodies, and configuring those objects all seems to be by the book... There are only two things that I am somewhat concerned about: 1. For resource management and scene graph synchronization purposes, I'm storing b...
- Fri Jul 20, 2018 8:56 pm
- Forum: General Bullet Physics Support and Feedback
- Topic: Squirrely dynamic bodies resting on flat static surface (video)
- Replies: 18
- Views: 9344
Re: Squirrely dynamic bodies resting on flat static surface (video)
Hi Mwni, Unfortunately timestep & number of substeps don't appear to be the issue. Since the simulation appears to run much more stably with very high masses (10,000x scale) I'm tempted to just move forward with that. I'm wondering what types unforeseen issues scaling the mass for all my objects...
- Fri Jul 20, 2018 2:38 am
- Forum: General Bullet Physics Support and Feedback
- Topic: Squirrely dynamic bodies resting on flat static surface (video)
- Replies: 18
- Views: 9344
Re: Squirrely dynamic bodies resting on flat static surface (video)
Chip, my code appears to do essentially all the same things as yours, except that I calculate localInertia like this: btVector3 localInertia = {0, 0, 0} collisionShape->calculateLocalInertia(mass, localInertia); Note sure if that's correct... If I try it with your random method of calculating localI...
- Fri Jul 20, 2018 12:37 am
- Forum: General Bullet Physics Support and Feedback
- Topic: Squirrely dynamic bodies resting on flat static surface (video)
- Replies: 18
- Views: 9344
Re: Squirrely dynamic bodies resting on flat static surface (video)
Another example using boxes. The spinning phenomenon is a lot less common, but boxes often don't lay flat on the ground. btBoxShape, mass=1


- Thu Jul 19, 2018 11:49 pm
- Forum: General Bullet Physics Support and Feedback
- Topic: Squirrely dynamic bodies resting on flat static surface (video)
- Replies: 18
- Views: 9344
Re: Squirrely dynamic bodies resting on flat static surface (video)
Hi Mwni, I played around with m_numIterations a bit. Setting to 0 results in no dynamic<->static interaction as expected, but anything larger seems to have no effect. m_numIterations = 0: http://goosesensor.net/bt_5.gif m_numIterations = 10: http://goosesensor.net/bt_6.gif m_numIterations = 100: htt...
- Thu Jul 19, 2018 3:47 am
- Forum: General Bullet Physics Support and Feedback
- Topic: Squirrely dynamic bodies resting on flat static surface (video)
- Replies: 18
- Views: 9344
Re: Squirrely dynamic bodies resting on flat static surface (video)
Thanks chip.
Generally activiationState gets set to ACTIVE_TAG when the rigid body is created in my code -- I disabled it to leave it as Bullet's default, then changed the friction and restitution settings as you recommended. Here is the result:

Generally activiationState gets set to ACTIVE_TAG when the rigid body is created in my code -- I disabled it to leave it as Bullet's default, then changed the friction and restitution settings as you recommended. Here is the result:

- Wed Jul 18, 2018 12:59 am
- Forum: General Bullet Physics Support and Feedback
- Topic: Squirrely dynamic bodies resting on flat static surface (video)
- Replies: 18
- Views: 9344
Squirrely dynamic bodies resting on flat static surface (video)
I'm having some issues with squirrely dynamic bodies attempting to rest on a flat static body. I have a static "ground plane," 40x40 units, that I've tried constructing a number of different ways: - btBoxShape of varying thickness - btConvexHullShape created from a plane geometry - btBvhTr...