mirror of https://github.com/CGAL/cgal
Only check if other shape is the same if inliers not empty
This commit is contained in:
parent
0ce39504c8
commit
94b0157563
|
|
@ -597,12 +597,13 @@ shape. The implementation follows \cgalCite{schnabel2007efficient}.
|
||||||
if (best_candidate->indices_of_assigned_points().size() <
|
if (best_candidate->indices_of_assigned_points().size() <
|
||||||
m_options.min_points)
|
m_options.min_points)
|
||||||
{
|
{
|
||||||
for (std::size_t i = 0;i < candidates.size() - 1;i++) {
|
if (!(best_candidate->indices_of_assigned_points().empty()))
|
||||||
if (best_candidate->is_same(candidates[i])) {
|
for (std::size_t i = 0;i < candidates.size() - 1;i++) {
|
||||||
delete candidates[i];
|
if (best_candidate->is_same(candidates[i])) {
|
||||||
candidates[i] = NULL;
|
delete candidates[i];
|
||||||
|
candidates[i] = NULL;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
candidates.back() = NULL;
|
candidates.back() = NULL;
|
||||||
delete best_candidate;
|
delete best_candidate;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue