MCPcopy Create free account
hub / github.com/DanielChappuis/reactphysics3d / update

Method update

src/constraint/ContactPoint.cpp:67–78  ·  view source on GitHub ↗

Update the contact point with a new one that is similar (very close) The idea is to keep the cache impulse (for warm starting the contact solver)

Source from the content-addressed store, hash-verified

65// Update the contact point with a new one that is similar (very close)
66/// The idea is to keep the cache impulse (for warm starting the contact solver)
67void ContactPoint::update(const ContactPointInfo* contactInfo) {
68
69 assert(isSimilarWithContactPoint(contactInfo));
70 assert(contactInfo->penetrationDepth > decimal(0.0));
71
72 mNormal = contactInfo->normal;
73 mPenetrationDepth = contactInfo->penetrationDepth;
74 mLocalPointOnShape1 = contactInfo->localPoint1;
75 mLocalPointOnShape2 = contactInfo->localPoint2;
76
77 mIsObsolete = false;
78}

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected