38 #ifndef FCL_NARROWPHASE_GJKSOLVERINDEP_H 39 #define FCL_NARROWPHASE_GJKSOLVERINDEP_H 41 #include "fcl/common/deprecated.h" 42 #include "fcl/common/types.h" 43 #include "fcl/narrowphase/contact_point.h" 52 template <
typename S_>
59 template<
typename Shape1,
typename Shape2>
63 const Transform3<S>& tf1,
65 const Transform3<S>& tf2,
66 Vector3<S>* contact_points,
68 Vector3<S>* normal)
const;
71 template<
typename Shape1,
typename Shape2>
74 const Transform3<S>& tf1,
76 const Transform3<S>& tf2,
80 template<
typename Shape>
83 const Transform3<S>& tf,
87 Vector3<S>* contact_points =
nullptr,
88 S* penetration_depth =
nullptr,
89 Vector3<S>* normal =
nullptr)
const;
92 template<
typename Shape>
95 const Transform3<S>& tf1,
99 const Transform3<S>& tf2,
100 Vector3<S>* contact_points =
nullptr,
101 S* penetration_depth =
nullptr,
102 Vector3<S>* normal =
nullptr)
const;
105 template<
typename Shape1,
typename Shape2>
108 const Transform3<S>& tf1,
110 const Transform3<S>& tf2,
112 Vector3<S>* p1 =
nullptr,
113 Vector3<S>* p2 =
nullptr)
const;
116 template<
typename Shape>
119 const Transform3<S>& tf,
120 const Vector3<S>& P1,
121 const Vector3<S>& P2,
122 const Vector3<S>& P3,
124 Vector3<S>* p1 =
nullptr,
125 Vector3<S>* p2 =
nullptr)
const;
128 template<
typename Shape>
131 const Transform3<S>& tf1,
132 const Vector3<S>& P1,
133 const Vector3<S>& P2,
134 const Vector3<S>& P3,
135 const Transform3<S>& tf2,
137 Vector3<S>* p1 =
nullptr,
138 Vector3<S>* p2 =
nullptr)
const;
143 void enableCachedGuess(
bool if_enable)
const;
145 void setCachedGuess(
const Vector3<S>& guess)
const;
147 Vector3<S> getCachedGuess()
const;
180 #include "fcl/narrowphase/detail/gjk_solver_indep-inl.h" Main namespace.
Definition: broadphase_bruteforce-inl.h:45
bool shapeTriangleDistance(const Shape &s, const Transform3< S > &tf, const Vector3< S > &P1, const Vector3< S > &P2, const Vector3< S > &P3, S *distance=nullptr, Vector3< S > *p1=nullptr, Vector3< S > *p2=nullptr) const
distance computation between one shape and a triangle
Definition: gjk_solver_indep-inl.h:792
Vector3< S > cached_guess
smart guess
Definition: gjk_solver_indep.h:171
S gjk_max_iterations
maximum number of iterations used for GJK iterations
Definition: gjk_solver_indep.h:165
bool shapeDistance(const Shape1 &s1, const Transform3< S > &tf1, const Shape2 &s2, const Transform3< S > &tf2, S *distance=nullptr, Vector3< S > *p1=nullptr, Vector3< S > *p2=nullptr) const
distance computation between two shapes
Definition: gjk_solver_indep-inl.h:627
S gjk_tolerance
the threshold used in GJK to stop iteration
Definition: gjk_solver_indep.h:162
GJKSolver_indep()
default setting for GJK algorithm
Definition: gjk_solver_indep-inl.h:920
bool enable_cached_guess
Whether smart guess can be provided.
Definition: gjk_solver_indep.h:168
unsigned int epa_max_iterations
maximum number of iterations used for EPA iterations
Definition: gjk_solver_indep.h:156
unsigned int epa_max_face_num
maximum number of simplex face used in EPA algorithm
Definition: gjk_solver_indep.h:150
unsigned int epa_max_vertex_num
maximum number of simplex vertex used in EPA algorithm
Definition: gjk_solver_indep.h:153
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
collision and distance solver based on GJK algorithm implemented in fcl (rewritten the code from the ...
Definition: gjk_solver_indep.h:53
S epa_tolerance
the threshold used in EPA to stop iteration
Definition: gjk_solver_indep.h:159
FCL_DEPRECATED bool shapeIntersect(const Shape1 &s1, const Transform3< S > &tf1, const Shape2 &s2, const Transform3< S > &tf2, Vector3< S > *contact_points, S *penetration_depth, Vector3< S > *normal) const
intersection checking between two shapes
bool shapeTriangleIntersect(const Shape &s, const Transform3< S > &tf, const Vector3< S > &P1, const Vector3< S > &P2, const Vector3< S > &P3, Vector3< S > *contact_points=nullptr, S *penetration_depth=nullptr, Vector3< S > *normal=nullptr) const
intersection checking between one shape and a triangle
Definition: gjk_solver_indep-inl.h:393