Use kernel functors (suggestions from @sloriot)

Co-authored-by: Sebastien Loriot <sloriot.ml@gmail.com>
This commit is contained in:
Mael 2020-07-08 12:39:18 +02:00 committed by GitHub
parent b3dbae08fc
commit f42d19b37e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 6 additions and 6 deletions

View File

@ -172,25 +172,25 @@ template <class K>
inline typename K::Boolean do_intersect(const CGAL::Bbox_3 &aabb, inline typename K::Boolean do_intersect(const CGAL::Bbox_3 &aabb,
const typename K::Tetrahedron_3 &tet, const typename K::Tetrahedron_3 &tet,
const K &k) { const K &k) {
using Tr = CGAL::Triangle_3<K>; typename K::Construct_triangle_3 tr = k.construct_triangle_3_object();
typename K::Boolean result = false; typename K::Boolean result = false;
typename K::Boolean b = false; typename K::Boolean b = false;
b = do_intersect(aabb, Tr(tet[0], tet[1], tet[2]), k); b = do_intersect(aabb, tr(tet[0], tet[1], tet[2]), k);
if (certainly(b)) return b; if (certainly(b)) return b;
if (is_indeterminate(b)) result = b; if (is_indeterminate(b)) result = b;
b = do_intersect(aabb, Tr(tet[1], tet[2], tet[3]), k); b = do_intersect(aabb, tr(tet[1], tet[2], tet[3]), k);
if (certainly(b)) return b; if (certainly(b)) return b;
if (is_indeterminate(b)) result = b; if (is_indeterminate(b)) result = b;
b = do_intersect(aabb, Tr(tet[2], tet[3], tet[0]), k); b = do_intersect(aabb, tr(tet[2], tet[3], tet[0]), k);
if (certainly(b)) return b; if (certainly(b)) return b;
if (is_indeterminate(b)) result = b; if (is_indeterminate(b)) result = b;
b = do_intersect(aabb, Tr(tet[3], tet[0], tet[1]), k); b = do_intersect(aabb, tr(tet[3], tet[0], tet[1]), k);
if (certainly(b)) return b; if (certainly(b)) return b;
if (is_indeterminate(b)) result = b; if (is_indeterminate(b)) result = b;
b = k.has_on_bounded_side_3_object()( b = k.has_on_bounded_side_3_object()(
tet, typename K::Point_3(aabb.xmin(), aabb.ymin(), aabb.zmin())); tet, k.construct_point_3_object()(aabb.xmin(), aabb.ymin(), aabb.zmin()));
if (certainly(b)) return b; if (certainly(b)) return b;
if (is_indeterminate(b)) result = b; if (is_indeterminate(b)) result = b;