mirror of https://github.com/CGAL/cgal
remove private test
This commit is contained in:
parent
6e2161b490
commit
f01ec78b4c
|
|
@ -34,10 +34,6 @@
|
|||
#include <CGAL/Iterator_project.h>
|
||||
#include <CGAL/function_objects.h>
|
||||
|
||||
#if defined(TEST)
|
||||
#include <CGAL/kdtree_d.h>
|
||||
#endif
|
||||
|
||||
CGAL_BEGIN_NAMESPACE
|
||||
|
||||
/*!
|
||||
|
|
@ -76,12 +72,6 @@ public:
|
|||
typedef typename T::Iso_rectangle_2 Iso_rectangle_2;
|
||||
typedef T Traits;
|
||||
|
||||
#if defined(TEST)
|
||||
typedef CGAL::Kdtree_interface_2d<Point_2> kd_interface;
|
||||
typedef CGAL::Kdtree_d<kd_interface> kd_tree;
|
||||
typedef typename kd_tree::Box Kd_box;
|
||||
#endif
|
||||
|
||||
class Point_data;
|
||||
|
||||
class Less_yx
|
||||
|
|
@ -228,10 +218,6 @@ public:
|
|||
Iso_rectangle_2
|
||||
get_largest_empty_iso_rectangle();
|
||||
|
||||
#if defined(TEST)
|
||||
void kd_test(Iso_rectangle_2 rec);
|
||||
#endif
|
||||
|
||||
//! Retrieve four points from the input that define the largest
|
||||
//! empty iso rectangle.
|
||||
Quadruple<Point_2, Point_2, Point_2, Point_2>
|
||||
|
|
@ -1309,40 +1295,6 @@ Largest_empty_iso_rectangle_2<T>::update()
|
|||
}
|
||||
}
|
||||
|
||||
#if defined(TEST)
|
||||
template<class T>
|
||||
void Largest_empty_iso_rectangle_2<T>::kd_test(Iso_rectangle_2 rec)
|
||||
{
|
||||
kd_tree *tree = new kd_tree(2);
|
||||
std::list<Point_2> l;
|
||||
|
||||
for(const_iterator it = begin();
|
||||
it != end();
|
||||
++it){
|
||||
const Point_2& p = *it;
|
||||
l.push_back(p);
|
||||
}
|
||||
|
||||
tree->build(l);
|
||||
|
||||
if(!tree->is_valid() )
|
||||
tree->dump();
|
||||
assert(tree->is_valid());
|
||||
|
||||
list<Point_2> res;
|
||||
Kd_box b(rec.min(),rec.max(),2);
|
||||
tree->search(std::back_inserter(res),b);
|
||||
|
||||
for(list<Point_2>::iterator iter = res.begin();
|
||||
iter != res.end();
|
||||
++iter)
|
||||
if(rec.has_on_bounded_side(*iter)) {
|
||||
std::cout << "LER has points inside!!!!!!!!!!!!!!!\n";
|
||||
exit(-1);
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
template<class T>
|
||||
typename Largest_empty_iso_rectangle_2<T>::Iso_rectangle_2
|
||||
Largest_empty_iso_rectangle_2<T>::get_largest_empty_iso_rectangle()
|
||||
|
|
@ -1351,17 +1303,6 @@ Largest_empty_iso_rectangle_2<T>::get_largest_empty_iso_rectangle()
|
|||
return(get_bounding_box());
|
||||
}
|
||||
update();
|
||||
#if defined(TEST)
|
||||
kd_test(Iso_rectangle_2(
|
||||
less_xy_point(left_p.x_part,right_p.x_part) ?
|
||||
left_p.x_part : right_p.x_part,
|
||||
less_xy_point(left_p.x_part,right_p.x_part) ?
|
||||
right_p.x_part : left_p.x_part,
|
||||
less_yx_point(bottom_p.x_part,top_p.x_part) ?
|
||||
bottom_p.y_part : top_p.y_part,
|
||||
less_yx_point(bottom_p.x_part,top_p.x_part) ?
|
||||
top_p.y_part : bottom_p.y_part));
|
||||
#endif
|
||||
|
||||
return(Iso_rectangle_2(
|
||||
less_xy_point(left_p.x_part,right_p.x_part) ?
|
||||
|
|
|
|||
Loading…
Reference in New Issue