![]() |
• Physics Manager | ||||||
|
API Links
Developer Links
|
RigidBodyContact::GetWorldContactPositionDefined in:
Returns the world-space contact position and normal vector.
C4Contacts.hPrototype
Parameters
Description
The GetWorldContactPosition function returns the world-space position and normal vector corresponding to one of the two rigid bodies involved in a rigid body contact. The rigidBody parameter must be a pointer to one of the rigid bodies connected in the contact graph by the RigidBodyContact object for which this function is called. It would ordinarily be set to either a pointer to the object for which the RigidBodyController::HandleNewRigidBodyContact function has been called or the the contactBody parameter passed to the RigidBodyController::HandleNewRigidBodyContact function.The position parameter should specify a location to which the world-space contact position is written. This position represents the point on the surface of the other rigid body that is closest to the deepest penetration between the two rigid bodies.The normal parameter should specify a location to which the world-space contact normal vector is written. The normal vector always points outward with respect to the rigid body specified by the rigidBody parameter. (If the GetWorldContactPosition were to be called for both rigid bodies involved in the contact, the normal vectors returned would be negatives of each other.)
See Also
|