Go to the documentation of this file.
48 std::vector<Vec3f> result(8);
67 std::vector<Vec3f> result(12);
69 FCL_REAL edge_size =
sphere.radius * 6 / (sqrt(27.0) + sqrt(15.0));
92 std::vector<Vec3f> result(12);
93 const FCL_REAL phi = (1 + sqrt(5.0)) / 2.0;
95 const FCL_REAL a = sqrt(3.0) / (phi * phi);
126 std::vector<Vec3f> result(36);
127 const FCL_REAL m = (1 + sqrt(5.0)) / 2.0;
130 FCL_REAL edge_size = capsule.
radius * 6 / (sqrt(27.0) + sqrt(15.0));
181 std::vector<Vec3f> result(7);
202 std::vector<Vec3f> result(12);
229 for (std::size_t i = 0; i < convex.
num_points; ++i) {
238 std::vector<Vec3f> result(3);
280 bv.
max_ = T + v_delta;
281 bv.
min_ = T - v_delta;
289 bv.
max_ = T + v_delta;
290 bv.
min_ = T - v_delta;
300 bv.
max_ = T + v_delta;
301 bv.
min_ = T - v_delta;
311 bv.
max_ = T + v_delta;
312 bv.
min_ = T - v_delta;
327 Vec3f v_delta(x_range, y_range, z_range);
328 bv.
max_ = T + v_delta;
329 bv.
min_ = T - v_delta;
345 Vec3f v_delta(x_range, y_range, z_range);
346 bv.
max_ = T + v_delta;
347 bv.
min_ = T - v_delta;
357 for (std::size_t i = 0; i < s.
num_points; ++i) {
379 bv_.
min_ = Vec3f::Constant(-(std::numeric_limits<FCL_REAL>::max)());
380 bv_.
max_ = Vec3f::Constant((std::numeric_limits<FCL_REAL>::max)());
411 bv_.
min_ = Vec3f::Constant(-(std::numeric_limits<FCL_REAL>::max)());
412 bv_.
max_ = Vec3f::Constant((std::numeric_limits<FCL_REAL>::max)());
417 }
else if (n[0] > 0) {
424 }
else if (n[1] > 0) {
431 }
else if (n[2] > 0) {
454 bv.
axes.setIdentity();
464 bv.
axes.noalias() =
R;
474 bv.
axes.noalias() =
R;
485 bv.
axes.noalias() =
R;
497 bv.
axes.applyOnTheLeft(
R);
499 bv.
To =
R * bv.
To + T;
505 bv.
axes.setIdentity();
507 bv.
extent.setConstant(((std::numeric_limits<FCL_REAL>::max)()));
513 bv.
axes.setIdentity();
516 (std::numeric_limits<FCL_REAL>::max)();
532 bv.
spheres[0].
r = (std::numeric_limits<FCL_REAL>::max)();
543 for (
short i = 0; i <
D; ++i)
544 bv.dist(i) = -(std::numeric_limits<FCL_REAL>::max)();
545 for (
short i =
D; i < 2 *
D; ++i)
546 bv.dist(i) = (std::numeric_limits<FCL_REAL>::max)();
563 }
else if (n[2] == (
FCL_REAL)0.0 && n[0] == n[1]) {
565 bv.dist(
D + 3) = n[0] * d * 2;
567 bv.dist(3) = n[0] * d * 2;
568 }
else if (n[1] == (
FCL_REAL)0.0 && n[0] == n[2]) {
570 bv.dist(
D + 4) = n[0] * d * 2;
572 bv.dist(4) = n[0] * d * 2;
573 }
else if (n[0] == (
FCL_REAL)0.0 && n[1] == n[2]) {
575 bv.dist(
D + 5) = n[1] * d * 2;
577 bv.dist(5) = n[1] * d * 2;
580 bv.dist(
D + 6) = n[0] * d * 2;
582 bv.dist(6) = n[0] * d * 2;
585 bv.dist(
D + 7) = n[0] * d * 2;
587 bv.dist(7) = n[0] * d * 2;
600 for (
short i = 0; i <
D; ++i)
601 bv.dist(i) = -(std::numeric_limits<FCL_REAL>::max)();
602 for (
short i =
D; i < 2 *
D; ++i)
603 bv.dist(i) = (std::numeric_limits<FCL_REAL>::max)();
620 }
else if (n[2] == (
FCL_REAL)0.0 && n[0] == n[1]) {
622 bv.dist(
D + 3) = n[0] * d * 2;
624 bv.dist(3) = n[0] * d * 2;
625 }
else if (n[1] == (
FCL_REAL)0.0 && n[0] == n[2]) {
627 bv.dist(
D + 4) = n[0] * d * 2;
629 bv.dist(4) = n[0] * d * 2;
630 }
else if (n[0] == (
FCL_REAL)0.0 && n[1] == n[2]) {
632 bv.dist(
D + 5) = n[1] * d * 2;
634 bv.dist(5) = n[1] * d * 2;
637 bv.dist(
D + 6) = n[0] * d * 2;
639 bv.dist(6) = n[0] * d * 2;
642 bv.dist(
D + 7) = n[0] * d * 2;
644 bv.dist(7) = n[0] * d * 2;
647 bv.dist(
D + 8) = n[1] * d * 2;
649 bv.dist(8) = n[1] * d * 2;
662 for (
short i = 0; i <
D; ++i)
663 bv.dist(i) = -(std::numeric_limits<FCL_REAL>::max)();
664 for (
short i =
D; i < 2 *
D; ++i)
665 bv.dist(i) = (std::numeric_limits<FCL_REAL>::max)();
682 }
else if (n[2] == (
FCL_REAL)0.0 && n[0] == n[1]) {
684 bv.dist(
D + 3) = n[0] * d * 2;
686 bv.dist(3) = n[0] * d * 2;
687 }
else if (n[1] == (
FCL_REAL)0.0 && n[0] == n[2]) {
689 bv.dist(
D + 4) = n[0] * d * 2;
691 bv.dist(4) = n[0] * d * 2;
692 }
else if (n[0] == (
FCL_REAL)0.0 && n[1] == n[2]) {
694 bv.dist(
D + 5) = n[1] * d * 2;
696 bv.dist(5) = n[1] * d * 2;
699 bv.dist(
D + 6) = n[0] * d * 2;
701 bv.dist(6) = n[0] * d * 2;
704 bv.dist(
D + 7) = n[0] * d * 2;
706 bv.dist(7) = n[0] * d * 2;
709 bv.dist(
D + 8) = n[1] * d * 2;
711 bv.dist(8) = n[1] * d * 2;
714 bv.dist(
D + 9) = n[0] * d * 3;
716 bv.dist(9) = n[0] * d * 3;
719 bv.dist(
D + 10) = n[0] * d * 3;
721 bv.dist(10) = n[0] * d * 3;
724 bv.dist(
D + 11) = n[1] * d * 3;
726 bv.dist(11) = n[1] * d * 3;
734 bv.
axes.col(0).noalias() = n;
736 bv.
extent << 0, (std::numeric_limits<FCL_REAL>::max)(),
737 (std::numeric_limits<FCL_REAL>::max)();
749 bv.
axes.col(0).noalias() = n;
751 bv.
length[0] = (std::numeric_limits<FCL_REAL>::max)();
752 bv.
length[1] = (std::numeric_limits<FCL_REAL>::max)();
772 bv.
spheres[0].
r = (std::numeric_limits<FCL_REAL>::max)();
784 for (
short i = 0; i <
D; ++i)
785 bv.dist(i) = -(std::numeric_limits<FCL_REAL>::max)();
786 for (
short i =
D; i < 2 *
D; ++i)
787 bv.dist(i) = (std::numeric_limits<FCL_REAL>::max)();
791 bv.dist(0) = bv.dist(
D) = d;
793 bv.dist(0) = bv.dist(
D) = -d;
796 bv.dist(1) = bv.dist(
D + 1) = d;
798 bv.dist(1) = bv.dist(
D + 1) = -d;
801 bv.dist(2) = bv.dist(
D + 2) = d;
803 bv.dist(2) = bv.dist(
D + 2) = -d;
804 }
else if (n[2] == (
FCL_REAL)0.0 && n[0] == n[1]) {
805 bv.dist(3) = bv.dist(
D + 3) = n[0] * d * 2;
806 }
else if (n[1] == (
FCL_REAL)0.0 && n[0] == n[2]) {
807 bv.dist(4) = bv.dist(
D + 4) = n[0] * d * 2;
808 }
else if (n[0] == (
FCL_REAL)0.0 && n[1] == n[2]) {
809 bv.dist(6) = bv.dist(
D + 5) = n[1] * d * 2;
811 bv.dist(6) = bv.dist(
D + 6) = n[0] * d * 2;
813 bv.dist(7) = bv.dist(
D + 7) = n[0] * d * 2;
826 for (
short i = 0; i <
D; ++i)
827 bv.dist(i) = -(std::numeric_limits<FCL_REAL>::max)();
828 for (
short i =
D; i < 2 *
D; ++i)
829 bv.dist(i) = (std::numeric_limits<FCL_REAL>::max)();
833 bv.dist(0) = bv.dist(
D) = d;
835 bv.dist(0) = bv.dist(
D) = -d;
838 bv.dist(1) = bv.dist(
D + 1) = d;
840 bv.dist(1) = bv.dist(
D + 1) = -d;
843 bv.dist(2) = bv.dist(
D + 2) = d;
845 bv.dist(2) = bv.dist(
D + 2) = -d;
846 }
else if (n[2] == (
FCL_REAL)0.0 && n[0] == n[1]) {
847 bv.dist(3) = bv.dist(
D + 3) = n[0] * d * 2;
848 }
else if (n[1] == (
FCL_REAL)0.0 && n[0] == n[2]) {
849 bv.dist(4) = bv.dist(
D + 4) = n[0] * d * 2;
850 }
else if (n[0] == (
FCL_REAL)0.0 && n[1] == n[2]) {
851 bv.dist(5) = bv.dist(
D + 5) = n[1] * d * 2;
853 bv.dist(6) = bv.dist(
D + 6) = n[0] * d * 2;
855 bv.dist(7) = bv.dist(
D + 7) = n[0] * d * 2;
857 bv.dist(8) = bv.dist(
D + 8) = n[1] * d * 2;
870 for (
short i = 0; i <
D; ++i)
871 bv.dist(i) = -(std::numeric_limits<FCL_REAL>::max)();
872 for (
short i =
D; i < 2 *
D; ++i)
873 bv.dist(i) = (std::numeric_limits<FCL_REAL>::max)();
877 bv.dist(0) = bv.dist(
D) = d;
879 bv.dist(0) = bv.dist(
D) = -d;
882 bv.dist(1) = bv.dist(
D + 1) = d;
884 bv.dist(1) = bv.dist(
D + 1) = -d;
887 bv.dist(2) = bv.dist(
D + 2) = d;
889 bv.dist(2) = bv.dist(
D + 2) = -d;
890 }
else if (n[2] == (
FCL_REAL)0.0 && n[0] == n[1]) {
891 bv.dist(3) = bv.dist(
D + 3) = n[0] * d * 2;
892 }
else if (n[1] == (
FCL_REAL)0.0 && n[0] == n[2]) {
893 bv.dist(4) = bv.dist(
D + 4) = n[0] * d * 2;
894 }
else if (n[0] == (
FCL_REAL)0.0 && n[1] == n[2]) {
895 bv.dist(5) = bv.dist(
D + 5) = n[1] * d * 2;
897 bv.dist(6) = bv.dist(
D + 6) = n[0] * d * 2;
899 bv.dist(7) = bv.dist(
D + 7) = n[0] * d * 2;
901 bv.dist(8) = bv.dist(
D + 8) = n[1] * d * 2;
903 bv.dist(9) = bv.dist(
D + 9) = n[0] * d * 3;
905 bv.dist(10) = bv.dist(
D + 10) = n[0] * d * 3;
907 bv.dist(11) = bv.dist(
D + 11) = n[1] * d * 3;
FCL_REAL radius
Radius of the cylinder.
FCL_REAL height() const
Height of the RSS.
Matrix3f axes
Orientation of OBB. axis[i] is the ith column of the orientation matrix for the box; it is also the i...
HPP_FCL_DLLAPI void computeBV< AABB, TriangleP >(const TriangleP &s, const Transform3f &tf, AABB &bv)
Vec3f extent
Half dimensions of OBB.
Eigen::Matrix< FCL_REAL, 3, 1 > Vec3f
HPP_FCL_DLLAPI Halfspace transform(const Halfspace &a, const Transform3f &tf)
HPP_FCL_DLLAPI void computeBV< AABB, Box >(const Box &s, const Transform3f &tf, AABB &bv)
Vec3f * points
An array of the points of the polygon.
HPP_FCL_DLLAPI void computeBV< OBB, Sphere >(const Sphere &s, const Transform3f &tf, OBB &bv)
HPP_FCL_DLLAPI void computeBV< AABB, Sphere >(const Sphere &s, const Transform3f &tf, AABB &bv)
Matrix3f axes
Orientation of RSS. axis[i] is the ith column of the orientation matrix for the RSS; it is also the i...
FCL_REAL depth() const
Depth of the RSS.
FCL_REAL depth() const
The (AABB) depth.
OBB obb
OBB member, for rotation.
HPP_FCL_DLLAPI void computeBV< OBB, Halfspace >(const Halfspace &s, const Transform3f &tf, OBB &bv)
HPP_FCL_DLLAPI void computeBV< OBBRSS, Halfspace >(const Halfspace &s, const Transform3f &tf, OBBRSS &bv)
Center at zero point sphere.
Vec3f min_
The min point in the AABB.
FCL_REAL radius
Radius of capsule.
HPP_FCL_DLLAPI void computeBV< OBB, Cone >(const Cone &s, const Transform3f &tf, OBB &bv)
A class describing the kIOS collision structure, which is a set of spheres.
Vec3f max_
The max point in the AABB.
HPP_FCL_DLLAPI void computeBV< kIOS, Halfspace >(const Halfspace &s, const Transform3f &tf, kIOS &bv)
HPP_FCL_DLLAPI void computeBV< AABB, Cylinder >(const Cylinder &s, const Transform3f &tf, AABB &bv)
HPP_FCL_DLLAPI void computeBV< OBB, Cylinder >(const Cylinder &s, const Transform3f &tf, OBB &bv)
void fit(Vec3f *ps, unsigned int n, BV &bv)
Compute a bounding volume that fits a set of n points.
Vec3f Tr
Origin of the rectangle in RSS.
Vec3f halfSide
box side half-length
Cylinder along Z axis. The cylinder is defined at its centroid.
FCL_REAL halfLength
Half Length along z axis.
FCL_REAL halfLength
Half Length along z axis.
Ellipsoid centered at point zero.
HPP_FCL_DLLAPI void computeBV< OBB, Capsule >(const Capsule &s, const Transform3f &tf, OBB &bv)
FCL_REAL radius
Radius of the sphere.
HPP_FCL_DLLAPI void computeBV< RSS, Plane >(const Plane &s, const Transform3f &tf, RSS &bv)
HPP_FCL_DLLAPI void computeBV< OBB, ConvexBase >(const ConvexBase &s, const Transform3f &tf, OBB &bv)
OBB obb
@ OBB related with kIOS
HPP_FCL_DLLAPI void computeBV< AABB, Ellipsoid >(const Ellipsoid &e, const Transform3f &tf, AABB &bv)
HPP_FCL_DLLAPI void constructBox(const AABB &bv, Box &box, Transform3f &tf)
construct a box shape (with a configuration) from a given bounding volume
HPP_FCL_DLLAPI void computeBV< AABB, Cone >(const Cone &s, const Transform3f &tf, AABB &bv)
Oriented bounding box class.
HPP_FCL_DLLAPI void computeBV< AABB, Halfspace >(const Halfspace &s, const Transform3f &tf, AABB &bv)
Cone The base of the cone is at and the top is at .
Capsule It is where is the distance between the point x and the capsule segment AB,...
A class describing the AABB collision structure, which is a box in 3D space determined by two diagona...
HPP_FCL_DLLAPI void computeBV< OBB, Box >(const Box &s, const Transform3f &tf, OBB &bv)
FCL_REAL radius
Radius of the cone.
HPP_FCL_DLLAPI void computeBV< OBB, Plane >(const Plane &s, const Transform3f &tf, OBB &bv)
FCL_REAL height() const
The (AABB) height.
HPP_FCL_DLLAPI void computeBV< AABB, Plane >(const Plane &s, const Transform3f &tf, AABB &bv)
unsigned int num_spheres
The number of spheres, no larger than 5.
Eigen::Matrix< FCL_REAL, 3, 3 > Matrix3f
HPP_FCL_DLLAPI void computeBV< RSS, Halfspace >(const Halfspace &s, const Transform3f &tf, RSS &bv)
Base for convex polytope.
Half Space: this is equivalent to the Plane in ODE. The separation plane is defined as n * x = d; Poi...
HPP_FCL_DLLAPI void computeBV< kIOS, Plane >(const Plane &s, const Transform3f &tf, kIOS &bv)
Vec3f center() const
The (AABB) center.
HPP_FCL_DLLAPI void computeBV< AABB, ConvexBase >(const ConvexBase &s, const Transform3f &tf, AABB &bv)
RSS rss
RSS member, for distance.
Triangle stores the points instead of only indices of points.
HPP_FCL_DLLAPI void computeBV< AABB, Capsule >(const Capsule &s, const Transform3f &tf, AABB &bv)
FCL_REAL width() const
The (AABB) width.
FCL_REAL halfLength
Half Length along z axis.
HPP_FCL_DLLAPI void computeBV< OBBRSS, Plane >(const Plane &s, const Transform3f &tf, OBBRSS &bv)
FCL_REAL width() const
Width of the RSS.
FCL_REAL length[2]
Side lengths of rectangle.
FCL_REAL radius
Radius of sphere summed with rectangle to form RSS.
Vec3f center() const
Center of the AABB.
std::vector< Vec3f > getBoundVertices(const Box &box, const Transform3f &tf)
KDOP class describes the KDOP collision structures. K is set as the template parameter,...
Vec3f radii
Radii of the Ellipsoid (such that on boundary: x^2/rx^2 + y^2/ry^2.
Center at zero point, axis aligned box.
kIOS_Sphere spheres[5]
The (at most) five spheres for intersection.
void generateCoordinateSystem(const Eigen::MatrixBase< Derived1 > &_w, const Eigen::MatrixBase< Derived2 > &_u, const Eigen::MatrixBase< Derived3 > &_v)
hpp-fcl
Author(s):
autogenerated on Fri Aug 2 2024 02:45:13