diff --git a/Polyhedron/demo/Polyhedron/CMakeLists.txt b/Polyhedron/demo/Polyhedron/CMakeLists.txt index 10077f8c394..aaf8abd3c1a 100644 --- a/Polyhedron/demo/Polyhedron/CMakeLists.txt +++ b/Polyhedron/demo/Polyhedron/CMakeLists.txt @@ -131,9 +131,6 @@ endif() if(CGAL_Qt5_FOUND AND Qt5_FOUND AND OPENGL_FOUND ) include(${CGAL_USE_FILE}) - set(Boost_USE_MULTITHREADED ON) - find_package(Boost COMPONENTS thread system filesystem) - qt5_wrap_ui( MainWindowUI_files MainWindow.ui) qt5_wrap_ui( SubViewerUI_files SubViewer.ui) qt5_wrap_ui( statisticsUI_FILES Statistics_on_item_dialog.ui) @@ -233,7 +230,7 @@ if(CGAL_Qt5_FOUND AND Qt5_FOUND AND OPENGL_FOUND ) macro(add_item item_name) add_library(${item_name} SHARED ${ARGN}) target_link_libraries(${item_name} - PUBLIC demo_framework ${CGAL_LIBRARIES} ${Boost_LIBRARIES} + PUBLIC demo_framework ${CGAL_LIBRARIES} Qt5::OpenGL Qt5::Gui Qt5::Script Qt5::Widgets) cgal_add_compilation_test(${item_name}) endmacro(add_item) diff --git a/Polyhedron/demo/Polyhedron/MainWindow.cpp b/Polyhedron/demo/Polyhedron/MainWindow.cpp index 7f7978a5e8f..0285a33b8b1 100644 --- a/Polyhedron/demo/Polyhedron/MainWindow.cpp +++ b/Polyhedron/demo/Polyhedron/MainWindow.cpp @@ -341,6 +341,7 @@ MainWindow::MainWindow(const QStringList &keywords, bool verbose, QWidget* paren connect(&operationSearchBar, &QLineEdit::textChanged, this, &MainWindow::filterOperations); loadPlugins(); + accepted_keywords.clear(); // Setup the submenu of the View menu that can toggle the dockwidgets Q_FOREACH(QDockWidget* widget, findChildren()) { diff --git a/Polyhedron/demo/Polyhedron/MainWindow.h b/Polyhedron/demo/Polyhedron/MainWindow.h index bae08376816..f692af4500f 100644 --- a/Polyhedron/demo/Polyhedron/MainWindow.h +++ b/Polyhedron/demo/Polyhedron/MainWindow.h @@ -456,7 +456,7 @@ private: bool bbox_need_update; QMap >plugin_metadata_map; QMap ignored_map; - const QStringList& accepted_keywords; + QStringList accepted_keywords; private Q_SLOTS: void on_actionAdd_Viewer_triggered(); diff --git a/Polyhedron/demo/Polyhedron/Plugins/Mesh_3/CMakeLists.txt b/Polyhedron/demo/Polyhedron/Plugins/Mesh_3/CMakeLists.txt index 59966607eef..96575090599 100644 --- a/Polyhedron/demo/Polyhedron/Plugins/Mesh_3/CMakeLists.txt +++ b/Polyhedron/demo/Polyhedron/Plugins/Mesh_3/CMakeLists.txt @@ -29,11 +29,17 @@ if (VTK_FOUND) else() message(STATUS "NOTICE : the DICOM files (.dcm) need VTK libraries to be open and will not be able to.") endif() + +find_package(Boost QUIET OPTIONAL_COMPONENTS filesystem) if(Boost_FILESYSTEM_FOUND) qt5_wrap_ui( imgUI_FILES Image_res_dialog.ui raw_image.ui) polyhedron_demo_plugin(io_image_plugin Io_image_plugin Volume_plane_intersection.cpp Raw_image_dialog.cpp ${imgUI_FILES} ${VOLUME_MOC_OUTFILES} KEYWORDS IO Mesh_3) - target_link_libraries(io_image_plugin PUBLIC scene_image_item ${VTK_LIBS} ) - target_link_libraries(io_image_plugin PUBLIC CGAL::CGAL_ImageIO) + target_link_libraries(io_image_plugin PUBLIC scene_image_item ${VTK_LIBS} CGAL::CGAL_ImageIO) + if(TARGET Boost::filesystem) + target_link_libraries(io_image_plugin PUBLIC Boost::filesystem) + else() + target_link_libraries(io_image_plugin PUBLIC ${Boost_LIBRARIES}) + endif() else() message( STATUS "NOTICE : the Io_image_plugin needs boost-filesystem to work and will not be compiled") endif() diff --git a/Surface_mesh/include/CGAL/Surface_mesh/Surface_mesh.h b/Surface_mesh/include/CGAL/Surface_mesh/Surface_mesh.h index 0f9b77861b2..f2c03be9a76 100644 --- a/Surface_mesh/include/CGAL/Surface_mesh/Surface_mesh.h +++ b/Surface_mesh/include/CGAL/Surface_mesh/Surface_mesh.h @@ -2125,8 +2125,9 @@ private: //------------------------------------------------------- private data reindex.resize(sm.num_vertices()); int n = 0; for(Vertex_index v : sm.vertices()){ - - os << get(vpm, v); + + P p = get(vpm, v); + os << p.x() << " " << p.y() << " " << p.z(); if(has_vcolors) { CGAL::Color color = vcolors[v]; @@ -2407,7 +2408,7 @@ private: //------------------------------------------------------- private data } sm.reserve(sm.num_vertices()+n, sm.num_edges()+e, sm.num_faces()+f); std::vector vertexmap(n); - P p; + Vector_3 v; typename Mesh::template Property_map vcolor; typename Mesh::template Property_map vnormal; @@ -2422,10 +2423,11 @@ private: //------------------------------------------------------- private data for(int i=0; i < n; i++){ is >> sm_skip_comments; - is >> p; + double x, y, z; + is >> iformat(x) >> iformat(y) >> iformat(z); Vertex_index vi = sm.add_vertex(); - put(vpm, vi, p); + put(vpm, vi, P(x, y, z)); vertexmap[i] = vi;