[ODE] How I can set Body having a trimesh?

Eugen Lofing lofing at gmx.net
Mon Apr 18 16:48:56 MST 2005


Hello!

How I can set Body having a trimesh?
I have a Mesh and don't want to use dMassSetBox.

If I use this:

dGeomSetPosition(geom,pos.X,pos.Y,pos.Z);
body = dBodyCreate(world);
dMassSetBox(&mass,1.0f,(dReal)extend.X,(dReal)extend.Y,(dReal)extend.Z);
dMassAdjust(&mass,0.25);
dBodySetMass(body,&mass);
dGeomSetBody(geom,body);
dBodySetPosition(body,pos.X,pos.Y,pos.Z);
dBodySetData(body,(void*)this);

.. so it doesn't work it shood.

Please Help me!! If u have some litle example (with code)
with a falling trimesh or so.. 


-- 
+++ GMX - Die erste Adresse für Mail, Message, More +++

1 GB Mailbox bereits in GMX FreeMail http://www.gmx.net/de/go/mail


More information about the ODE mailing list