diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/Alpha_complex/include/gudhi/Alpha_complex_3d.h | 13 | ||||
-rw-r--r-- | src/Alpha_complex/test/Alpha_complex_3d_unit_test.cpp | 8 |
2 files changed, 6 insertions, 15 deletions
diff --git a/src/Alpha_complex/include/gudhi/Alpha_complex_3d.h b/src/Alpha_complex/include/gudhi/Alpha_complex_3d.h index f40a08f9..ca3c5fc3 100644 --- a/src/Alpha_complex/include/gudhi/Alpha_complex_3d.h +++ b/src/Alpha_complex/include/gudhi/Alpha_complex_3d.h @@ -82,16 +82,7 @@ template <complexity Complexity, bool Weighted_or_periodic> struct Value_from_iterator { template <typename Iterator> static double perform(Iterator it) { - // Default behaviour is to return the value pointed by the given iterator - return *it; - } -}; - -template <> -struct Value_from_iterator<complexity::SAFE, true> { - template <typename Iterator> - static double perform(Iterator it) { - // In SAFE mode, we are with Epick with EXACT value set to CGAL::Tag_true. + // Default behaviour return CGAL::to_double(*it); } }; @@ -118,7 +109,7 @@ template<bool Weighted_or_periodic> struct Value_from_iterator<complexity::EXACT,Weighted_or_periodic>{ template <typename Iterator> static double perform(Iterator it) { - // In EXACT mode, we are with Epeck or Epick with EXACT value set to CGAL::Tag_true. + // In EXACT mode, we are with Epeck, or with Epick and EXACT value set to CGAL::Tag_true. return CGAL::to_double(it->exact()); } }; diff --git a/src/Alpha_complex/test/Alpha_complex_3d_unit_test.cpp b/src/Alpha_complex/test/Alpha_complex_3d_unit_test.cpp index 9e071195..b818fb2e 100644 --- a/src/Alpha_complex/test/Alpha_complex_3d_unit_test.cpp +++ b/src/Alpha_complex/test/Alpha_complex_3d_unit_test.cpp @@ -432,13 +432,13 @@ BOOST_AUTO_TEST_CASE_TEMPLATE(Alpha_complex_weighted_periodic_throw, Weighted_pe wp_variants_type_list) { std::cout << "Weighted periodic alpha complex 3d exception throw" << std::endl; - using Creator = CGAL::Creator_uniform_3<double, Weighted_periodic_alpha_complex_3d::Point_3>; + using Creator = CGAL::Creator_uniform_3<double, typename Weighted_periodic_alpha_complex_3d::Point_3>; CGAL::Random random(7); - CGAL::Random_points_in_cube_3<Weighted_periodic_alpha_complex_3d::Point_3, Creator> in_cube(1, random); - std::vector<Weighted_periodic_alpha_complex_3d::Point_3> wp_points; + CGAL::Random_points_in_cube_3<typename Weighted_periodic_alpha_complex_3d::Point_3, Creator> in_cube(1, random); + std::vector<typename Weighted_periodic_alpha_complex_3d::Point_3> wp_points; for (int i = 0; i < 50; i++) { - Weighted_periodic_alpha_complex_3d::Point_3 p = *in_cube++; + typename Weighted_periodic_alpha_complex_3d::Point_3 p = *in_cube++; wp_points.push_back(p); } std::vector<double> p_weights; |