Skip to content

Body Collision Viewer

When performing a complex operation in a constraint environment, one can collide with surrounding equipment or tool. In this tutorial, we show how collision between the tracked manikin and the virtual scene can be retrieved. You will then be able to know which body parts collide with your environment during a simulation.

Prerequisites : Your INTERACT simulation needs a Full Body Tracking player

Collision monitoring

  1. Add an empty object Collisions in the hierarchy and add the following components:
    • XdeSkeletonCollisionMonitor
    • XdeColliderViewer
  2. In the XdeSkeletonCollisionMonitor:
    • In Skeleton , drop the FullBody localized in [Player_1] > Devices > HumanManager > FullBody.
    • In Right Hand, drop the RightHand localized in [Player_1] > Devices > HumanManager > FullBody > RightHand
    • In Left Hand, drop the LeftHand localized in [Player_1] > Devices > HumanManager > FullBody > LeftHand
    • Click on Create Contact Monitor. This will had a XdeContactsMonitor component to every part of the player's body.
  3. In the XdeColliderViewer:

    • In Monitor, drop the XdeSkeletonCollisionMonitor.

    Enable contact in collision matrix

    Make sure you have set the collision between your objects and player group in INTERACT > Physics > Show Collision Matrix.

Display collisions

  1. We need an interface to visualize colliding body parts in real-time during the simulation.
    You can change the name of ErgoCotationPanel to "Canvas" since we will use it to visualize the collision as well.

  2. Add a second model:

    • Copy/Paste the XdePostureCotationPopup to make it easier and faster. Then rename it as CollisionManagement.
    • Delete the XdePostureCotationPopup component on it and add XdeSkeletonCollisionPopup instead.
  3. Now, let's re-organize our panel:

    • Move the transform of the game object CollisionManagement to the left so that both panel are side by side.

    • Keep Title and Cotation and drop the all of the other children which will not be useful here.
    • Add an empty object as a child of CollisionManagement
    • Rename this object Collision and set Title and Cotation as children of it.

You can now run your simulation. Body parts are highlighted in red in the panel when a collision occurs.