mirror of https://github.com/CGAL/cgal
Don't test on two files but on random points again
This commit is contained in:
parent
88add6bc7b
commit
ce5472de15
|
|
@ -47,20 +47,20 @@ public:
|
|||
|
||||
static void test_insert_rnd_then_remove_all (unsigned pt_count,
|
||||
unsigned seed,
|
||||
const std::string& path)
|
||||
const std::string& /* path */)
|
||||
{
|
||||
std::cout << "--- test_insert_rnd (" << pt_count << ", " << seed << ')' << std::endl;
|
||||
|
||||
CGAL::Random random(seed);
|
||||
// typedef CGAL::Creator_uniform_3<double, Point_3> Creator;
|
||||
// CGAL::Random_points_in_cube_3<Point_3, Creator> in_cube(0.5, random);
|
||||
typedef CGAL::Creator_uniform_3<double, Point_3> Creator;
|
||||
CGAL::Random_points_in_cube_3<Point_3, Creator> in_cube(0.5, random);
|
||||
|
||||
Iso_cuboid iso_cuboid(-0.5, -0.5, -0.5, 0.5, 0.5, 0.5);
|
||||
P3RT3 p3rt3(iso_cuboid);
|
||||
|
||||
std::ofstream stream("p3rt3_ir_point_set");
|
||||
assert(stream);
|
||||
std::ifstream input_stream(path.c_str());
|
||||
//std::ofstream stream("p3rt3_ir_point_set");
|
||||
//assert(stream);
|
||||
//std::ifstream input_stream(path.c_str());
|
||||
|
||||
std::vector<Weighted_point_3> insert_set;
|
||||
insert_set.reserve(pt_count);
|
||||
|
|
@ -70,12 +70,12 @@ public:
|
|||
std::cout << "-- insert" << std::endl;
|
||||
for (unsigned cnt = 1; cnt <= pt_count; ++cnt)
|
||||
{
|
||||
// Weighted_point_3 p(*in_cube++, random.get_double(0., 0.015625));
|
||||
Weighted_point_3 p(*in_cube++, random.get_double(0., 0.015625));
|
||||
// std::cout << cnt << " : " << p << std::endl;
|
||||
Weighted_point_3 p;
|
||||
input_stream >> p;
|
||||
assert(p.weight() < 0.015625);
|
||||
stream << p << std::endl;
|
||||
// Weighted_point_3 p;
|
||||
// input_stream >> p;
|
||||
// assert(p.weight() < 0.015625);
|
||||
// stream << p << std::endl;
|
||||
|
||||
std::size_t hidden_point_count = 0;
|
||||
for (Cell_iterator iter = p3rt3.cells_begin(), end_iter = p3rt3.cells_end(); iter != end_iter; ++iter)
|
||||
|
|
@ -100,7 +100,7 @@ public:
|
|||
insert_set.push_back(p);
|
||||
}
|
||||
|
||||
stream.close();
|
||||
//stream.close();
|
||||
|
||||
assert(p3rt3.is_valid());
|
||||
|
||||
|
|
@ -138,7 +138,6 @@ public:
|
|||
{
|
||||
////// Iso_cuboid unitaire -> 0 <= weight < 0.015625
|
||||
test_insert_rnd_then_remove_all(800, 7, "data/p3rt3_point_set__s7_n800");
|
||||
test_insert_rnd_then_remove_all(800, 12, "data/p3rt3_point_set__s12_n800");
|
||||
}
|
||||
};
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue