2
0

b3ContactConstraint4.h 749 B

12345678910111213141516171819202122232425262728293031
  1. #ifndef B3_CONTACT_CONSTRAINT5_H
  2. #define B3_CONTACT_CONSTRAINT5_H
  3. #include "Bullet3Common/shared/b3Float4.h"
  4. typedef struct b3ContactConstraint4 b3ContactConstraint4_t;
  5. struct b3ContactConstraint4
  6. {
  7. b3Float4 m_linear; //normal?
  8. b3Float4 m_worldPos[4];
  9. b3Float4 m_center; // friction
  10. float m_jacCoeffInv[4];
  11. float m_b[4];
  12. float m_appliedRambdaDt[4];
  13. float m_fJacCoeffInv[2]; // friction
  14. float m_fAppliedRambdaDt[2]; // friction
  15. unsigned int m_bodyA;
  16. unsigned int m_bodyB;
  17. int m_batchIdx;
  18. unsigned int m_paddings;
  19. };
  20. //inline void setFrictionCoeff(float value) { m_linear[3] = value; }
  21. inline float b3GetFrictionCoeff(b3ContactConstraint4_t* constraint)
  22. {
  23. return constraint->m_linear.w;
  24. }
  25. #endif //B3_CONTACT_CONSTRAINT5_H