fix compilation of Mesh_2 with Homogeneous kernel

the example mesh_optimization.cpp fails during refinement
with Kernel = CGAL::Homogeneous<double>
This commit is contained in:
Jane Tournois 2021-09-10 11:28:13 +02:00
parent 7e3af5cbda
commit 0ac4bf6493
2 changed files with 3 additions and 3 deletions

View File

@ -352,7 +352,7 @@ private:
sum += CGAL::sqrt(*it);
#ifdef CGAL_MESH_2_OPTIMIZER_VERBOSE
sum_moves_ = sum/big_moves_.size();
sum_moves_ = sum/FT(big_moves_.size());
#endif
return ( sum/FT(big_moves_.size()) < convergence_ratio_ );

View File

@ -169,7 +169,7 @@ private:
typename Tr::Edge_circulator end = ec;
FT sum_len(0.);
FT nb = 0.;
unsigned int nb = 0;
do
{
Edge e = *ec;
@ -187,7 +187,7 @@ private:
while(++ec != end);
// nb == 0 could happen if there is an isolated point.
if( 0 != nb )
return sum_len/nb;
return sum_len/FT(nb);
else
// Use outside faces to compute size of point
return 1.;//todo