[ODE] [test_trimesh.cpp and dGeomTriMeshDataBuildSingle] Vertex Stride value

dpedreno at iionks.com dpedreno at iionks.com
Sun Aug 1 16:45:07 MST 2004


Hello,

In the examples, I want to modify the test_trimesh.cpp file, and I want to use 
the strided version of dGeomTriMeshDataBuildSingle.

To get it work, I have to replace the line:

dGeomTriMeshDataBuildSimple (Data, (dReal*)Vertices, VertexCount, Indices, 
IndexCount);

by:

dGeomTriMeshDataBuildSingle (Data, (dReal*)Vertices, sizeof(dReal)*4, 
VertexCount, &Indices[0], IndexCount, 3*sizeof(int));

Please notice that the vertex stride is equal to sizeof(dReal)*4.
Could someone give me a light on this please?


Didier


More information about the ODE mailing list