c++game-physicsnvidiaphysics-enginephysx

PhysX Collision Filter with Dynamic & Static Rigidbodies


I'm developing a videogame engine and I'm implementing PhysX 3.4, specifically I'm currently working on Colliders Filtering and I've been testing the FilterShader() function (from this and this Nvidia documentation) with some colliders and rigidbodies. So, if both colliders have a dynamic rigidbody the, function gives me the pxFilterData of both, but if one of them is static it gives me only 1 pxFilterData and in the next iteration the other one.

Is it possible to receive both of them as it does when both are dynamic?


Solution

  • This was solved by creating first the shape and then calling setSimulationFilterData(), before creating the rigidbody