From d671f6069a18a47f9320cabcdd1a1d2c2618a3ef Mon Sep 17 00:00:00 2001 From: Bishwash Khanal <43448240+bkhanal-11@users.noreply.github.com> Date: Fri, 27 Jan 2023 14:04:44 +0545 Subject: [PATCH] added user input --- .../polyfit_example_model_complexity_control.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Polygonal_surface_reconstruction/examples/Polygonal_surface_reconstruction/polyfit_example_model_complexity_control.cpp b/Polygonal_surface_reconstruction/examples/Polygonal_surface_reconstruction/polyfit_example_model_complexity_control.cpp index e132d62975d..cf1ce77b8b1 100644 --- a/Polygonal_surface_reconstruction/examples/Polygonal_surface_reconstruction/polyfit_example_model_complexity_control.cpp +++ b/Polygonal_surface_reconstruction/examples/Polygonal_surface_reconstruction/polyfit_example_model_complexity_control.cpp @@ -39,9 +39,9 @@ typedef CGAL::Nth_of_tuple_property_map<2, PNI> * candidate generation are cached and reused. */ -int main() +int main(int argc, char* argv[]) { - const std::string& input_file(CGAL::data_file_path("points_3/building.ply")); + const std::string input_file = (argc > 1) ? argv[1] : CGAL::data_file_path("points_3/building.ply"); std::ifstream input_stream(input_file.c_str()); std::vector points; // store points