Newton 2 - NewtonHingeGetJointOmega always returns zero

Report any bugs here and we'll post fixes

Moderators: Sascha Willems, Thomas

Newton 2 - NewtonHingeGetJointOmega always returns zero

Postby Aphex » Thu Aug 28, 2008 5:26 pm

Seems like this function now always returns zero with Newton 2. Are these legacy joints unsupported now?
Aphex
 
Posts: 144
Joined: Fri Jun 18, 2004 6:08 am
Location: UK

Re: Newton 2 - NewtonHingeGetJointOmega always returns zero

Postby Julio Jerez » Thu Aug 28, 2008 6:38 pm

I will check
Julio Jerez
Moderator
Moderator
 
Posts: 12249
Joined: Sun Sep 14, 2003 2:18 pm
Location: Los Angeles

Re: Newton 2 - NewtonHingeGetJointOmega always returns zero

Postby Aphex » Mon Sep 01, 2008 4:27 pm

Hey,

Any ideas on this? I've put in a workaround using the two joint body omega's but it would be nicer to use the joint function...

ta,
Aph
Aphex
 
Posts: 144
Joined: Fri Jun 18, 2004 6:08 am
Location: UK

Re: Newton 2 - NewtonHingeGetJointOmega always returns zero

Postby Julio Jerez » Mon Sep 01, 2008 6:15 pm

have not look at yet, I will see what it is.
Julio Jerez
Moderator
Moderator
 
Posts: 12249
Joined: Sun Sep 14, 2003 2:18 pm
Location: Los Angeles

Re: Newton 2 - NewtonHingeGetJointOmega always returns zero

Postby Julio Jerez » Thu Sep 04, 2008 10:38 am

you are right I made a mistake in 2.0

here is teh funtion

*
Code: Select all
dgFloat32 dgHingeConstraint::GetJointOmega () const
{
   _ASSERTE (m_body0);
   _ASSERTE (m_body1);
   dgVector dir (m_body0->GetMatrix().RotateVector (m_localMatrix0[0]));
   const dgVector& omega0 = m_body0->GetOmega();
   const dgVector& omega1 = m_body0->GetOmega();

//   if (m_body1) {
//      omega1 = m_body1->GetOmega();
//   }
   return (omega0 - omega1) % dir;

}


the bug is that I had teh m_bodi commenetd out,
I fix it and now it is liek this


Code: Select all
dgFloat32 dgHingeConstraint::GetJointOmega () const
{
   _ASSERTE (m_body0);
   _ASSERTE (m_body1);
   dgVector dir (m_body0->GetMatrix().RotateVector (m_localMatrix0[0]));
   const dgVector& omega0 = m_body0->GetOmega();
   const dgVector& omega1 = m_body1->GetOmega();
}


you will get it with nex update in a day or tow
It is taking me longere because I had to do soem nessary work on teh SDK to nake simpler to make demos.

Thank for the bug report.
:D
Julio Jerez
Moderator
Moderator
 
Posts: 12249
Joined: Sun Sep 14, 2003 2:18 pm
Location: Los Angeles

Re: Newton 2 - NewtonHingeGetJointOmega always returns zero

Postby Aphex » Fri Sep 05, 2008 8:54 am

Sorted :) Cheers man!
Aphex
 
Posts: 144
Joined: Fri Jun 18, 2004 6:08 am
Location: UK


Return to Bugs and Fixes

Who is online

Users browsing this forum: No registered users and 4 guests

cron