summaryrefslogtreecommitdiff
path: root/src/Bottleneck_distance/include
diff options
context:
space:
mode:
authorglisse <glisse@636b058d-ea47-450e-bf9e-a15bfbe3eedb>2017-04-05 22:49:42 +0000
committerglisse <glisse@636b058d-ea47-450e-bf9e-a15bfbe3eedb>2017-04-05 22:49:42 +0000
commit0c8ac71a00cdcfe286b8c0a940cf0b75868b59cc (patch)
treea52c57ba856aeda2f9cb86cde989f3c9e0290482 /src/Bottleneck_distance/include
parent133a4a2d3056f244df93bd06918441fe39a7c861 (diff)
In Kd_tree::remove, test the point index instead of the coordinates.
git-svn-id: svn+ssh://scm.gforge.inria.fr/svnroot/gudhi/branches/bottleneck-glisse@2311 636b058d-ea47-450e-bf9e-a15bfbe3eedb Former-commit-id: e8d50867d77eea455c34dc5a89ed9e0f45fbeeb7
Diffstat (limited to 'src/Bottleneck_distance/include')
-rw-r--r--src/Bottleneck_distance/include/gudhi/Neighbors_finder.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/Bottleneck_distance/include/gudhi/Neighbors_finder.h b/src/Bottleneck_distance/include/gudhi/Neighbors_finder.h
index 8553494d..bdc47578 100644
--- a/src/Bottleneck_distance/include/gudhi/Neighbors_finder.h
+++ b/src/Bottleneck_distance/include/gudhi/Neighbors_finder.h
@@ -149,7 +149,9 @@ inline int Neighbors_finder::pull_near(int u_point_index) {
if(!neighbor)
return null_point_index();
tmp = neighbor->point_index;
- kd_t.remove(g.get_v_point(tmp));
+ auto point = g.get_v_point(tmp);
+ int idx = point.point_index;
+ kd_t.remove(point, [idx](Internal_point const&p){return p.point_index == idx;});
}
return tmp;
}