issue-6550

detect_planar_patches fails with perfectly flat surfaces

Debug 过程

static std::array<Eigen::Vector3d, 6> colors = {
		Eigen::Vector3d(0.8500, 0.3250, 0.0980),
		Eigen::Vector3d(0.9290, 0.6940, 0.1250),
		Eigen::Vector3d(0.4940, 0.1840, 0.5560),
		Eigen::Vector3d(0.4660, 0.6740, 0.1880),
		Eigen::Vector3d(0.3010, 0.7450, 0.9330),
		Eigen::Vector3d(0.6350, 0.0780, 0.1840)};
PointCloud dummy;
for (size_t i = 0; i < planes.size(); i++) {
	auto& plane = planes[i];
	auto pcd = this->SelectByIndex(plane->indices_);
	pcd->PaintUniformColor(colors[i % colors.size()]);
	dummy += *pcd;
}
  1. 分割 BVH 后结果正确
  2. Merge 没有正确合并相邻的 patch,这个函数实现可能有问题
  3. 在这个 issue 的数据中,大量两两 patch 的法向量点积为 min_normal_diff_ 也为 ,合并过程中这个[[A robust statistics approach for plane detection in unorganized point clouds#Robust plane detection#2. Plane-sample normal deviation test|阈值判断条件]]就失效了