9 #include <decomp_geometry/polyhedron.h> 59 virtual void shrink(
double shrink_distance) {}
63 void find_polyhedron() {
67 while (!obs_remain.empty()) {
68 const auto v =
ellipsoid_.closest_hyperplane(obs_remain);
71 for (
const auto &it : obs_remain) {
72 if (v.signed_dist(it) < 0)
73 obs_tmp.push_back(it);
vec_E< Vecf< N >> vec_Vecf
Vector of Eigen 1D float vector.
Definition: data_type.h:69
Line Segment Class.
Definition: decomp_base.h:18
void set_local_bbox(const Vecf< Dim > &bbox)
Adding local bounding box around line seg.
Definition: decomp_base.h:28
Vecf< Dim > local_bbox_
Local bounding box along the line segment.
Definition: decomp_base.h:94
vec_Vecf< Dim > get_obs() const
Get obstacel points.
Definition: decomp_base.h:41
void set_obs(const vec_Vecf< Dim > &obs)
Import obstacle points.
Definition: decomp_base.h:33
Polyhedron< Dim > polyhedron_
Output polyhedron.
Definition: decomp_base.h:91
Polyhedron class.
Definition: polyhedron.h:41
Ellipsoid< Dim > get_ellipsoid() const
Get ellipsoid.
Definition: decomp_base.h:44
Definition: ellipsoid.h:14
void add(const Hyperplane< Dim > &v)
Append Hyperplane.
Definition: polyhedron.h:49
vec_Vecf< Dim > points_inside(const vec_Vecf< Dim > &O) const
Calculate points inside polyhedron, non-exclusive.
Definition: polyhedron.h:65
vec_Vecf< Dim > obs_
Obstacles, input.
Definition: decomp_base.h:86
DecompBase()
Null constructor.
Definition: decomp_base.h:21
double decimal_t
Rename the float type used in lib.
Definition: data_type.h:50
virtual void shrink(double shrink_distance)
Shrink the polyhedron.
Definition: decomp_base.h:59
Polyhedron< Dim > get_polyhedron() const
Get polyhedron.
Definition: decomp_base.h:47
Eigen::Matrix< decimal_t, N, 1 > Vecf
Eigen 1D float vector.
Definition: data_type.h:57
virtual void dilate(decimal_t radius=0)=0
Inflate the line segment.
Ellipsoid< Dim > ellipsoid_
Output ellipsoid.
Definition: decomp_base.h:89