PPL API Reference |
|
---|
Public Member Functions | |
Modifiers | |
void | Merge (const CDClearanceMap &_other) |
void | SetClearance (const Body *const _a, const Body *const _b, const double _clearance) |
void | Clear () |
Reset the structure. | |
Queries | |
double | GetClearance (const Body *const _a, const Body *const _b) const noexcept |
double | GetClearance (const MultiBody *const _a, const MultiBody *const _b) const noexcept |
double | GetMinClearance () const noexcept |
Get the lowest reported clearance. | |
BodyKey | GetClosestBodies () const noexcept |
Get the body pair which had the lowest clearance value. | |
MultiBodyKey | GetClosestMultiBodies () const noexcept |
Get the multibody pair which had the lowest clearance value. | |
iterator | begin () const noexcept |
iterator | end () const noexcept |
Public Types | |
Local Types | |
typedef std::pair< const Body *, const Body * > | BodyKey |
typedef std::pair< const MultiBody *, const MultiBody * > | MultiBodyKey |
typedef std::map< BodyKey, double > | BodyMap |
typedef std::map< MultiBodyKey, double > | MultiBodyMap |
typedef BodyMap::const_iterator | iterator |
Map for tracking the detected clearance between bodies during collision detection.
void CDClearanceMap::Merge | ( | const CDClearanceMap & | _other | ) |
Merge another clearance map into this one. If a key is present in both maps, the lowest clearance will be maintained.
_other | The map to merge into this one. |
void CDClearanceMap::SetClearance | ( | const Body *const | _a, |
const Body *const | _b, | ||
const double | _clearance | ||
) |
Set the observed clearance between two bodies.
_a | The first body. |
_b | The second body. |
_clearance | The clearance observed between _a and _b. |
Get the observed clearance between two bodies.
_a | The first body. |
_b | The second body. |
|
noexcept |
Get the observed clearance between two multibodies.
_a | The first multibody. |
_b | The second multibody. |