A Contact contains information about two bodies that are in contact with each other. More...
#include <Contact.h>
Public Member Functions | |
Contact (int body1, int body2) | |
Create a Contact object. | |
Contact (const Contact ©) | |
Contact (ContactImpl *impl) | |
~Contact () | |
Contact & | operator= (const Contact ©) |
int | getFirstBody () const |
Get the first body involved in the contact, specified by its index within its contact set. | |
int | getSecondBody () const |
Get the second body involved in the contact, specified by its index within its contact set. | |
const ContactImpl & | getImpl () const |
A Contact contains information about two bodies that are in contact with each other.
It usually is created by a CollisionDetectionAlgorithm, and is retrieved by calling getContacts() on a GeneralContactSubsystem.
The base class records only the indices of the two bodies that are in contact. CollisionDetectionAlgorithms which characterize contacts in more complex ways will typically define subclasses of Contact that provide additional information.
Contact | ( | int | body1, | |
int | body2 | |||
) |
Create a Contact object.
body1 | the index of the first body involved in the contact, specified by its index within its contact set | |
body2 | the index of the second body involved in the contact, specified by its index within its contact set |
Contact | ( | ContactImpl * | impl | ) |
~Contact | ( | ) |
int getFirstBody | ( | ) | const |
Get the first body involved in the contact, specified by its index within its contact set.
const ContactImpl& getImpl | ( | ) | const [inline] |
int getSecondBody | ( | ) | const |
Get the second body involved in the contact, specified by its index within its contact set.