SO3Engine
|
#include <SO3MaterialPair.h>
Public Member Functions | |
SMaterialPair (SScene *scene, SMaterialID *mat1, SMaterialID *mat2) | |
~SMaterialPair () | |
int | getID1 () |
int | getID2 () |
bool | GetContactCallbackActivated () |
void | SetContactCallbackActivated (const bool &state) |
bool | GetOverlapStartedCallbackActivated () |
void | SetOverlapStartedCallbackActivated (const bool &state) |
bool | GetOverlapEndedCallbackActivated () |
void | SetOverlapEndedCallbackActivated (const bool &state) |
void | SetDefaultSurfaceThickness (const Ogre::Real &value) |
void | SetDefaultElasticity (const Ogre::Real &value) |
void | SetDefaultFriction (const Ogre::Real &stat, const Ogre::Real &kin) |
void | SetDefaultSoftness (const Ogre::Real &value) |
void | SetDefaultCollidable (const bool &enable) |
SScene * | GetParentScene () |
virtual int | onAABBOverlap (OgreNewt::Body *body0, OgreNewt::Body *body1, int threadIndex) |
user-defined AABB-overlap function | |
virtual void | contactsProcess (OgreNewt::ContactJoint &contactJoint, Ogre::Real timeStep, int threadIndex) |
user-defined Process function | |
Protected Attributes | |
OgreNewt::MaterialPair * | O3MaterialPair |
SMaterialID * | mMat1 |
SMaterialID * | mMat2 |
SScene * | mScene |
Detailed Description
Definition at line 42 of file SO3MaterialPair.h.
Constructor & Destructor Documentation
◆ SMaterialPair()
SO3::SMaterialPair::SMaterialPair | ( | SScene * | scene, |
SMaterialID * | mat1, | ||
SMaterialID * | mat2 | ||
) |
Definition at line 18 of file SO3MaterialPair.cpp.
◆ ~SMaterialPair()
SO3::SMaterialPair::~SMaterialPair | ( | ) |
Definition at line 38 of file SO3MaterialPair.cpp.
Member Function Documentation
◆ contactsProcess()
|
virtual |
user-defined Process function
user process function. it is called for each colliding pair of bodies. you can use the ContactJoint to iterate through all contact-points and change the "material" of each contact-point!
Reimplemented from OgreNewt::ContactCallback.
Definition at line 166 of file SO3MaterialPair.cpp.
◆ GetContactCallbackActivated()
bool SO3::SMaterialPair::GetContactCallbackActivated | ( | ) |
Definition at line 53 of file SO3MaterialPair.cpp.
◆ getID1()
int SO3::SMaterialPair::getID1 | ( | ) |
Definition at line 43 of file SO3MaterialPair.cpp.
◆ getID2()
int SO3::SMaterialPair::getID2 | ( | ) |
Definition at line 48 of file SO3MaterialPair.cpp.
◆ GetOverlapEndedCallbackActivated()
bool SO3::SMaterialPair::GetOverlapEndedCallbackActivated | ( | ) |
Definition at line 73 of file SO3MaterialPair.cpp.
◆ GetOverlapStartedCallbackActivated()
bool SO3::SMaterialPair::GetOverlapStartedCallbackActivated | ( | ) |
Definition at line 63 of file SO3MaterialPair.cpp.
◆ GetParentScene()
SScene * SO3::SMaterialPair::GetParentScene | ( | ) |
Definition at line 109 of file SO3MaterialPair.cpp.
◆ onAABBOverlap()
|
virtual |
user-defined AABB-overlap function
this function is called when 2 bodies AABB overlap. they have not yet collided, but may do so this loop. at this point, m_body0 and m_body1 are defined, but the contact isn't yet valid, so none of the member functions can be called yet. they must be called from the contacsProcess() function. return 0 to ignore the collision, 1 to allow it.
Reimplemented from OgreNewt::ContactCallback.
Definition at line 114 of file SO3MaterialPair.cpp.
◆ SetContactCallbackActivated()
void SO3::SMaterialPair::SetContactCallbackActivated | ( | const bool & | state | ) |
Definition at line 58 of file SO3MaterialPair.cpp.
◆ SetDefaultCollidable()
void SO3::SMaterialPair::SetDefaultCollidable | ( | const bool & | enable | ) |
Definition at line 104 of file SO3MaterialPair.cpp.
◆ SetDefaultElasticity()
void SO3::SMaterialPair::SetDefaultElasticity | ( | const Ogre::Real & | value | ) |
Definition at line 88 of file SO3MaterialPair.cpp.
◆ SetDefaultFriction()
void SO3::SMaterialPair::SetDefaultFriction | ( | const Ogre::Real & | stat, |
const Ogre::Real & | kin | ||
) |
Definition at line 93 of file SO3MaterialPair.cpp.
◆ SetDefaultSoftness()
void SO3::SMaterialPair::SetDefaultSoftness | ( | const Ogre::Real & | value | ) |
Definition at line 99 of file SO3MaterialPair.cpp.
◆ SetDefaultSurfaceThickness()
void SO3::SMaterialPair::SetDefaultSurfaceThickness | ( | const Ogre::Real & | value | ) |
Definition at line 83 of file SO3MaterialPair.cpp.
◆ SetOverlapEndedCallbackActivated()
void SO3::SMaterialPair::SetOverlapEndedCallbackActivated | ( | const bool & | state | ) |
Definition at line 78 of file SO3MaterialPair.cpp.
◆ SetOverlapStartedCallbackActivated()
void SO3::SMaterialPair::SetOverlapStartedCallbackActivated | ( | const bool & | state | ) |
Definition at line 68 of file SO3MaterialPair.cpp.
Member Data Documentation
◆ mMat1
|
protected |
Definition at line 47 of file SO3MaterialPair.h.
◆ mMat2
|
protected |
Definition at line 48 of file SO3MaterialPair.h.
◆ mScene
|
protected |
Definition at line 49 of file SO3MaterialPair.h.
◆ O3MaterialPair
|
protected |
Definition at line 46 of file SO3MaterialPair.h.
The documentation for this class was generated from the following files:
- include/SO3PhysicGraph/SO3MaterialPair.h
- src/SO3PhysicGraph/SO3MaterialPair.cpp
Generated by 1.9.8