From bbf22c32a893c9875f6ea0e217d0bf6cf77c3257 Mon Sep 17 00:00:00 2001 From: vrouvrea Date: Wed, 23 Mar 2016 08:09:39 +0000 Subject: prune_above_filtration returns filtration vector modification information instead of calling initialize_filtration() git-svn-id: svn+ssh://scm.gforge.inria.fr/svnroot/gudhi/branches/alphashapes@1071 636b058d-ea47-450e-bf9e-a15bfbe3eedb Former-commit-id: 6fdc1797ac6e7b452abe150643f0ec9578c3bbab --- src/Alpha_complex/test/Alpha_complex_unit_test.cpp | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'src/Alpha_complex/test') diff --git a/src/Alpha_complex/test/Alpha_complex_unit_test.cpp b/src/Alpha_complex/test/Alpha_complex_unit_test.cpp index 2912019d..315582d1 100644 --- a/src/Alpha_complex/test/Alpha_complex_unit_test.cpp +++ b/src/Alpha_complex/test/Alpha_complex_unit_test.cpp @@ -78,7 +78,8 @@ BOOST_AUTO_TEST_CASE(ALPHA_DOC_OFF_file_filtered) { std::cout << "========== OFF FILE NAME = " << off_file_name << " - alpha²=" << max_alpha_square_value << "==========" << std::endl; - Gudhi::alphacomplex::Alpha_complex alpha_complex_from_file(off_file_name, max_alpha_square_value); + // Use of the default dynamic kernel + Gudhi::alphacomplex::Alpha_complex<> alpha_complex_from_file(off_file_name, max_alpha_square_value); const int DIMENSION = 2; std::cout << "alpha_complex_from_file.dimension()=" << alpha_complex_from_file.dimension() << std::endl; @@ -200,7 +201,12 @@ BOOST_AUTO_TEST_CASE(Alpha_complex_from_points) { BOOST_CHECK_THROW (alpha_complex_from_points.get_point(1234), std::out_of_range); // Test after prune_above_filtration - alpha_complex_from_points.prune_above_filtration(0.6); + bool modified = alpha_complex_from_points.prune_above_filtration(0.6); + if (modified) { + alpha_complex_from_points.initialize_filtration(); + } + BOOST_CHECK(modified); + // Another way to check num_simplices std::cout << "Iterator on alpha complex simplices in the filtration order, with [filtration value]:" << std::endl; num_simplices = 0; -- cgit v1.2.3