You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The current API for the broad phase pair filter cannot access any information about the bodies that are colliding. The filter has access to the handles via the BroadPhasePairFilter trait but there is not way to retrieve the body information from the set due to the fact that MechanicalWorld::step, which calls the filter, requires mutable access to the body set. Utilizing the user data on the collider is sufficient for cases where the information does not change during each step (e.g., parent information) but cannot be used for information about a body that may have been updated.
The text was updated successfully, but these errors were encountered:
I investigated having nphysics define its own BroadPhasePairFilter trait but almost 100% of the collision logic happens in ncollide (unsurprisingly). So it looks like this will have to be a change within ncollide.
I suspect the best approach would be to modify the BroadPhasePairFilter to the following:
where Set becomes the BodySet in nphysics. This will require a change at every step between nphysics and ncollide's src/pipeline/glue/update.rs, so it's a fairly sizable change. I'll wait to start working on this until I get input.
The current API for the broad phase pair filter cannot access any information about the bodies that are colliding. The filter has access to the handles via the
BroadPhasePairFilter
trait but there is not way to retrieve the body information from the set due to the fact thatMechanicalWorld::step
, which calls the filter, requires mutable access to the body set. Utilizing the user data on the collider is sufficient for cases where the information does not change during each step (e.g., parent information) but cannot be used for information about a body that may have been updated.The text was updated successfully, but these errors were encountered: