Problem with initialization ODE

24 views
Skip to first unread message

Artur Kaperek

unread,
May 9, 2013, 5:27:17 PM5/9/13
to ode-...@googlegroups.com
I use double release DLL version of ODE. I try create simple sphere. But when i use dBodySetMass program return box with error "assertion dMassCheck failed".What i do wrong?
Full code of physic function and physic globals :

static dWorldID world;
static dSpaceID space;
static dBodyID body;
static dGeomID geom;
static dMass m;
static dJointGroupID contactgroup;
...
void initPhysic()
{
    dInitODE ();
    world = dWorldCreate ();
    space = dHashSpaceCreate (0);
    dWorldSetGravity (world,0,0,-0.2);
    dWorldSetCFM (world,1e-5);
    dCreatePlane (space,0,0,1,0);
    body = dBodyCreate (world);
    geom = dCreateSphere (space,0.5);
    dMassSetSphere (&m,1,0.5);
    dBodySetMass (body,&m);
}

Joseph Cooper

unread,
May 10, 2013, 12:25:44 AM5/10/13
to ode-...@googlegroups.com
I compiled your code in release-double-dll and it executes without any problem.  I'd suggest rebuilding the library and ensuring that the headers you include match the .dll you load.  You'll probably also want to actually connect the geom to the body:dGeomSetBody(geom,body);, but that's unrelated to your assertion.

jc


--
You received this message because you are subscribed to the Google Groups "ode-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to ode-users+...@googlegroups.com.
To post to this group, send email to ode-...@googlegroups.com.
Visit this group at http://groups.google.com/group/ode-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

Reply all
Reply to author
Forward
0 new messages