Use CGAL_make_vector()

This commit is contained in:
Sylvain Pion 2007-04-02 20:19:14 +00:00
parent 667fc845ef
commit ae242392dc
4 changed files with 6 additions and 12 deletions

View File

@ -198,7 +198,7 @@ public:
{
int n = number_of_vertices();
std::vector<Point> points (first, last);
std::vector<Point> points CGAL_make_vector(first, last);
std::random_shuffle (points.begin(), points.end());
spatial_sort (points.begin(), points.end(), geom_traits());

View File

@ -136,7 +136,7 @@ public:
{
int n = number_of_vertices();
std::vector<Weighted_point> points (first, last);
std::vector<Weighted_point> points CGAL_make_vector(first, last);
std::random_shuffle (points.begin(), points.end());
spatial_sort (points.begin(), points.end(), geom_traits());

View File

@ -576,7 +576,7 @@ public:
{
int n = number_of_vertices();
std::vector<Point> points (first, last);
std::vector<Point> points CGAL_make_vector(first, last);
std::random_shuffle (points.begin(), points.end());
spatial_sort (points.begin(), points.end(), geom_traits());
@ -2945,14 +2945,8 @@ operator==(const Triangulation_3<GT, Tds> &t1,
if (dim == 1) {
// It's enough to test that the points are the same,
// since the triangulation is uniquely defined in this case.
#ifndef CGAL_CFG_MISSING_TEMPLATE_VECTOR_CONSTRUCTORS_BUG
std::vector<Point> V1(t1.points_begin(), t1.points_end());
std::vector<Point> V2(t2.points_begin(), t2.points_end());
#else
std::vector<Point> V1, V2;
std::copy(t1.points_begin(), t1.points_end(), std::back_inserter(V1));
std::copy(t2.points_begin(), t2.points_end(), std::back_inserter(V2));
#endif
std::vector<Point> V1 CGAL_make_vector(t1.points_begin(), t1.points_end());
std::vector<Point> V2 CGAL_make_vector(t2.points_begin(), t2.points_end());
std::sort(V1.begin(), V1.end(),
compose(Is_negative<int>(),// implicit conversion of CGAL::Sign
t1.geom_traits().compare_xyz_3_object()));

View File

@ -101,7 +101,7 @@ public:
{
int n = number_of_vertices();
std::vector<Point> points (first, last);
std::vector<Point> points CGAL_make_vector(first, last);
std::random_shuffle (points.begin(), points.end());
spatial_sort (points.begin(), points.end(), geom_traits());