diff --git a/Bounding_volumes/test/Bounding_volumes/Approximate_min_ellipsoid_d.cpp b/Bounding_volumes/test/Bounding_volumes/Approximate_min_ellipsoid_d.cpp index 6c46f227d17..28a9525f6a9 100644 --- a/Bounding_volumes/test/Bounding_volumes/Approximate_min_ellipsoid_d.cpp +++ b/Bounding_volumes/test/Bounding_volumes/Approximate_min_ellipsoid_d.cpp @@ -15,6 +15,7 @@ #include #include #include +#include #include #include @@ -148,7 +149,7 @@ void simple_test(int n, int d, int multiplicity, double eps) Point_list P; typedef typename is_d_dimensional::value is_d; add_random_points(n, d, multiplicity, P, is_d()); - std::random_shuffle(P.begin(), P.end()); + CGAL::random_shuffle(P.begin(), P.end()); // compute minellipsoid: Traits tco; diff --git a/Generator/examples/Generator/random_degenerate_point_set.cpp b/Generator/examples/Generator/random_degenerate_point_set.cpp index d1bc4325cf9..88829b9bddb 100644 --- a/Generator/examples/Generator/random_degenerate_point_set.cpp +++ b/Generator/examples/Generator/random_degenerate_point_set.cpp @@ -40,7 +40,7 @@ int main() { // Use a random permutation to hide the creation history // of the point set. - std::random_shuffle( points.begin(), points.end(), get_default_random()); + CGAL::random_shuffle( points.begin(), points.end()); // Check range of values. for ( Vector::iterator i = points.begin(); i != points.end(); i++){ diff --git a/Generator/test/Generator/test_generators.cpp b/Generator/test/Generator/test_generators.cpp index e2c2598b5a8..360c4173f00 100644 --- a/Generator/test/Generator/test_generators.cpp +++ b/Generator/test/Generator/test_generators.cpp @@ -97,7 +97,7 @@ void test_point_generators_2() { perturb_points_2( i1, i2, 10.0); // Create a random permutation. - std::random_shuffle( points.begin(), points.end(), get_default_random()); + CGAL::random_shuffle( points.begin(), points.end(), get_default_random()); assert( points.size() == 1000); for ( std::vector::iterator i = points.begin(); diff --git a/Interval_skip_list/examples/Interval_skip_list/intervals.cpp b/Interval_skip_list/examples/Interval_skip_list/intervals.cpp index 0a62f10d395..aa28ead654a 100644 --- a/Interval_skip_list/examples/Interval_skip_list/intervals.cpp +++ b/Interval_skip_list/examples/Interval_skip_list/intervals.cpp @@ -1,5 +1,6 @@ #include #include +#include #include #include #include @@ -19,7 +20,7 @@ int main() for(i = 0; i < n; i++) { intervals[i] = Interval(i, i+d); } - std::random_shuffle(intervals.begin(), intervals.end()); + CGAL::random_shuffle(intervals.begin(), intervals.end()); isl.insert(intervals.begin(), intervals.end()); diff --git a/Interval_skip_list/test/Interval_skip_list/main.cpp b/Interval_skip_list/test/Interval_skip_list/main.cpp index 9002b74807a..3a6343718fa 100644 --- a/Interval_skip_list/test/Interval_skip_list/main.cpp +++ b/Interval_skip_list/test/Interval_skip_list/main.cpp @@ -1,5 +1,7 @@ #include #include +#include + #include #include #include @@ -20,7 +22,7 @@ fct() for(i = 0; i < n; i++) { intervals[i] = Interval(i,i+d); } - std::random_shuffle(intervals.begin(), intervals.end()); + CGAL::random_shuffle(intervals.begin(), intervals.end()); for(i = 0; i < n; i++) { isl.insert(intervals[i]); diff --git a/Periodic_2_triangulation_2/test/Periodic_2_triangulation_2/test_p2t2_performance_gredner.cpp b/Periodic_2_triangulation_2/test/Periodic_2_triangulation_2/test_p2t2_performance_gredner.cpp index 212f0306e20..b98e512a2ff 100644 --- a/Periodic_2_triangulation_2/test/Periodic_2_triangulation_2/test_p2t2_performance_gredner.cpp +++ b/Periodic_2_triangulation_2/test/Periodic_2_triangulation_2/test_p2t2_performance_gredner.cpp @@ -19,7 +19,7 @@ int main() #include #include -#include +#include const bool pre_run = false; const bool do_remove = true; @@ -63,7 +63,7 @@ void test(const std::vector &input, T &t) vhs.push_back(it); } - std::random_shuffle(vhs.begin(), vhs.end()); + CGAL::random_shuffle(vhs.begin(), vhs.end()); vhs.resize(vhs.size() / 2); for (size_t i = 0; i < vhs.size(); ++i) t.remove(vhs[i]); diff --git a/Periodic_3_triangulation_3/demo/Periodic_3_triangulation_3/Scene.cpp b/Periodic_3_triangulation_3/demo/Periodic_3_triangulation_3/Scene.cpp index 31b3bd81bfe..03f2a75013c 100644 --- a/Periodic_3_triangulation_3/demo/Periodic_3_triangulation_3/Scene.cpp +++ b/Periodic_3_triangulation_3/demo/Periodic_3_triangulation_3/Scene.cpp @@ -972,7 +972,7 @@ void Scene::load_points(const QString& fileName) { std::copy(std::istream_iterator(ifs), std::istream_iterator(), std::back_inserter(points)); - std::random_shuffle(points.begin(), points.end()); + CGAL::random_shuffle(points.begin(), points.end()); p3dt.insert(points.begin(), points.end()); QString snv; diff --git a/Periodic_3_triangulation_3/demo/Periodic_3_triangulation_3/Scene_utils.h b/Periodic_3_triangulation_3/demo/Periodic_3_triangulation_3/Scene_utils.h index a56a66ae20e..57b73291b68 100644 --- a/Periodic_3_triangulation_3/demo/Periodic_3_triangulation_3/Scene_utils.h +++ b/Periodic_3_triangulation_3/demo/Periodic_3_triangulation_3/Scene_utils.h @@ -6,6 +6,7 @@ #include #include +#include // Making available the Periodic_3_Delaunay_triangulation_3 to be // drawn in the Scene. diff --git a/Polygon_mesh_processing/test/Polygon_mesh_processing/orient_polygon_soup_test.cpp b/Polygon_mesh_processing/test/Polygon_mesh_processing/orient_polygon_soup_test.cpp index bab8959187c..587279df019 100644 --- a/Polygon_mesh_processing/test/Polygon_mesh_processing/orient_polygon_soup_test.cpp +++ b/Polygon_mesh_processing/test/Polygon_mesh_processing/orient_polygon_soup_test.cpp @@ -9,6 +9,7 @@ #include #include +#include #include #include @@ -86,7 +87,7 @@ void shuffle_off(const char* fname_in, const char* fname_out) for (int k=0;k> indices[k]; - std::random_shuffle(indices.begin(), indices.end()); + CGAL::random_shuffle(indices.begin(), indices.end()); output << n; for (int k=0;k #include #include +#include #include #include @@ -451,9 +452,9 @@ void Scene_points_with_normal_item_priv::compute_normals_and_vertices() const colors_points.resize(0); //Shuffle container to allow quick display random points - std::random_shuffle (m_points->begin(), m_points->first_selected()); + CGAL::random_shuffle (m_points->begin(), m_points->first_selected()); if (m_points->nb_selected_points() != 0) - std::random_shuffle (m_points->first_selected(), m_points->end()); + CGAL::random_shuffle (m_points->first_selected(), m_points->end()); //if item has normals, points will be one point out of two in the lines data. //else points will be lines and lines discarded. double average_spacing = 0; diff --git a/Random_numbers/test/Random_numbers/test_Random.cpp b/Random_numbers/test/Random_numbers/test_Random.cpp index ae46b8ee517..44efa68a4af 100644 --- a/Random_numbers/test/Random_numbers/test_Random.cpp +++ b/Random_numbers/test/Random_numbers/test_Random.cpp @@ -22,6 +22,7 @@ // ============================================================================ #include +#include #include #include #include @@ -160,7 +161,7 @@ main() std::vector numbers; numbers.push_back(1); - std::random_shuffle(numbers.begin(), numbers.end(), CGAL::get_default_random()); + CGAL::random_shuffle(numbers.begin(), numbers.end(), CGAL::get_default_random()); return( 0); } diff --git a/STL_Extension/test/STL_Extension/test_Modifiable_priority_queue.cpp b/STL_Extension/test/STL_Extension/test_Modifiable_priority_queue.cpp index 9df96afa513..7a99aa480f0 100644 --- a/STL_Extension/test/STL_Extension/test_Modifiable_priority_queue.cpp +++ b/STL_Extension/test/STL_Extension/test_Modifiable_priority_queue.cpp @@ -1,4 +1,5 @@ #include +#include #include #include #include @@ -127,7 +128,7 @@ int main() //testing correctness of the order int array[10] = {0,1,2,3,4,5,6,7,8,9}; - std::random_shuffle(array,array+10); + CGAL::random_shuffle(array,array+10); data.clear(); data.reserve(10); for (int i=0;i<10;++i){ diff --git a/Triangulation/test/Triangulation/test_torture.cpp b/Triangulation/test/Triangulation/test_torture.cpp index d75b560791a..99394c71241 100644 --- a/Triangulation/test/Triangulation/test_torture.cpp +++ b/Triangulation/test/Triangulation/test_torture.cpp @@ -96,7 +96,7 @@ void test(const int D, const int d, const int N, bool no_transform) assert( 2 * dc.number_of_vertices() == dc.number_of_full_cells() + 2 ); if( dc.current_dimension() > 3 ) { - std::random_shuffle(points.begin(), points.end()); + CGAL::random_shuffle(points.begin(), points.end()); if (points.size() > 100) points.resize(100); } diff --git a/Triangulation_3/demo/Triangulation_3_Geomview_demos/Triangulation_3_remove_demo.cpp b/Triangulation_3/demo/Triangulation_3_Geomview_demos/Triangulation_3_remove_demo.cpp index 6c5380de8ce..91b945c37f7 100644 --- a/Triangulation_3/demo/Triangulation_3_Geomview_demos/Triangulation_3_remove_demo.cpp +++ b/Triangulation_3/demo/Triangulation_3_Geomview_demos/Triangulation_3_remove_demo.cpp @@ -130,7 +130,7 @@ int main() std::cout <<" Removing vertices in random order" << std::endl; - std::random_shuffle(V.begin(), V.end()); + CGAL::random_shuffle(V.begin(), V.end()); for (i=0; i<125; ++i) { T.remove(V[i]);