From bc3e8fa2358ec7a57fcc77870aa0697890c448ba Mon Sep 17 00:00:00 2001 From: Sven Oesau Date: Thu, 21 Mar 2024 08:17:47 +0100 Subject: [PATCH] removed type wrapper added Ray/Vector types in AABB_traits_2/3 --- AABB_tree/include/CGAL/AABB_traits_2.h | 3 ++- AABB_tree/include/CGAL/AABB_traits_3.h | 3 ++- .../internal/AABB_ray_intersection.h | 21 ++----------------- 3 files changed, 6 insertions(+), 21 deletions(-) diff --git a/AABB_tree/include/CGAL/AABB_traits_2.h b/AABB_tree/include/CGAL/AABB_traits_2.h index 2d6e366f36b..6300d4188bf 100644 --- a/AABB_tree/include/CGAL/AABB_traits_2.h +++ b/AABB_tree/include/CGAL/AABB_traits_2.h @@ -47,10 +47,11 @@ struct AABB_traits_intersection_base_2{}; template struct AABB_traits_intersection_base_2{ typedef typename GeomTraits::Ray_2 Ray_2; + typedef typename GeomTraits::Ray_2 Ray; typedef typename GeomTraits::Point_2 Point_2; typedef typename GeomTraits::Point_2 Point; - typedef typename GeomTraits::Ray_2 Ray; typedef typename GeomTraits::Vector_2 Vector_2; + typedef typename GeomTraits::Vector_2 Vector; typedef typename GeomTraits::FT FT; typedef typename GeomTraits::Cartesian_const_iterator_2 Cartesian_const_iterator_2; typedef typename GeomTraits::Construct_cartesian_const_iterator_2 Construct_cartesian_const_iterator_2; diff --git a/AABB_tree/include/CGAL/AABB_traits_3.h b/AABB_tree/include/CGAL/AABB_traits_3.h index 5614b484ad4..9e9499b5971 100644 --- a/AABB_tree/include/CGAL/AABB_traits_3.h +++ b/AABB_tree/include/CGAL/AABB_traits_3.h @@ -70,10 +70,11 @@ struct AABB_traits_intersection_base{}; template struct AABB_traits_intersection_base{ typedef typename GeomTraits::Ray_3 Ray_3; + typedef typename GeomTraits::Ray_3 Ray; typedef typename GeomTraits::Point_3 Point_3; typedef typename GeomTraits::Point_3 Point; - typedef typename GeomTraits::Ray_3 Ray; typedef typename GeomTraits::Vector_3 Vector_3; + typedef typename GeomTraits::Vector_3 Vector; typedef typename GeomTraits::FT FT; typedef typename GeomTraits::Cartesian_const_iterator_3 Cartesian_const_iterator_3; typedef typename GeomTraits::Construct_cartesian_const_iterator_3 Construct_cartesian_const_iterator_3; diff --git a/AABB_tree/include/CGAL/AABB_tree/internal/AABB_ray_intersection.h b/AABB_tree/include/CGAL/AABB_tree/internal/AABB_ray_intersection.h index 34bb26d7f90..b670266e8a4 100644 --- a/AABB_tree/include/CGAL/AABB_tree/internal/AABB_ray_intersection.h +++ b/AABB_tree/include/CGAL/AABB_tree/internal/AABB_ray_intersection.h @@ -33,29 +33,12 @@ namespace CGAL { -namespace internal { -template -struct Intersection_traits_wrapper {}; - -template -struct Intersection_traits_wrapper { - typedef typename GT::Ray_2 Ray; - typedef typename GT::Vector_2 Vector; -}; - -template -struct Intersection_traits_wrapper { - typedef typename GT::Ray_3 Ray; - typedef typename GT::Vector_3 Vector; -}; -} - template class AABB_ray_intersection { typedef typename AABBTree::AABB_traits AABB_traits; static const int dimension = AABB_traits::Point::Ambient_dimension::value; - typedef typename internal::Intersection_traits_wrapper::Ray Ray; - typedef typename internal::Intersection_traits_wrapper::Vector Vector; + typedef typename AABB_traits::Ray Ray; + typedef typename AABB_traits::Vector Vector; typedef typename AABBTree::template Intersection_and_primitive_id::Type Ray_intersection_and_primitive_id; typedef typename Ray_intersection_and_primitive_id::first_type Ray_intersection;