NewtonConvexCollisionCalculateInertialMatrix

From Newton Wiki
Revision as of 08:02, 10 June 2019 by WikiSysop (talk | contribs) (1 revision imported)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

NewtonConvexCollisionCalculateInertialMatrix

void NewtonConvexCollisionCalculateInertialMatrix( const NewtonCollision* convexCollision, dFloat* inertia, dFloat* origin)

Usage

Calculate the three principal axis and the the values of the inertia matrix of a convex collision objects.

Parameters

  • const NewtonCollision convexCollision - is the pointer to a convex collision primitive.
  • dFloat *inertia - pointer to and array of a least 3 floats to hold the values of the principal inertia.
  • dFloat *origin - pointer to and array of a least 3 floats to hold the values of the center of mass for the principal inertia.

Remarks

  • This function calculate a general inertial matrix for arbitrary convex collision including compound collisions.
  • It should be noted that the generated inertia values should be multiplied by the object mass before calling NewtonBodySetMassMatrix

See also

NewtonBodySetMassMatrix NewtonBodyGetMassMatrix NewtonBodySetCentreOfMass NewtonBodyGetCentreOfMass