btDbvtBroadphase not checking filter group/mask?

beauzo
Posts: 2
Joined: Wed Aug 29, 2007 6:44 pm

btDbvtBroadphase not checking filter group/mask?

Post by beauzo »

I must be missing something, but btDbvtBroadphase.cpp line 105 (ish) does not seem to be checking the result of addOverlappingPair() (which would return NULL if the pair should not be added)...

Code: Select all

pbp->m_paircache->addOverlappingPair(pa,pb);
++pbp->m_newpairs;
Should be?

Code: Select all

if (pbp->m_paircache->addOverlappingPair(pa,pb))
    ++pbp->m_newpairs;
Thanks,
-Beau
beauzo
Posts: 2
Joined: Wed Aug 29, 2007 6:44 pm

Re: btDbvtBroadphase not checking filter group/mask?

Post by beauzo »

The code change above doesn't seem to fix my problem. Pardon the gun jumping... Anyway, the filter group/mask behavior between AxisSweep and Dvbt does not seem to be the same for me.

BTW: I'm using Bullet collision only.

Thanks,
-Beau
User avatar
Erwin Coumans
Site Admin
Posts: 4221
Joined: Sun Jun 26, 2005 6:43 pm
Location: California, USA

Re: btDbvtBroadphase not checking filter group/mask?

Post by Erwin Coumans »

The collision filtering based on group/mask happens in the pair cache, and by default all broadphases share the same btHashedOverlappingPairCache.

What is the problem exactly? Do you experience a crash?
Can you share a reproduction case?

Thanks,
Erwin