[ODE] A beginner question about applying forces on a body

Cristian Bianchi cristian at sssup.it
Fri Apr 30 15:43:21 MST 2004


You can use the friction model (see the ode doc for details on how to write
a collision callback and set up collision params) or use other force
functions:

void dBodyAddForceAtPos       (dBodyID, dReal fx, dReal fy, dReal fz,
                                        dReal px, dReal py, dReal pz);
void dBodyAddForceAtRelPos    (dBodyID, dReal fx, dReal fy, dReal fz,
                                        dReal px, dReal py, dReal pz);
void dBodyAddRelForceAtPos    (dBodyID, dReal fx, dReal fy, dReal fz,
                                        dReal px, dReal py, dReal pz);
void dBodyAddRelForceAtRelPos (dBodyID, dReal fx, dReal fy, dReal fz,
                                        dReal px, dReal py, dReal pz);

with these functions you can apply force and torque not only on the center
of mass, but also in absolute coordinate positions or body coordinate
positions...
bye
Cris


----- Original Message ----- 
From: "martin maximilien" <martin.maximilien at free.fr>
To: <ode at q12.org>
Sent: Friday, April 30, 2004 3:03 PM
Subject: [ODE] A beginner question about applying forces on a body


> Hi,
> I want to apply a set of forces,  on a sphere, with friction at the
> contact points of each force.
> My sphere has a translation and rotation parameters, and is rotating on
> a plane, with another friction coefficient.
> How can i modelize all that ?
> Apparently, dBodySetForce is operating on the mass center, or am i wrong ?
> Tx for your help.
>
> _______________________________________________
> ODE mailing list
> ODE at q12.org
> http://q12.org/mailman/listinfo/ode
>



More information about the ODE mailing list