mirror of https://github.com/CGAL/cgal
do not use default constructed kernel
This commit is contained in:
parent
88c6381e00
commit
f34d1e3545
|
|
@ -123,22 +123,20 @@ public:
|
||||||
void operator() (RandomAccessIterator begin, RandomAccessIterator end) const
|
void operator() (RandomAccessIterator begin, RandomAccessIterator end) const
|
||||||
{
|
{
|
||||||
//Bbox_2 box=bbox_2(begin, end); BUG: WE NEED TO FIX THIS
|
//Bbox_2 box=bbox_2(begin, end); BUG: WE NEED TO FIX THIS
|
||||||
|
double xmin=to_double(_k.compute_x_2_object()(*begin)),
|
||||||
K k;
|
ymin=to_double(_k.compute_y_2_object()(*begin)),
|
||||||
double xmin=to_double(k.compute_x_2_object()(*begin)),
|
|
||||||
ymin=to_double(k.compute_y_2_object()(*begin)),
|
|
||||||
xmax=xmin,
|
xmax=xmin,
|
||||||
ymax=ymin;
|
ymax=ymin;
|
||||||
|
|
||||||
for(RandomAccessIterator it=begin+1; it<end; ++it){
|
for(RandomAccessIterator it=begin+1; it<end; ++it){
|
||||||
if ( to_double(k.compute_x_2_object()(*it)) < xmin)
|
if ( to_double(_k.compute_x_2_object()(*it)) < xmin)
|
||||||
xmin = to_double(k.compute_x_2_object()(*it));
|
xmin = to_double(_k.compute_x_2_object()(*it));
|
||||||
if ( to_double(k.compute_y_2_object()(*it)) < ymin)
|
if ( to_double(_k.compute_y_2_object()(*it)) < ymin)
|
||||||
ymin = to_double(k.compute_y_2_object()(*it));
|
ymin = to_double(_k.compute_y_2_object()(*it));
|
||||||
if ( to_double(k.compute_x_2_object()(*it)) > xmax)
|
if ( to_double(_k.compute_x_2_object()(*it)) > xmax)
|
||||||
xmax = to_double(k.compute_x_2_object()(*it));
|
xmax = to_double(_k.compute_x_2_object()(*it));
|
||||||
if ( to_double(k.compute_y_2_object()(*it)) > ymax)
|
if ( to_double(_k.compute_y_2_object()(*it)) > ymax)
|
||||||
ymax = to_double(k.compute_y_2_object()(*it));
|
ymax = to_double(_k.compute_y_2_object()(*it));
|
||||||
}
|
}
|
||||||
|
|
||||||
sort <0, false, false> (begin, end, xmin, ymin, xmax, ymax);
|
sort <0, false, false> (begin, end, xmin, ymin, xmax, ymax);
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue