mirror of https://github.com/CGAL/cgal
Slight optimization
This commit is contained in:
parent
d8954256f1
commit
f11efea26a
|
|
@ -192,8 +192,8 @@ public:
|
||||||
std::random_shuffle (points.begin(), points.end());
|
std::random_shuffle (points.begin(), points.end());
|
||||||
spatial_sort (points.begin(), points.end(), geom_traits());
|
spatial_sort (points.begin(), points.end(), geom_traits());
|
||||||
Face_handle f;
|
Face_handle f;
|
||||||
for (typename std::vector<Point>::const_iterator p = points.begin();
|
for (typename std::vector<Point>::const_iterator p = points.begin(), end = points.end();
|
||||||
p != points.end(); ++p)
|
p != end; ++p)
|
||||||
f = insert (*p, f)->face();
|
f = insert (*p, f)->face();
|
||||||
|
|
||||||
return number_of_vertices() - n;
|
return number_of_vertices() - n;
|
||||||
|
|
|
||||||
|
|
@ -255,8 +255,8 @@ public:
|
||||||
CGAL::spatial_sort (points.begin(), points.end(), geom_traits());
|
CGAL::spatial_sort (points.begin(), points.end(), geom_traits());
|
||||||
|
|
||||||
Face_handle hint;
|
Face_handle hint;
|
||||||
for (typename std::vector<Point>::const_iterator p = points.begin();
|
for (typename std::vector<Point>::const_iterator p = points.begin(), end = points.end();
|
||||||
p != points.end(); ++p)
|
p != end; ++p)
|
||||||
hint = insert (*p, hint)->face();
|
hint = insert (*p, hint)->face();
|
||||||
|
|
||||||
return number_of_vertices() - n;
|
return number_of_vertices() - n;
|
||||||
|
|
|
||||||
|
|
@ -210,8 +210,8 @@ public:
|
||||||
spatial_sort (points.begin(), points.end(), geom_traits());
|
spatial_sort (points.begin(), points.end(), geom_traits());
|
||||||
|
|
||||||
Face_handle hint;
|
Face_handle hint;
|
||||||
for (typename std::vector<Point>::const_iterator p = points.begin();
|
for (typename std::vector<Point>::const_iterator p = points.begin(), end = points.end();
|
||||||
p != points.end(); ++p)
|
p != end; ++p)
|
||||||
hint = insert (*p, hint)->face();
|
hint = insert (*p, hint)->face();
|
||||||
|
|
||||||
return number_of_vertices() - n;
|
return number_of_vertices() - n;
|
||||||
|
|
|
||||||
|
|
@ -164,8 +164,8 @@ public:
|
||||||
std::random_shuffle (points.begin(), points.end());
|
std::random_shuffle (points.begin(), points.end());
|
||||||
spatial_sort (points.begin(), points.end(), geom_traits());
|
spatial_sort (points.begin(), points.end(), geom_traits());
|
||||||
Face_handle f;
|
Face_handle f;
|
||||||
for (typename std::vector<Point>::const_iterator p = points.begin();
|
for (typename std::vector<Point>::const_iterator p = points.begin(), end = points.end();
|
||||||
p != points.end(); ++p)
|
p != end; ++p)
|
||||||
f = insert (*p, f)->face();
|
f = insert (*p, f)->face();
|
||||||
|
|
||||||
return this->number_of_vertices() - n;
|
return this->number_of_vertices() - n;
|
||||||
|
|
|
||||||
|
|
@ -336,8 +336,9 @@ public:
|
||||||
spatial_sort (points.begin(), points.end(), geom_traits());
|
spatial_sort (points.begin(), points.end(), geom_traits());
|
||||||
|
|
||||||
Face_handle hint;
|
Face_handle hint;
|
||||||
for (typename std::vector<Weighted_point>::const_iterator p = points.begin();
|
for (typename std::vector<Weighted_point>::const_iterator p = points.begin(),
|
||||||
p != points.end(); ++p)
|
end = points.end();
|
||||||
|
p != end; ++p)
|
||||||
hint = insert (*p, hint)->face();
|
hint = insert (*p, hint)->face();
|
||||||
|
|
||||||
return number_of_vertices() - n;
|
return number_of_vertices() - n;
|
||||||
|
|
|
||||||
|
|
@ -443,8 +443,8 @@ int insert(InputIterator first, InputIterator last)
|
||||||
std::random_shuffle (points.begin(), points.end());
|
std::random_shuffle (points.begin(), points.end());
|
||||||
spatial_sort (points.begin(), points.end(), geom_traits());
|
spatial_sort (points.begin(), points.end(), geom_traits());
|
||||||
Face_handle f;
|
Face_handle f;
|
||||||
for (typename std::vector<Point>::const_iterator p = points.begin();
|
for (typename std::vector<Point>::const_iterator p = points.begin(), end = points.end();
|
||||||
p != points.end(); ++p)
|
p != end; ++p)
|
||||||
f = insert (*p, f)->face();
|
f = insert (*p, f)->face();
|
||||||
|
|
||||||
return number_of_vertices() - n;
|
return number_of_vertices() - n;
|
||||||
|
|
|
||||||
|
|
@ -105,8 +105,8 @@ public:
|
||||||
CGAL::spatial_sort (points.begin(), points.end(), geom_traits());
|
CGAL::spatial_sort (points.begin(), points.end(), geom_traits());
|
||||||
|
|
||||||
Face_handle hint;
|
Face_handle hint;
|
||||||
for (typename std::vector<Point>::const_iterator p = points.begin();
|
for (typename std::vector<Point>::const_iterator p = points.begin(), end = points.end();
|
||||||
p != points.end(); ++p)
|
p != end; ++p)
|
||||||
hint = insert (*p, hint)->face();
|
hint = insert (*p, hint)->face();
|
||||||
|
|
||||||
return this->number_of_vertices() - n;
|
return this->number_of_vertices() - n;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue