'back-porting' btGeneric6DofSpring2Constraint to bulletv2.80

kevino
Posts: 2
Joined: Thu Jan 08, 2015 5:19 pm

'back-porting' btGeneric6DofSpring2Constraint to bulletv2.80

Post by kevino »

Hi,

I'm currently restricted to using Bullet v2.80 but I'd like to try out the btGeneric6DofSpring2Constraint constraint
from v3 code base if possible. I've tried (naively) cutting and pasting into the old code base and (with a few other minor alterations) it compiles but seg faults when called in my code. Specifically, the btConstraintInfo2 being passed around it's methods has null pointer, info->m_J2linearAxis=0.
Any ideas anyone or is this a fool's errand?

Best regards,

Kevin
kevino
Posts: 2
Joined: Thu Jan 08, 2015 5:19 pm

Re: 'back-porting' btGeneric6DofSpring2Constraint to bulletv

Post by kevino »

I've found the issue - in v2.80 btSolverConstraint::m_contactNormal2 isn't explicitly defined

//btVector3 m_contactNormal2;//usually m_contactNormal2 == -m_contactNormal

whereas it is in later versions