fix compilation issues and warnings

This commit is contained in:
Sébastien Loriot 2015-04-15 09:03:14 +02:00
parent 7a54cf0b68
commit 3c66842b77
4 changed files with 16 additions and 15 deletions

View File

@ -22,7 +22,7 @@ int main ()
v.reserve(size); v.reserve(size);
CGAL::Random_points_on_sphere_3<Point> unit_sphere(1.0, random); // generate points CGAL::Random_points_on_sphere_3<Point> unit_sphere(1.0, random); // generate points
for (int i = 0; i < size; ++i) v.push_back(*unit_sphere++); for (std::size_t i = 0; i < size; ++i) v.push_back(*unit_sphere++);
CGAL::hilbert_sort_on_sphere(v.begin(), v.end()); // sort CGAL::hilbert_sort_on_sphere(v.begin(), v.end()); // sort
@ -38,7 +38,7 @@ int main ()
Vector trans = Vector(3,4,5); Vector trans = Vector(3,4,5);
Sphere sphere = Sphere(CGAL::ORIGIN + trans, 4); Sphere sphere = Sphere(CGAL::ORIGIN + trans, 4);
CGAL::Random_points_on_sphere_3<Point> given_sphere(2.0, random); // generate points CGAL::Random_points_on_sphere_3<Point> given_sphere(2.0, random); // generate points
for (int i = 0; i < size; ++i) v.push_back(*given_sphere++ + trans); for (std::size_t i = 0; i < size; ++i) v.push_back(*given_sphere++ + trans);
CGAL::hilbert_sort_on_sphere(v.begin(), v.end(), // sort CGAL::hilbert_sort_on_sphere(v.begin(), v.end(), // sort
sphere.squared_radius(), sphere.center()); sphere.squared_radius(), sphere.center());

View File

@ -22,7 +22,7 @@ int main ()
v.reserve(size); v.reserve(size);
CGAL::Random_points_on_sphere_3<Point> unit_sphere(1.0, random); // generate points CGAL::Random_points_on_sphere_3<Point> unit_sphere(1.0, random); // generate points
for (int i = 0; i < size; ++i) v.push_back(*unit_sphere++); for (std::size_t i = 0; i < size; ++i) v.push_back(*unit_sphere++);
CGAL::spatial_sort_on_sphere(v.begin(), v.end()); // sort CGAL::spatial_sort_on_sphere(v.begin(), v.end()); // sort
@ -38,7 +38,7 @@ int main ()
Vector trans = Vector(3,4,5); Vector trans = Vector(3,4,5);
Sphere sphere = Sphere(CGAL::ORIGIN + trans, 4); Sphere sphere = Sphere(CGAL::ORIGIN + trans, 4);
CGAL::Random_points_on_sphere_3<Point> given_sphere(2.0, random); // generate points CGAL::Random_points_on_sphere_3<Point> given_sphere(2.0, random); // generate points
for (int i = 0; i < size; ++i) v.push_back(*given_sphere++ + trans); for (std::size_t i = 0; i < size; ++i) v.push_back(*given_sphere++ + trans);
CGAL::spatial_sort_on_sphere(v.begin(), v.end(), // sort CGAL::spatial_sort_on_sphere(v.begin(), v.end(), // sort
sphere.squared_radius(), sphere.center()); sphere.squared_radius(), sphere.center());

View File

@ -63,13 +63,14 @@ public:
double sq_r = 1.0, double sq_r = 1.0,
const Point_3 &p = Point_3(0,0,0), const Point_3 &p = Point_3(0,0,0),
std::ptrdiff_t limit=1) std::ptrdiff_t limit=1)
: _k(k), _p(p), _sq_r(sq_r), : _hs_1_object(Face_1_traits_3(),limit),
_hs_1_object(Face_1_traits_3(),limit),
_hs_2_object(Face_2_traits_3(),limit), _hs_2_object(Face_2_traits_3(),limit),
_hs_3_object(Face_3_traits_3(),limit), _hs_3_object(Face_3_traits_3(),limit),
_hs_4_object(Face_4_traits_3(),limit), _hs_4_object(Face_4_traits_3(),limit),
_hs_5_object(Face_5_traits_3(),limit), _hs_5_object(Face_5_traits_3(),limit),
_hs_6_object(Face_6_traits_3(),limit) { _hs_6_object(Face_6_traits_3(),limit),
_k(k), _p(p), _sq_r(sq_r)
{
CGAL_precondition( sq_r > 0 ); CGAL_precondition( sq_r > 0 );
} }

View File

@ -247,18 +247,18 @@ struct Transform_coordinates_traits_3 {
typedef Transform_coordinates_traits_3<R,x,y,z,ord> Traits; typedef Transform_coordinates_traits_3<R,x,y,z,ord> Traits;
typedef R Rp; typedef R Rp;
typedef typename Rp::Point_3 Point_2; typedef typename Rp::Point_3 Point_2;
typedef Less_x_2<R,opt> Less_x_2; typedef Less_x_2<R,opt> Less_x;
typedef Less_y_2<R,opt> Less_y_2; typedef Less_y_2<R,opt> Less_y;
typedef Compute_x_2<R,opt> Compute_x_2; typedef Compute_x_2<R,opt> Compute_x;
typedef Compute_y_2<R,opt> Compute_y_2; typedef Compute_y_2<R,opt> Compute_y;
Transform_coordinates_traits_3(){} Transform_coordinates_traits_3(){}
Transform_coordinates_traits_3(const Transform_coordinates_traits_3&){} Transform_coordinates_traits_3(const Transform_coordinates_traits_3&){}
Less_x_2 less_x_2_object() const { return Less_x_2(); } Less_x less_x_2_object() const { return Less_x(); }
Less_y_2 less_y_2_object() const { return Less_y_2(); } Less_y less_y_2_object() const { return Less_y(); }
Compute_x_2 compute_x_2_object() const { return Compute_x_2(); } Compute_x compute_x_2_object() const { return Compute_x(); }
Compute_y_2 compute_y_2_object() const { return Compute_y_2(); } Compute_y compute_y_2_object() const { return Compute_y(); }
}; };