Skip to Content.
Sympa Menu

cgal-discuss - Re: [cgal-discuss] Kd_tree interface

Subject: CGAL users discussion list

List archive

Re: [cgal-discuss] Kd_tree interface


Chronological Thread 
  • From: Ashwin Nanjappa <>
  • To:
  • Subject: Re: [cgal-discuss] Kd_tree interface
  • Date: Fri, 23 Nov 2007 10:54:53 +0800

Matthijs Sypkens Smit wrote:
Hi,

In the manual for CGAL 3.3 it says that there is a class method clear(), to clear a Kd_tree, but it seems that is does not exist in the code. Looking at the code I conclude that at insertion the tree is cleared automatically. However, this is even the case for the insertion of a single point. Is there any use for a tree with just a single point?

Yes, Kd_tree.clear() is in the manual, but doesn't seem to be implemented. I see this problem too.

If I'm not wrong, it might be as simple as adding the following lines to kd_tree.h:
//////////////////////
class Kd_tree {
public:
// [..........]
void
clear() const
{
pts.clear();
return;
}
// [..........]
};
//////////////////////

~ash



Archive powered by MHonArc 2.6.16.

Top of Page