105 template <
typename Po
intT>
double inline
109 double max_dist = std::numeric_limits<double>::min ();
110 const auto token = std::numeric_limits<std::size_t>::max();
113 for (std::size_t i = 0; i < cloud.
size (); ++i)
115 for (std::size_t j = i; j < cloud.
size (); ++j)
118 double dist = (cloud[i].getVector4fMap () -
130 return (
max_dist = std::numeric_limits<double>::min ());
145 template <
typename Po
intT>
double inline
149 double max_dist = std::numeric_limits<double>::min ();
150 const auto token = std::numeric_limits<std::size_t>::max();
153 for (std::size_t i = 0; i < indices.size (); ++i)
155 for (std::size_t j = i; j < indices.size (); ++j)
158 double dist = (cloud[indices[i]].getVector4fMap () -
159 cloud[indices[j]].getVector4fMap ()).
squaredNorm ();
170 return (
max_dist = std::numeric_limits<double>::min ());
181 template<
typename Po
intType1,
typename Po
intType2>
inline float
192 template<>
inline float
203 template<
typename Po
intType1,
typename Po
intType2>
inline float
Iterator class for point clouds with or without given indices.
std::size_t size() const
Size of the range the iterator is going through.
PointCloud represents the base class in PCL for storing collections of 3D points.
Defines all the PCL implemented PointT point type structures.
double getMaxSegment(const pcl::PointCloud< PointT > &cloud, PointT &pmin, PointT &pmax)
Obtain the maximum segment in a given set of points, and return the minimum and maximum points.
PCL_EXPORTS void lineToLineSegment(const Eigen::VectorXf &line_a, const Eigen::VectorXf &line_b, Eigen::Vector4f &pt1_seg, Eigen::Vector4f &pt2_seg)
Get the shortest 3D segment between two 3D lines.
double sqrPointToLineDistance(const Eigen::Vector4f &pt, const Eigen::Vector4f &line_pt, const Eigen::Vector4f &line_dir)
Get the square distance from a point to a line (represented by a point and a direction)
float squaredEuclideanDistance(const PointType1 &p1, const PointType2 &p2)
Calculate the squared euclidean distance between the two given points.
IndicesAllocator<> Indices
Type used for indices in PCL.
float euclideanDistance(const PointType1 &p1, const PointType2 &p2)
Calculate the euclidean distance between the two given points.
A 2D point structure representing Euclidean xy coordinates.
A point structure representing Euclidean xyz coordinates, and the RGB color.
Defines basic non-point types used by PCL.