Search found 690 matches

by drleviathan
Fri Apr 09, 2021 3:28 pm
Forum: General Bullet Physics Support and Feedback
Topic: Improving performances of transported objects [SOLVED]
Replies: 8
Views: 486

Re: Improving performances of transported objects

Maybe use btGhostObject for your sensors instead of just btCollisionObject. If you need your sensors have a fancy shape instead of just a box then there is extra work involved.
by drleviathan
Fri Apr 09, 2021 3:34 am
Forum: General Bullet Physics Support and Feedback
Topic: Improving performances of transported objects [SOLVED]
Replies: 8
Views: 486

Re: Improving performances of transported objects

To ensure sensor detection: make sure your kinematic objects are kept "active". This should always be true when using MotionStates to move them around because the MotionState.getWorldTransform() is only called on active kinematic objects. I believe kinematic-vs-static objects do not "...
by drleviathan
Fri Apr 02, 2021 3:35 pm
Forum: General Bullet Physics Support and Feedback
Topic: Improving performances of transported objects [SOLVED]
Replies: 8
Views: 486

Re: Improving performances of transported objects

It occurs to me: I don't know if the CProfileManager stuff works in the multi-thread paradigm. So if you tried it... dunno if it would actually work. I've never played with the multi-threaded Bullet however I would expect single-threaded Bullet to be able to push several hundred dynamic objects, eve...
by drleviathan
Thu Apr 01, 2021 10:40 pm
Forum: General Bullet Physics Support and Feedback
Topic: Improving performances of transported objects [SOLVED]
Replies: 8
Views: 486

Re: Improving performances of transported objects

If you want to first measure where the time is being spent inside the Bullet step before taking optimization measures you could use the CProfileManager utility in Bullet to get a nice printout of time spent in each context. Rather than outline its usage here I suggest you research previous threads a...
by drleviathan
Wed Mar 31, 2021 2:43 pm
Forum: General Bullet Physics Support and Feedback
Topic: Use of api(CreateFromTriMesh)
Replies: 3
Views: 332

Re: Use of api(CreateFromTriMesh)

I looked at the code for btSoftBody . AFAICT the m_collisionDisabledObjects vector date member of that class is used when linking soft bodies together with "anchors". If you're not doing that then you would expect that vector container to be empty. The m_bodySolver is set internally, impli...
by drleviathan
Wed Mar 24, 2021 2:46 pm
Forum: General Bullet Physics Support and Feedback
Topic: Use of api(CreateFromTriMesh)
Replies: 3
Views: 332

Re: Use of api(CreateFromTriMesh)

You should examine the implementation of btSoftBodyHelpers::CreateFromTriMesh() inside the CPP file to see how they are used. But I would guess: const btScalar* vertices is a pointer to a buffer of btScalar representing the float or double (depending on if btScaler is a float or double) values the v...
by drleviathan
Mon Mar 22, 2021 3:39 pm
Forum: General Bullet Physics Support and Feedback
Topic: "multiple mesh parts" with btBvhTriangleMeshShape?
Replies: 4
Views: 432

Re: "multiple mesh parts" with btBvhTriangleMeshShape?

Ah I see... looking closer at the code I rediscover: the btBvhTriangleMeshShape uses an instance of something that implements the btStridingMeshInterface and that interface supports having the mesh split into sub-parts. Yes, I recall taking advantage of that multiple parts API. At one time we were l...
by drleviathan
Fri Mar 19, 2021 10:23 pm
Forum: General Bullet Physics Support and Feedback
Topic: "multiple mesh parts" with btBvhTriangleMeshShape?
Replies: 4
Views: 432

Re: "multiple mesh parts" with btBvhTriangleMeshShape?

My interpretation of the manual (although I wasn't able to find a copy with the section you describe) is: if you have multiple distinct mesh "parts"... then you could store them in single btBvhTriangleMeshShape instance in one RigidBody... and the collision behavior would be identical to w...
by drleviathan
Tue Mar 16, 2021 4:23 pm
Forum: General Bullet Physics Support and Feedback
Topic: Object falling when turning
Replies: 1
Views: 380

Re: Object falling when turning

The ball easily falls out of the pipe because when the pipe is "teleported" to a new transform the two objects interpenetrate and the "interpenetration logic" is happy to push the ball to the outside. It doesn't know inside from outside: it just tries to resolve the overlap. You ...
by drleviathan
Tue Mar 09, 2021 10:58 pm
Forum: General Bullet Physics Support and Feedback
Topic: Hinge vehicle balance
Replies: 3
Views: 403

Re: Hinge vehicle balance

Car race-em games often require very tuned "game physics" (as opposed to "accurate physics") in order to make them fun. The example for this I usually give is: crashes. Accurate car crashes happen quite fast: you're in control when suddenly the vehicle is tumbling faster than you...
by drleviathan
Wed Mar 03, 2021 4:17 pm
Forum: General Bullet Physics Support and Feedback
Topic: [HELP] Explosiveness and stretching of physical object connections
Replies: 3
Views: 429

Re: [HELP] Explosiveness and stretching of physical object connections

Because of bug, sword when attached to hand was always falling, increasing it's velocity higher and higher so everything it touches would fly away. Sword was separate object that was moving as their own as attachment to hand bone, so it wasn't physical movement. Ah I see: you were slamming the swor...
by drleviathan
Wed Mar 03, 2021 3:02 pm
Forum: General Bullet Physics Support and Feedback
Topic: [HELP] Explosiveness and stretching of physical object connections
Replies: 3
Views: 429

Re: [HELP] Explosiveness and stretching of physical object connections

I watched the video. I believe what is happening is: the objects get into a state of interpenetration and the penetration resolution logic separates them but does so in a non-physical way. The penetration resolution logic is pretty good at getting the objects out of overlap while not pumping too muc...
by drleviathan
Tue Feb 23, 2021 11:12 pm
Forum: General Bullet Physics Support and Feedback
Topic: rotation format in bullet physics
Replies: 5
Views: 539

Re: rotation format in bullet physics

is there a way to efficiently integrate the rotation with this vector? Do you mean: "Given some initial rotation Q0 and a non-zero angular velocity W ... is it possible to compute the rotation Q(t) as time progresses forward?" If so then: yes. In fact, that is what Bullet does: RigidBody ...
by drleviathan
Tue Feb 23, 2021 7:03 pm
Forum: General Bullet Physics Support and Feedback
Topic: rotation format in bullet physics
Replies: 5
Views: 539

Re: rotation format in bullet physics

AngularVelocity is indeed a btVector3, however its units are radians/second. It represents the rate of change of the rotation... not the rotation. Perhaps you had a question about AngularVelocity?
by drleviathan
Tue Feb 23, 2021 4:53 pm
Forum: General Bullet Physics Support and Feedback
Topic: rotation format in bullet physics
Replies: 5
Views: 539

Re: rotation format in bullet physics

Bullet stores both position and rotation in a btTransform which is a 4x4 matrix under the hood. You can extract just the rotation part into a normalized btQuaternion which is a 4D "vector". The components of a Quaternion are NOT the normalized_axis + angle, however with some practice you c...