I am using PCL to detect surface in my lidar point cloud, and I have the configuration as below:
pcl::RegionGrowing<pcl::PointXYZ, pcl::Normal> reg;
reg.setMinClusterSize(static_cast<int>(100));
reg.setMaxClusterSize(static_cast<int>(1000));
reg.setSearchMethod(new pcl::search::KdTree<pcl::PointXYZ>);
reg.setNumberOfNeighbours(30);
reg.setInputCloud(point_cloud);
reg.setInputNormals(normals);
reg.setSmoothnessThreshold(6_deg);
reg.setCurvatureThreshold(1.0);
It works fine, except I found it picks up some outlier points as shown in the image below.
I was trying to detect a plane that comes with a leg, and it seems that the method picks up some point on the leg. Is there away to avoid such point using, e.g., density threshold in the region growing method in PCL? After spending some time on the documentation and tweaking the values for region grow setups I still could not figure out how to do it.