Traversal node for collision between two meshes. More...
#include <hpp/fcl/traversal/traversal_node_bvhs.h>
Public Types | |
enum | { Options = _Options, RTIsIdentity = _Options & RelativeTransformationIsIdentity } |
Public Member Functions | |
MeshCollisionTraversalNode (const CollisionRequest &request) | |
bool | BVTesting (int b1, int b2) const |
BV culling test in one BVTT node. More... | |
bool | BVTesting (int b1, int b2, FCL_REAL &sqrDistLowerBound) const |
BV test between b1 and b2. More... | |
void | leafTesting (int b1, int b2, FCL_REAL &sqrDistLowerBound) const |
Intersection testing between leaves (two triangles) More... | |
bool | canStop () const |
Whether the traversal process can stop early. More... | |
![]() | |
BVHCollisionTraversalNode (const CollisionRequest &request) | |
bool | isFirstNodeLeaf (int b) const |
Whether the BV node in the first BVH tree is leaf. More... | |
bool | isSecondNodeLeaf (int b) const |
Whether the BV node in the second BVH tree is leaf. More... | |
bool | firstOverSecond (int b1, int b2) const |
Determine the traversal order, is the first BVTT subtree better. More... | |
int | getFirstLeftChild (int b) const |
Obtain the left child of BV node in the first BVH. More... | |
int | getFirstRightChild (int b) const |
Obtain the right child of BV node in the first BVH. More... | |
int | getSecondLeftChild (int b) const |
Obtain the left child of BV node in the second BVH. More... | |
int | getSecondRightChild (int b) const |
Obtain the right child of BV node in the second BVH. More... | |
![]() | |
CollisionTraversalNodeBase (const CollisionRequest &request_) | |
virtual | ~CollisionTraversalNodeBase () |
void | enableStatistics (bool enable) |
Whether store some statistics information during traversal. More... | |
![]() | |
virtual | ~TraversalNodeBase () |
virtual void | preprocess () |
virtual void | postprocess () |
Public Attributes | |
Vec3f * | vertices1 |
Vec3f * | vertices2 |
Triangle * | tri_indices1 |
Triangle * | tri_indices2 |
details::RelativeTransformation<!bool(RTIsIdentity)> | RT |
![]() | |
const BVHModel< BV > * | model1 |
The first BVH model. More... | |
const BVHModel< BV > * | model2 |
The second BVH model. More... | |
int | num_bv_tests |
statistical information More... | |
int | num_leaf_tests |
FCL_REAL | query_time_seconds |
![]() | |
const CollisionRequest & | request |
request setting for collision More... | |
CollisionResult * | result |
collision result kept during the traversal iteration More... | |
bool | enable_statistics |
Whether stores statistics. More... | |
![]() | |
Transform3f | tf1 |
configuation of first object More... | |
Transform3f | tf2 |
configuration of second object More... | |
Traversal node for collision between two meshes.
anonymous enum |
|
inline |
|
inlinevirtual |
BV culling test in one BVTT node.
Implements hpp::fcl::CollisionTraversalNodeBase.
References hpp::fcl::CollisionTraversalNodeBase::enable_statistics, hpp::fcl::BVHCollisionTraversalNode< BV >::model1, hpp::fcl::BVHCollisionTraversalNode< BV >::model2, hpp::fcl::BVHCollisionTraversalNode< BV >::num_bv_tests, and hpp::fcl::overlap().
|
inlinevirtual |
BV test between b1 and b2.
b1,b2 | Bounding volumes to test, |
sqrDistLowerBound | square of a lower bound of the minimal distance between bounding volumes. |
Implements hpp::fcl::CollisionTraversalNodeBase.
References hpp::fcl::CollisionTraversalNodeBase::enable_statistics, hpp::fcl::BVHCollisionTraversalNode< BV >::model1, hpp::fcl::BVHCollisionTraversalNode< BV >::model2, hpp::fcl::BVHCollisionTraversalNode< BV >::num_bv_tests, hpp::fcl::overlap(), and hpp::fcl::CollisionTraversalNodeBase::request.
|
inlinevirtual |
Whether the traversal process can stop early.
Reimplemented from hpp::fcl::CollisionTraversalNodeBase.
References hpp::fcl::CollisionRequest::isSatisfied(), hpp::fcl::CollisionTraversalNodeBase::request, and hpp::fcl::CollisionTraversalNodeBase::result.
|
inlinevirtual |
Intersection testing between leaves (two triangles)
b1,b2 | id of primitive in bounding volume hierarchy |
sqrDistLowerBound | squared lower bound of distance between primitives if they are not in collision. |
This method supports a security margin. If the distance between the primitives is less than the security margin, the objects are considered as in collision. in this case a contact point is returned in the CollisionResult.
Reimplemented from hpp::fcl::CollisionTraversalNodeBase.
References hpp::fcl::CollisionResult::addContact(), hpp::fcl::distance(), hpp::fcl::CollisionTraversalNodeBase::enable_statistics, hpp::fcl::BVHCollisionTraversalNode< BV >::model1, hpp::fcl::BVHCollisionTraversalNode< BV >::model2, hpp::fcl::BVHCollisionTraversalNode< BV >::num_leaf_tests, hpp::fcl::CollisionRequest::num_max_contacts, hpp::fcl::CollisionResult::numContacts(), hpp::fcl::BVNodeBase::primitiveId(), hpp::fcl::CollisionTraversalNodeBase::request, hpp::fcl::CollisionTraversalNodeBase::result, hpp::fcl::CollisionRequest::security_margin, hpp::fcl::GJKSolver_indep::shapeDistance(), hpp::fcl::TraversalNodeBase::tf1, and hpp::fcl::TraversalNodeBase::tf2.
details::RelativeTransformation<!bool(RTIsIdentity)> hpp::fcl::MeshCollisionTraversalNode< BV, _Options >::RT |
Triangle* hpp::fcl::MeshCollisionTraversalNode< BV, _Options >::tri_indices1 |
Referenced by hpp::fcl::initialize().
Triangle* hpp::fcl::MeshCollisionTraversalNode< BV, _Options >::tri_indices2 |
Referenced by hpp::fcl::initialize().
Vec3f* hpp::fcl::MeshCollisionTraversalNode< BV, _Options >::vertices1 |
Referenced by hpp::fcl::initialize().
Vec3f* hpp::fcl::MeshCollisionTraversalNode< BV, _Options >::vertices2 |
Referenced by hpp::fcl::initialize().