[ODE] Instanced Trimesh (SVN #1076)

David Walters hidden.asbestos at googlemail.com
Wed Sep 13 09:31:39 MST 2006

I've just made a checkin in response to feature request 1526353,
submitted by Michael Molkenthin back in July.

The trimesh data used to hold its last transform for use in collision
in approximating triangle velocities and generally enhancing
collision. The storage of this in the shape data (dTriMeshData)
prevented using multiple instances of moving trimeshes. To fix this
the last transform is now stored in the dxTriMesh geom struct, i.e. on
a per geom instance basis.

To convert code from the old way to the new you need to make the
following change:

dGeomTriMeshDataSet( dTriMeshDataID, TRIMESH_LAST_TRANSFORMATION, dMatrix4 )


dGeomTriMeshSetLastTransform( dGeomID, dMatrix4 )




dGeomTriMeshGetLastTransform( dGeomID )

If anyone finds any problems with this then please let me know. Some
of the casts might make GCC complain, I don't know - I've tested with
VS2005 and test_moving_trimesh works fine.


More information about the ODE mailing list