Tutorial for collision detection with mesh geometries

Discussion in 'Visualization' started by fcarrillo, Apr 6, 2020.

  1. Hi all

    Would anyone know of a comprehensive tutorial to use the collision detection functionality with custom meshes?

    I have been working with the meshes of a human leg (bones) and I want to measure the forces generated at the knee when applying a force at the hip, for example.

    However, I have been only working on the XML model and I would love to switch to python of c++ but I don't see to find any comprehensive tutorial of ho to do that

    Also, I have been having problems with the definition of the contact areas and the meshes in the space. It is really difficult to rely always in the position of the mesh itself.

    Can anyone give me some pointers or examples of a model where an external force is applied and measure on custom defined meshes in Mujoco?

  2. EDIT: Misread the question, sorry. This answer is hardly relevant.

    You first need to create a mesh asset of your STL (http://www.mujoco.org/book/XMLreference.html#mesh).
    Then you can create a geom with 'type' set to "mesh" (http://www.mujoco.org/book/XMLreference.html#geom) and then you specify a mesh asset by name:


    <bodypos="0 0 0.35"/>
    <jointtype="hinge"axis="1 0 0"/>

    Let us know what problems you run into.