38 #ifndef FCL_TRAVERSAL_SHAPEDISTANCETRAVERSALNODE_INL_H 39 #define FCL_TRAVERSAL_SHAPEDISTANCETRAVERSALNODE_INL_H 41 #include "fcl/narrowphase/detail/traversal/distance/shape_distance_traversal_node.h" 50 template <
typename Shape1,
typename Shape2,
typename NarrowPhaseSolver>
51 ShapeDistanceTraversalNode<Shape1, Shape2, NarrowPhaseSolver>::
52 ShapeDistanceTraversalNode() : DistanceTraversalNodeBase<typename Shape1::S>()
61 template <
typename Shape1,
typename Shape2,
typename NarrowPhaseSolver>
69 template <
typename Shape1,
typename Shape2,
typename NarrowPhaseSolver>
73 using S =
typename Shape1::S;
82 Vector3<S> closest_p1 = Vector3<S>::Zero();
83 Vector3<S> closest_p2 = Vector3<S>::Zero();
85 nsolver->shapeDistance(
86 *model1, this->
tf1, *model2, this->
tf2, &distance, &closest_p1, &closest_p2);
99 template <
typename Shape1,
typename Shape2,
typename NarrowPhaseSolver>
102 const Shape1& shape1,
103 const Transform3<typename Shape1::S>&
tf1,
104 const Shape2& shape2,
105 const Transform3<typename Shape1::S>&
tf2,
106 const NarrowPhaseSolver* nsolver,
113 node.model1 = &shape1;
115 node.model2 = &shape2;
117 node.nsolver = nsolver;
Main namespace.
Definition: broadphase_bruteforce-inl.h:45
Traversal node for distance between two shapes.
Definition: shape_distance_traversal_node.h:52
void leafTesting(int, int) const
Distance testing between leaves (two shapes)
Definition: shape_distance_traversal_node-inl.h:70
distance result
Definition: distance_request.h:48
void update(S distance, const CollisionGeometry< S > *o1_, const CollisionGeometry< S > *o2_, int b1_, int b2_)
add distance information into the result
Definition: distance_result-inl.h:64
Transform3< Shape1::S > tf2
configuration of second object
Definition: traversal_node_base.h:88
S BVTesting(int, int) const
BV culling test in one BVTT node.
Definition: shape_distance_traversal_node-inl.h:63
DistanceRequest< Shape1::S > request
request setting for distance
Definition: distance_traversal_node_base.h:73
DistanceResult< Shape1::S > * result
distance result kept during the traversal iteration
Definition: distance_traversal_node_base.h:76
Transform3< Shape1::S > tf1
configuation of first object
Definition: traversal_node_base.h:85
S distance(const Eigen::MatrixBase< DerivedA > &R0, const Eigen::MatrixBase< DerivedB > &T0, const kIOS< S > &b1, const kIOS< S > &b2, Vector3< S > *P, Vector3< S > *Q)
Approximate distance between two kIOS bounding volumes.
Definition: kIOS-inl.h:266
request to the distance computation
Definition: distance_request.h:52