Munk2D Documentation  8.x.x
Loading...
Searching...
No Matches
cpContactPointSet Struct Reference

A struct that wraps up the important collision data for an arbiter. More...

#include <cpArbiter.h>

Data Fields

int count
 The number of contact points in the set.
 
cpVect normal
 The normal of the collision.
 
struct { 
 
   cpVect   pointA 
 The position of the contact on the surface of each shape.
 
   cpFloat   distance 
 Penetration distance of the two shapes. More...
 
points [2] 
 The array of contact points.
 

Detailed Description

A struct that wraps up the important collision data for an arbiter.

Field Documentation

◆ distance

cpFloat cpContactPointSet::distance

Penetration distance of the two shapes.

Overlapping means it will be negative. This value is calculated as cpvdot(cpvsub(point2, point1), normal) and is ignored by cpArbiterSetContactPointSet().


The documentation for this struct was generated from the following file: