Point Cloud Library (PCL)
1.11.1-dev
|
12 #include <pcl/filters/filter_indices.h>
13 #include <pcl/type_traits.h>
16 namespace experimental {
22 template <
typename Po
intT,
typename Function>
24 is_invocable_r_v<bool, Function, const PointCloud<PointT>&,
index_t>;
34 template <
typename Po
intT,
typename FunctionObject>
42 static_assert(is_function_object_for_filter_v<PointT, FunctionObjectT>,
43 "Function object signature must be similar to `bool(const "
44 "PointCloud<PointT>&, index_t)`");
97 indices.push_back(index);
107 template <
class Po
intT>
110 template <
class Po
intT>
void applyFilter(Indices &indices) override
Filtered results are indexed by an indices array.
PointCloudConstPtr input_
The input point cloud dataset.
std::function< bool(const PointCloud< PointT > &, index_t)> FilterFunction
PointCloud represents the base class in PCL for storing collections of 3D points.
detail::int_type_t< detail::index_type_size, detail::index_type_signed > index_t
Type used for an index in PCL.
Filter point clouds and indices based on a function object passed in the ctor.
FunctionObjectT functionObject_
constexpr static bool is_function_object_for_filter_v
Checks if the function object meets the usage in FunctorFilter class.
IndicesPtr removed_indices_
Indices of the points that are removed.
FilterIndices represents the base class for filters that are about binary point removal.
FunctionObjectT & getFunctionObject() noexcept
IndicesAllocator<> Indices
Type used for indices in PCL.
const FunctionObjectT & getFunctionObject() const noexcept
std::string filter_name_
The filter name.
IndicesPtr indices_
A pointer to the vector of point indices to use.
FunctionObject FunctionObjectT
bool negative_
False = normal filter behavior (default), true = inverted behavior.
FunctorFilter(FunctionObjectT function_object, bool extract_removed_indices=false)
Constructor.
bool extract_removed_indices_
Set to true if we want to return the indices of the removed points.