mirror of https://github.com/CGAL/cgal
Split_3 + do_overlap
This commit is contained in:
parent
8cc7601d38
commit
62dd84a760
|
|
@ -185,7 +185,71 @@ namespace CGAL {
|
||||||
return non_oriented_equal<SK>(l, la.supporting_line());
|
return non_oriented_equal<SK>(l, la.supporting_line());
|
||||||
}
|
}
|
||||||
|
|
||||||
// TO DO
|
|
||||||
|
template< class SK>
|
||||||
|
inline
|
||||||
|
Sign
|
||||||
|
compute_sign_of_cross_product(const typename SK::Root_of_2 &x1,
|
||||||
|
const typename SK::Root_of_2 &y1,
|
||||||
|
const typename SK::Root_of_2 &z1,
|
||||||
|
const typename SK::Root_of_2 &x2,
|
||||||
|
const typename SK::Root_of_2 &y2,
|
||||||
|
const typename SK::Root_of_2 &z2) {
|
||||||
|
typedef typename SK::Root_of_2 Root_of_2;
|
||||||
|
const Root_of_2 cx = y1 * z2 - z1 * y2;
|
||||||
|
const Root_of_2 cy = z1 * x2 - x1 * z2;
|
||||||
|
const Root_of_2 cz = x1 * y2 - y1 * x2;
|
||||||
|
if(!is_zero(cx)) return sign(cx);
|
||||||
|
if(!is_zero(cy)) return sign(cy);
|
||||||
|
return sign(cz);
|
||||||
|
}
|
||||||
|
|
||||||
|
template< class SK>
|
||||||
|
inline
|
||||||
|
Sign
|
||||||
|
compute_sign_of_cross_product(const typename SK::FT &x1,
|
||||||
|
const typename SK::FT &y1,
|
||||||
|
const typename SK::FT &z1,
|
||||||
|
const typename SK::FT &x2,
|
||||||
|
const typename SK::FT &y2,
|
||||||
|
const typename SK::FT &z2) {
|
||||||
|
typedef typename SK::FT FT;
|
||||||
|
const FT cx = y1 * z2 - z1 * y2;
|
||||||
|
const FT cy = z1 * x2 - x1 * z2;
|
||||||
|
const FT cz = x1 * y2 - y1 * x2;
|
||||||
|
if(!is_zero(cx)) return sign(cx);
|
||||||
|
if(!is_zero(cy)) return sign(cy);
|
||||||
|
return sign(cz);
|
||||||
|
}
|
||||||
|
|
||||||
|
template< class SK>
|
||||||
|
inline
|
||||||
|
Sign
|
||||||
|
compute_sign_of_cross_product(const typename SK::Circular_arc_point_3 &p1,
|
||||||
|
const typename SK::Circular_arc_point_3 &p2,
|
||||||
|
const typename SK::Point_3 &c) {
|
||||||
|
return compute_sign_of_cross_product<SK>(p1.x()-c.x(),
|
||||||
|
p1.y()-c.y(),
|
||||||
|
p1.z()-c.z(),
|
||||||
|
p2.x()-c.x(),
|
||||||
|
p2.y()-c.y(),
|
||||||
|
p2.z()-c.z());
|
||||||
|
}
|
||||||
|
|
||||||
|
template< class SK>
|
||||||
|
inline
|
||||||
|
Sign
|
||||||
|
compute_sign_of_cross_product(const typename SK::Point_3 &p1,
|
||||||
|
const typename SK::Point_3 &p2,
|
||||||
|
const typename SK::Point_3 &c) {
|
||||||
|
return compute_sign_of_cross_product<SK>(p1.x()-c.x(),
|
||||||
|
p1.y()-c.y(),
|
||||||
|
p1.z()-c.z(),
|
||||||
|
p2.x()-c.x(),
|
||||||
|
p2.y()-c.y(),
|
||||||
|
p2.z()-c.z());
|
||||||
|
}
|
||||||
|
|
||||||
template <class SK>
|
template <class SK>
|
||||||
inline
|
inline
|
||||||
bool
|
bool
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue