From 0e8a76e615a4d91c972dfb2f169b1002f08ee626 Mon Sep 17 00:00:00 2001 From: Andreas Fabri Date: Thu, 24 Nov 2022 07:53:31 +0000 Subject: [PATCH 1/2] Polygonal Surface Reconstuction: Fix paths in examples --- .../Polygonal_surface_reconstruction.txt | 2 +- .../doc/Polygonal_surface_reconstruction/examples.txt | 2 +- .../Polygonal_surface_reconstruction/CMakeLists.txt | 4 ++-- .../polyfit_example_model_complexty_control.cpp | 6 +++--- .../polyfit_example_user_provided_planes.cpp | 2 +- .../polyfit_example_with_region_growing.cpp | 2 +- .../polyfit_example_without_input_planes.cpp | 4 ++-- 7 files changed, 11 insertions(+), 11 deletions(-) diff --git a/Polygonal_surface_reconstruction/doc/Polygonal_surface_reconstruction/Polygonal_surface_reconstruction.txt b/Polygonal_surface_reconstruction/doc/Polygonal_surface_reconstruction/Polygonal_surface_reconstruction.txt index cbaf4f3e5a1..1f6d1200192 100644 --- a/Polygonal_surface_reconstruction/doc/Polygonal_surface_reconstruction/Polygonal_surface_reconstruction.txt +++ b/Polygonal_surface_reconstruction/doc/Polygonal_surface_reconstruction/Polygonal_surface_reconstruction.txt @@ -182,7 +182,7 @@ The following example shows how to control the model complexity by tuning the we \remark This example also shows how to reuse the intermediate results from the candidate generation step. -\cgalExample{Polygonal_surface_reconstruction/polyfit_example_model_complexty_control.cpp} +\cgalExample{Polygonal_surface_reconstruction/polyfit_example_model_complexity_control.cpp} \section secPerformances Performance diff --git a/Polygonal_surface_reconstruction/doc/Polygonal_surface_reconstruction/examples.txt b/Polygonal_surface_reconstruction/doc/Polygonal_surface_reconstruction/examples.txt index 0b1b37d6a26..24a2ab456cc 100644 --- a/Polygonal_surface_reconstruction/doc/Polygonal_surface_reconstruction/examples.txt +++ b/Polygonal_surface_reconstruction/doc/Polygonal_surface_reconstruction/examples.txt @@ -1,6 +1,6 @@ /*! \example Polygonal_surface_reconstruction/polyfit_example_without_input_planes.cpp \example Polygonal_surface_reconstruction/polyfit_example_user_provided_planes.cpp -\example Polygonal_surface_reconstruction/polyfit_example_model_complexty_control.cpp +\example Polygonal_surface_reconstruction/polyfit_example_model_complexity_control.cpp \example Polygonal_surface_reconstruction/polyfit_example_with_region_growing.cpp */ diff --git a/Polygonal_surface_reconstruction/examples/Polygonal_surface_reconstruction/CMakeLists.txt b/Polygonal_surface_reconstruction/examples/Polygonal_surface_reconstruction/CMakeLists.txt index 9db1ae5e988..0fb6ae17322 100644 --- a/Polygonal_surface_reconstruction/examples/Polygonal_surface_reconstruction/CMakeLists.txt +++ b/Polygonal_surface_reconstruction/examples/Polygonal_surface_reconstruction/CMakeLists.txt @@ -51,13 +51,13 @@ endif() create_single_source_cgal_program("polyfit_example_without_input_planes.cpp") create_single_source_cgal_program("polyfit_example_user_provided_planes.cpp") -create_single_source_cgal_program("polyfit_example_model_complexty_control.cpp") +create_single_source_cgal_program("polyfit_example_model_complexity_control.cpp") create_single_source_cgal_program("polyfit_example_with_region_growing.cpp") foreach( target polyfit_example_without_input_planes polyfit_example_user_provided_planes - polyfit_example_model_complexty_control polyfit_example_with_region_growing) + polyfit_example_model_complexity_control polyfit_example_with_region_growing) target_link_libraries(${target} PUBLIC CGAL::Eigen3_support) if(TARGET CGAL::SCIP_support) target_link_libraries(${target} PUBLIC CGAL::SCIP_support) diff --git a/Polygonal_surface_reconstruction/examples/Polygonal_surface_reconstruction/polyfit_example_model_complexty_control.cpp b/Polygonal_surface_reconstruction/examples/Polygonal_surface_reconstruction/polyfit_example_model_complexty_control.cpp index 64fd9a9784a..e132d62975d 100644 --- a/Polygonal_surface_reconstruction/examples/Polygonal_surface_reconstruction/polyfit_example_model_complexty_control.cpp +++ b/Polygonal_surface_reconstruction/examples/Polygonal_surface_reconstruction/polyfit_example_model_complexty_control.cpp @@ -90,7 +90,7 @@ int main() return EXIT_FAILURE; } else { - const std::string& output_file = "data/building_result-0.05.off"; + const std::string& output_file = "building_result-0.05.off"; if (CGAL::IO::write_OFF(output_file, model)) { std::cout << " Done. Saved to " << output_file << ". Time: " << t.time() << " sec." << std::endl; } @@ -108,7 +108,7 @@ int main() return EXIT_FAILURE; } else { - const std::string& output_file = "data/building_result-0.5.off"; + const std::string& output_file = "building_result-0.5.off"; if (CGAL::IO::write_OFF(output_file, model)) std::cout << " Done. Saved to " << output_file << ". Time: " << t.time() << " sec." << std::endl; else { @@ -125,7 +125,7 @@ int main() return EXIT_FAILURE; } else { - const std::string& output_file = "data/building_result-0.7.off"; + const std::string& output_file = "building_result-0.7.off"; if (CGAL::IO::write_OFF(output_file, model)){ std::cout << " Done. Saved to " << output_file << ". Time: " << t.time() << " sec." << std::endl; } diff --git a/Polygonal_surface_reconstruction/examples/Polygonal_surface_reconstruction/polyfit_example_user_provided_planes.cpp b/Polygonal_surface_reconstruction/examples/Polygonal_surface_reconstruction/polyfit_example_user_provided_planes.cpp index 733f0113749..2f2ed2df2c9 100644 --- a/Polygonal_surface_reconstruction/examples/Polygonal_surface_reconstruction/polyfit_example_user_provided_planes.cpp +++ b/Polygonal_surface_reconstruction/examples/Polygonal_surface_reconstruction/polyfit_example_user_provided_planes.cpp @@ -89,7 +89,7 @@ int main() } // Saves the mesh model - const std::string& output_file("data/ball_result.off"); + const std::string& output_file("user_provided_planes_result.off"); if (CGAL::IO::write_OFF(output_file, model)) std::cout << " Done. Saved to " << output_file << ". Time: " << t.time() << " sec." << std::endl; else { diff --git a/Polygonal_surface_reconstruction/examples/Polygonal_surface_reconstruction/polyfit_example_with_region_growing.cpp b/Polygonal_surface_reconstruction/examples/Polygonal_surface_reconstruction/polyfit_example_with_region_growing.cpp index 8dc81bd3c1e..493c8c138aa 100644 --- a/Polygonal_surface_reconstruction/examples/Polygonal_surface_reconstruction/polyfit_example_with_region_growing.cpp +++ b/Polygonal_surface_reconstruction/examples/Polygonal_surface_reconstruction/polyfit_example_with_region_growing.cpp @@ -172,7 +172,7 @@ int main() std::cout << "Saving..."; t.reset(); - const std::string& output_file("data/cube_result.off"); + const std::string& output_file("with_region_growing_result.off"); if (CGAL::IO::write_OFF(output_file, model)) std::cout << " Done. Saved to " << output_file << ". Time: " << t.time() << " sec." << std::endl; else { diff --git a/Polygonal_surface_reconstruction/examples/Polygonal_surface_reconstruction/polyfit_example_without_input_planes.cpp b/Polygonal_surface_reconstruction/examples/Polygonal_surface_reconstruction/polyfit_example_without_input_planes.cpp index 85e474d99d7..4b2ed8f91a4 100644 --- a/Polygonal_surface_reconstruction/examples/Polygonal_surface_reconstruction/polyfit_example_without_input_planes.cpp +++ b/Polygonal_surface_reconstruction/examples/Polygonal_surface_reconstruction/polyfit_example_without_input_planes.cpp @@ -125,7 +125,7 @@ int main() return EXIT_FAILURE; } - const std::string& output_file("data/cube_result.off"); + const std::string& output_file("without_input_planes_result.off"); if (CGAL::IO::write_OFF(output_file, model)) std::cout << " Done. Saved to " << output_file << ". Time: " << t.time() << " sec." << std::endl; else { @@ -138,7 +138,7 @@ int main() // Also stores the candidate faces as a surface mesh to a file Surface_mesh candidate_faces; algo.output_candidate_faces(candidate_faces); - const std::string& candidate_faces_file("data/cube_candidate_faces.off"); + const std::string& candidate_faces_file("without_input_planes_cube_candidate_faces.off"); std::ofstream candidate_stream(candidate_faces_file.c_str()); if (CGAL::IO::write_OFF(candidate_stream, candidate_faces)) std::cout << "Candidate faces saved to " << candidate_faces_file << "." << std::endl; From 9734f71e121332f39961d314b40d6135a1c312e6 Mon Sep 17 00:00:00 2001 From: Andreas Fabri Date: Thu, 24 Nov 2022 08:01:21 +0000 Subject: [PATCH 2/2] Rename example file --- ...y_control.cpp => polyfit_example_model_complexity_control.cpp} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename Polygonal_surface_reconstruction/examples/Polygonal_surface_reconstruction/{polyfit_example_model_complexty_control.cpp => polyfit_example_model_complexity_control.cpp} (100%) diff --git a/Polygonal_surface_reconstruction/examples/Polygonal_surface_reconstruction/polyfit_example_model_complexty_control.cpp b/Polygonal_surface_reconstruction/examples/Polygonal_surface_reconstruction/polyfit_example_model_complexity_control.cpp similarity index 100% rename from Polygonal_surface_reconstruction/examples/Polygonal_surface_reconstruction/polyfit_example_model_complexty_control.cpp rename to Polygonal_surface_reconstruction/examples/Polygonal_surface_reconstruction/polyfit_example_model_complexity_control.cpp