Is there SAT algorithm in Bullet Physics Engine

Post Reply
daye
Posts: 8
Joined: Mon Sep 04, 2017 2:59 am

Is there SAT algorithm in Bullet Physics Engine

Post by daye »

Hi everyone,

I want to change the Collision Detection algorithm to SAT algorithm. I only found GJK algorithm in Bullet. Is there SAT algorithm in Bullet Physics Engine which I can call it directly? Or I have to achieve that by myself?

Thank you in advance!
Daye
steven
Posts: 83
Joined: Mon Nov 05, 2018 8:16 am
Location: China

Re: Is there SAT algorithm in Bullet Physics Engine

Post by steven »

i think you should implement it yourself, but you can refer to the GPU part computeConvexConvexContactsGPUSAT()
User avatar
Erwin Coumans
Site Admin
Posts: 4221
Joined: Sun Jun 26, 2005 6:43 pm
Location: California, USA
Contact:

Re: Is there SAT algorithm in Bullet Physics Engine

Post by Erwin Coumans »

Yes, Bullet provides a SAT implementation.

You need to call the convexHull->initializePolyhedralFeatures(), this will create edges/trangles for a point cloud.
convex hull generation is

then enable SAT using getDispatchInfo().m_enableSatConvex=true;

Implementation is in src\BulletCollision\CollisionDispatch\btConvexConvexAlgorithm.cpp
and its contact clipping here:
src\BulletCollision\NarrowPhaseCollision\btPolyhedralContactClipping.cpp
Post Reply