MeshModifier that fits planes to the input mesh and projects the vertices onto the fitted planes.
#include <ransac_plane_fit_modifier.h>
|
| | RansacPrimitiveFitMeshModifier (float distance_threshold, unsigned min_vertices=1, int max_primitives=-1, unsigned max_iterations=100) |
| | Constructor.
|
| |
|
| RansacPrimitiveFitMeshModifier ()=default |
| |
| | RansacPrimitiveFitMeshModifier (float distance_threshold, unsigned min_vertices=1, int max_primitives=-1, unsigned max_iterations=100) |
| | Constructor.
|
| |
| std::vector< pcl::PolygonMesh > | modify (const pcl::PolygonMesh &mesh) const override |
| |
|
| std::shared_ptr< pcl::SampleConsensusModel< pcl::PointXYZ > > | createModel (const pcl::PolygonMesh &) const override |
| | Creates a SAC plane model.
|
| |
| pcl::PolygonMesh | createSubMesh (const pcl::PolygonMesh &mesh, std::shared_ptr< const pcl::RandomSampleConsensus< pcl::PointXYZ > > ransac) const override |
| | Creates a sub-mesh by projecting the inlier vertices/triangles onto the fitted plane.
|
| |
|
|
using | Ptr = std::unique_ptr< MeshModifier > |
| |
|
using | ConstPtr = std::unique_ptr< const MeshModifier > |
| |
|
float | distance_threshold_ |
| |
|
unsigned | min_vertices_ |
| |
|
int | max_primitives_ |
| |
|
unsigned | max_iterations_ |
| |
◆ createModel()
| std::shared_ptr< pcl::SampleConsensusModel< pcl::PointXYZ > > noether::RansacPlaneProjectionMeshModifier::createModel |
( |
const pcl::PolygonMesh & |
mesh | ) |
const |
|
overrideprotectedvirtual |
◆ createSubMesh()
| pcl::PolygonMesh noether::RansacPlaneProjectionMeshModifier::createSubMesh |
( |
const pcl::PolygonMesh & |
mesh, |
|
|
std::shared_ptr< const pcl::RandomSampleConsensus< pcl::PointXYZ > > |
ransac |
|
) |
| const |
|
overrideprotectedvirtual |
◆ RansacPrimitiveFitMeshModifier()
| noether::RansacPrimitiveFitMeshModifier::RansacPrimitiveFitMeshModifier |
( |
float |
distance_threshold, |
|
|
unsigned |
min_vertices = 1, |
|
|
int |
max_primitives = -1, |
|
|
unsigned |
max_iterations = 100 |
|
) |
| |
- Parameters
-
| distance_threshold | Maximum distance (m) a point can be from the primitive model to be considered an inlier |
| min_vertices | Minimum number of vertices that a cluster (identfied as a primitive) must have |
| max_primitives | Maximum number of primitives to detect |
| max_iterations | Maximum number of RANSAC iterations to perform |