Moderators: Sascha Willems, walaber



in_update:= true;
//NewtonUpdate(Newton_ext.NWorld, 0.1 / 6);
NewtonUpdateAsync(Newton_ext.NWorld, 0.1 / 6);
NewtonWaitForUpdateToFinish(Newton_ext.NWorld); // sync physics thread
in_update:= false;
JernejL wrote:It's impractical to use debug compiled newton because there are so many other asserts that are triggered that are still in the code that i'd need to remove first
(an example of assert that is unneccesary is dgAssert in NewtonMaterialSetContactNormalAcceleration function).
void NewtonMaterialSetContactNormalAcceleration(const NewtonMaterial* const materialHandle, dFloat accel)
{
TRACE_FUNCTION(__FUNCTION__);
dgContactMaterial* const material = (dgContactMaterial*) materialHandle;
dgAssert(0);
material->m_normal_Force.m_force = accel;
material->m_flags |= dgContactMaterial::m_overrideNormalAccel;
}
JernejL wrote:in my forcetorque and transform callbacks i check in_update value with assert, and if i use NewtonUpdateAsync + NewtonWaitForUpdateToFinish the assert is triggering, indicating that callbacks were triggered after NewtonWaitForUpdateToFinish.

in_update:= true;
//NewtonUpdate(Newton_ext.NWorld, 0.1 / 6);
NewtonUpdateAsync(Newton_ext.NWorld, 0.1 / 6);
NewtonWaitForUpdateToFinish(Newton_ext.NWorld); // sync physics thread
in_update:= false; 


// create the newton world
m_world = NewtonCreate();
// set the number of sub steps
NewtonSetNumberOfSubsteps (m_world, 2;
Users browsing this forum: Google Adsense [Bot] and 100 guests