odespace.h   odespace.h 
skipping to change at line 227 skipping to change at line 227
_jointset[dJointTypeSlider] = dJointSetSliderParam; _jointset[dJointTypeSlider] = dJointSetSliderParam;
_jointset[dJointTypeUniversal] = dJointSetUniversalParam; _jointset[dJointTypeUniversal] = dJointSetUniversalParam;
_jointset[dJointTypeHinge2] = dJointSetHinge2Param; _jointset[dJointTypeHinge2] = dJointSetHinge2Param;
} }
virtual ~ODESpace() { virtual ~ODESpace() {
} }
bool InitEnvironment() bool InitEnvironment()
{ {
#ifdef ODE_HAVE_ALLOCATE_DATA_THREAD
dAllocateODEDataForThread(dAllocateMaskAll);
#endif
RAVELOG_VERBOSE("init ode collision environment\n"); RAVELOG_VERBOSE("init ode collision environment\n");
_ode.reset(new ODEResources()); _ode.reset(new ODEResources());
return true; return true;
} }
void DestroyEnvironment() void DestroyEnvironment()
{ {
RAVELOG_VERBOSE("destroying ode collision environment\n"); RAVELOG_VERBOSE("destroying ode collision environment\n");
_ode.reset(); _ode.reset();
} }
bool IsInitialized() { bool IsInitialized() {
return !!_ode; return !!_ode;
} }
KinBodyInfoPtr InitKinBody(KinBodyPtr pbody, KinBodyInfoPtr pinfo = Kin BodyInfoPtr()) KinBodyInfoPtr InitKinBody(KinBodyPtr pbody, KinBodyInfoPtr pinfo = Kin BodyInfoPtr())
{ {
EnvironmentMutex::scoped_lock lock(pbody->GetEnv()->GetMutex()); EnvironmentMutex::scoped_lock lock(pbody->GetEnv()->GetMutex());
#ifdef ODE_HAVE_ALLOCATE_DATA_THREAD
dAllocateODEDataForThread(dAllocateMaskAll);
#endif
// create all ode bodies and joints // create all ode bodies and joints
if( !pinfo ) { if( !pinfo ) {
pinfo.reset(new KinBodyInfo(_ode)); pinfo.reset(new KinBodyInfo(_ode));
} }
pinfo->Reset(); pinfo->Reset();
pinfo->pbody = pbody; pinfo->pbody = pbody;
pinfo->_odespace = weak_space(); pinfo->_odespace = weak_space();
pinfo->vlinks.reserve(pbody->GetLinks().size()); pinfo->vlinks.reserve(pbody->GetLinks().size());
pinfo->vjoints.reserve(pbody->GetJoints().size()+pbody->GetPassiveJ oints().size()); pinfo->vjoints.reserve(pbody->GetJoints().size()+pbody->GetPassiveJ oints().size());
 End of changes. 2 change blocks. 
0 lines changed or deleted 7 lines changed or added

This html diff was produced by rfcdiff 1.41. The latest version is available from http://tools.ietf.org/tools/rfcdiff/