add CGAL_NTS before sign (bug in CORE, convertion from int to Sign)

This commit is contained in:
Sébastien Loriot 2009-07-08 13:26:57 +00:00
parent cc3c6a31f4
commit 9f6605e383
2 changed files with 17 additions and 17 deletions

View File

@ -36,14 +36,14 @@ namespace CGAL {
inline inline
Sign sign_at( const typename AK::Polynomial_for_spheres_2_3 & equation, Sign sign_at( const typename AK::Polynomial_for_spheres_2_3 & equation,
const typename AK::Root_for_spheres_2_3 &r){ const typename AK::Root_for_spheres_2_3 &r){
return sign(r.evaluate(equation)); return CGAL_NTS sign(r.evaluate(equation));
} }
template < class AK > template < class AK >
inline inline
Sign sign_at(const typename AK::Polynomial_1_3 & equation, Sign sign_at(const typename AK::Polynomial_1_3 & equation,
const typename AK::Root_for_spheres_2_3 &r){ const typename AK::Root_for_spheres_2_3 &r){
return sign(r.evaluate(equation)); return CGAL_NTS sign(r.evaluate(equation));
} }
template < class AK > template < class AK >
@ -247,9 +247,9 @@ namespace CGAL {
const Root_of_2 t2 = make_root_of_2(alpha,FT(1),gama); const Root_of_2 t2 = make_root_of_2(alpha,FT(1),gama);
bool first_t1 = true; bool first_t1 = true;
Sign sign_a1 = static_cast<Sign> (sign(p.a1())); Sign sign_a1 = CGAL_NTS sign(p.a1());
Sign sign_a2 = static_cast<Sign> (sign(p.a2())); Sign sign_a2 = CGAL_NTS sign(p.a2());
Sign sign_a3 = static_cast<Sign> (sign(p.a3())); Sign sign_a3 = CGAL_NTS sign(p.a3());
if(sign_a1 == ZERO) { if(sign_a1 == ZERO) {
if(sign_a2 == ZERO) { if(sign_a2 == ZERO) {
first_t1 = (sign_a3 == POSITIVE); first_t1 = (sign_a3 == POSITIVE);

View File

@ -182,8 +182,8 @@ namespace CGAL {
// It has to be the equation of a diametral circle // It has to be the equation of a diametral circle
CGAL_kernel_precondition((intersect<AK>(p,s))); CGAL_kernel_precondition((intersect<AK>(p,s)));
CGAL_kernel_precondition(sign(p.a() * s.a() + p.b() * s.b() + CGAL_kernel_precondition(CGAL_NTS sign(p.a() * s.a() + p.b() * s.b() +
p.c() * s.c() + p.d()) == ZERO); p.c() * s.c() + p.d()) == ZERO);
CGAL_kernel_precondition(!(is_zero(p.b()) && is_zero(p.c()))); CGAL_kernel_precondition(!(is_zero(p.b()) && is_zero(p.c())));
const FT sqbc = CGAL::square(p.b()) + CGAL::square(p.c()); const FT sqbc = CGAL::square(p.b()) + CGAL::square(p.c());
@ -217,8 +217,8 @@ namespace CGAL {
// It has to be the equation of a diametral circle // It has to be the equation of a diametral circle
CGAL_kernel_precondition((intersect<AK>(p,s))); CGAL_kernel_precondition((intersect<AK>(p,s)));
CGAL_kernel_precondition(sign(p.a() * s.a() + p.b() * s.b() + CGAL_kernel_precondition(CGAL_NTS sign(p.a() * s.a() + p.b() * s.b() +
p.c() * s.c() + p.d()) == ZERO); p.c() * s.c() + p.d()) == ZERO);
CGAL_kernel_precondition(!(is_zero(p.b()) && is_zero(p.c()))); CGAL_kernel_precondition(!(is_zero(p.b()) && is_zero(p.c())));
const FT sqbc = CGAL::square(p.b()) + CGAL::square(p.c()); const FT sqbc = CGAL::square(p.b()) + CGAL::square(p.c());
@ -256,8 +256,8 @@ namespace CGAL {
// It has to be the equation of a diametral circle // It has to be the equation of a diametral circle
CGAL_kernel_precondition((intersect<AK>(p,s))); CGAL_kernel_precondition((intersect<AK>(p,s)));
CGAL_kernel_precondition(sign(p.a() * s.a() + p.b() * s.b() + CGAL_kernel_precondition(CGAL_NTS sign(p.a() * s.a() + p.b() * s.b() +
p.c() * s.c() + p.d()) == ZERO); p.c() * s.c() + p.d()) == ZERO);
CGAL_kernel_precondition(!(is_zero(p.a()) && is_zero(p.c()))); CGAL_kernel_precondition(!(is_zero(p.a()) && is_zero(p.c())));
const FT sqac = CGAL::square(p.a()) + CGAL::square(p.c()); const FT sqac = CGAL::square(p.a()) + CGAL::square(p.c());
@ -297,8 +297,8 @@ namespace CGAL {
// It has to be the equation of a diametral circle // It has to be the equation of a diametral circle
CGAL_kernel_precondition((intersect<AK>(p,s))); CGAL_kernel_precondition((intersect<AK>(p,s)));
CGAL_kernel_precondition(sign(p.a() * s.a() + p.b() * s.b() + CGAL_kernel_precondition(CGAL_NTS sign(p.a() * s.a() + p.b() * s.b() +
p.c() * s.c() + p.d()) == ZERO); p.c() * s.c() + p.d()) == ZERO);
CGAL_kernel_precondition(!(is_zero(p.a()) && is_zero(p.c()))); CGAL_kernel_precondition(!(is_zero(p.a()) && is_zero(p.c())));
const FT sqac = CGAL::square(p.a()) + CGAL::square(p.c()); const FT sqac = CGAL::square(p.a()) + CGAL::square(p.c());
@ -341,8 +341,8 @@ namespace CGAL {
// It has to be the equation of a diametral circle // It has to be the equation of a diametral circle
CGAL_kernel_precondition((intersect<AK>(p,s))); CGAL_kernel_precondition((intersect<AK>(p,s)));
CGAL_kernel_precondition(sign(p.a() * s.a() + p.b() * s.b() + CGAL_kernel_precondition(CGAL_NTS sign(p.a() * s.a() + p.b() * s.b() +
p.c() * s.c() + p.d()) == ZERO); p.c() * s.c() + p.d()) == ZERO);
CGAL_kernel_precondition(!(is_zero(p.a()) && is_zero(p.b()))); CGAL_kernel_precondition(!(is_zero(p.a()) && is_zero(p.b())));
const FT sqab = CGAL::square(p.a()) + CGAL::square(p.b()); const FT sqab = CGAL::square(p.a()) + CGAL::square(p.b());
@ -394,8 +394,8 @@ namespace CGAL {
// It has to be the equation of a diametral circle // It has to be the equation of a diametral circle
CGAL_kernel_precondition((intersect<AK>(p,s))); CGAL_kernel_precondition((intersect<AK>(p,s)));
CGAL_kernel_precondition(sign(p.a() * s.a() + p.b() * s.b() + CGAL_kernel_precondition(CGAL_NTS sign(p.a() * s.a() + p.b() * s.b() +
p.c() * s.c() + p.d()) == ZERO); p.c() * s.c() + p.d()) == ZERO);
CGAL_kernel_precondition(!(is_zero(p.a()) && is_zero(p.b()))); CGAL_kernel_precondition(!(is_zero(p.a()) && is_zero(p.b())));
const FT sqab = CGAL::square(p.a()) + CGAL::square(p.b()); const FT sqab = CGAL::square(p.a()) + CGAL::square(p.b());