diff --git a/AABB_tree/include/CGAL/AABB_face_graph_triangle_primitive.h b/AABB_tree/include/CGAL/AABB_face_graph_triangle_primitive.h index 6657398435c..6d12a85adef 100644 --- a/AABB_tree/include/CGAL/AABB_face_graph_triangle_primitive.h +++ b/AABB_tree/include/CGAL/AABB_face_graph_triangle_primitive.h @@ -98,7 +98,7 @@ class AABB_face_graph_triangle_primitive } public: - #ifdef DOXYGEN_RUNNING +#ifdef DOXYGEN_RUNNING /// \name Types /// @{ /*! @@ -122,18 +122,32 @@ public: If `OneFaceGraphPerTree` is CGAL::Tag_true, constructs a `Shared_data` object from a reference to the polyhedon `graph`. */ static unspecified_type construct_shared_data( FaceGraph& graph ); - #else +#else typedef typename Base::Id Id; - #endif +#endif typedef typename boost::graph_traits::face_descriptor face_descriptor; // constructors + +#ifdef DOXYGEN_RUNNING /*! + constructs a primitive. + \tparam Iterator an input iterator with `Id` as value type. + + If `VertexPointPMap` is the default of the class, an additional constructor + is available with `vppm` set to `get(vertex_point, graph)`. + */ + template + AABB_face_graph_triangle_primitive(Iterator it, const FaceGraph& graph, VertexPointPMap vppm); + + /*! constructs a primitive. If `VertexPointPMap` is the default of the class, an additional constructor is available with `vppm` set to `get(vertex_point, graph)`. */ + AABB_face_graph_triangle_primitive(face_descriptor fd, const FaceGraph& graph, VertexPointPMap vppm); +#else template AABB_face_graph_triangle_primitive(Iterator it, const FaceGraph& graph, VertexPointPMap_ vppm) : Base( Id_(make_id(*it, graph, OneFaceGraphPerTree())), @@ -141,18 +155,12 @@ public: Point_property_map(const_cast(&graph),vppm) ) {} - /*! - constructs a primitive. - If `VertexPointPMap` is the default of the class, an additional constructor - is available with `vppm` set to `get(vertex_point, graph)`. - */ AABB_face_graph_triangle_primitive(face_descriptor fd, const FaceGraph& graph, VertexPointPMap_ vppm) : Base( Id_(make_id(fd, graph, OneFaceGraphPerTree())), Triangle_property_map(const_cast(&graph),vppm), Point_property_map(const_cast(&graph),vppm) ) {} -#ifndef DOXYGEN_RUNNING template AABB_face_graph_triangle_primitive(Iterator it, const FaceGraph& graph) : Base( Id_(make_id(*it, graph, OneFaceGraphPerTree())), diff --git a/AABB_tree/include/CGAL/AABB_halfedge_graph_segment_primitive.h b/AABB_tree/include/CGAL/AABB_halfedge_graph_segment_primitive.h index 1138376df43..a86ba35caac 100644 --- a/AABB_tree/include/CGAL/AABB_halfedge_graph_segment_primitive.h +++ b/AABB_tree/include/CGAL/AABB_halfedge_graph_segment_primitive.h @@ -140,14 +140,27 @@ public: #endif typedef typename boost::graph_traits::edge_descriptor edge_descriptor; +#ifdef DOXYGEN_RUNNING /*! constructs a primitive. + \tparam Iterator is an input iterator with `Id` as value type. + This \ref AABB_tree/AABB_halfedge_graph_edge_example.cpp "example" gives a way to call this constructor using the insert-by-range method of the class `AABB_tree`. If `VertexPointPMap` is the default of the class, an additional constructor is available with `vppm` set to `boost::get(vertex_point, graph)`. */ + template + AABB_halfedge_graph_segment_primitive(Iterator it, const HalfedgeGraph& graph, VertexPointPMap vppm); + + /*! + constructs a primitive. + If `VertexPointPMap` is the default of the class, an additional constructor + is available with `vppm` set to `boost::get(vertex_point, graph)`. + */ + AABB_halfedge_graph_segment_primitive(edge_descriptor ed, const HalfedgeGraph& graph, VertexPointPMap vppm); +#else template AABB_halfedge_graph_segment_primitive(Iterator it, const HalfedgeGraph& graph, VertexPointPMap_ vppm) : Base( Id_(make_id(*it, graph, OneHalfedgeGraphPerTree())), @@ -155,18 +168,12 @@ public: Point_property_map(const_cast(&graph), vppm) ) {} - /*! - constructs a primitive. - If `VertexPointPMap` is the default of the class, an additional constructor - is available with `vppm` set to `boost::get(vertex_point, graph)`. - */ AABB_halfedge_graph_segment_primitive(edge_descriptor ed, const HalfedgeGraph& graph, VertexPointPMap_ vppm) : Base( Id_(make_id(ed, graph, OneHalfedgeGraphPerTree())), Segment_property_map(const_cast(&graph), vppm), Point_property_map(const_cast(&graph), vppm) ) {} - #ifndef DOXYGEN_RUNNING template AABB_halfedge_graph_segment_primitive(Iterator it, const HalfedgeGraph& graph) : Base( Id_(make_id(*it, graph, OneHalfedgeGraphPerTree())), @@ -177,7 +184,7 @@ public: : Base( Id_(make_id(ed, graph, OneHalfedgeGraphPerTree())), Segment_property_map(const_cast(&graph)), Point_property_map(const_cast(&graph)) ){} - #endif +#endif /// \internal typedef internal::Cstr_shared_data Cstr_shared_data; diff --git a/Optimal_bounding_box/doc/Optimal_bounding_box/PackageDescription.txt b/Optimal_bounding_box/doc/Optimal_bounding_box/PackageDescription.txt index 859f26d645a..4ab46f8993c 100644 --- a/Optimal_bounding_box/doc/Optimal_bounding_box/PackageDescription.txt +++ b/Optimal_bounding_box/doc/Optimal_bounding_box/PackageDescription.txt @@ -26,7 +26,7 @@ \cgalPkgDependsOn{\ref PkgConvexHull3} \cgalPkgBib{cgal:obb} \cgalPkgLicense{\ref licensesGPL "GPL"} -\cgalPkgDemo{Polyhedron demo, polyhedron_3.zip} +\cgalPkgDemo{Polyhedron demo,polyhedron_3.zip} \cgalPkgShortInfoEnd \cgalPkgDescriptionEnd diff --git a/Shape_detection/doc/Shape_detection/PackageDescription.txt b/Shape_detection/doc/Shape_detection/PackageDescription.txt index 52001fe612e..35e87d2dc4e 100644 --- a/Shape_detection/doc/Shape_detection/PackageDescription.txt +++ b/Shape_detection/doc/Shape_detection/PackageDescription.txt @@ -74,7 +74,7 @@ on a polygon mesh.} \cgalPkgSince{4.7} \cgalPkgBib{cgal:ovja-pssd} \cgalPkgLicense{\ref licensesGPL "GPL"} -\cgalPkgDemo{Polyhedron demo, polyhedron_3.zip} +\cgalPkgDemo{Polyhedron demo,polyhedron_3.zip} \cgalPkgShortInfoEnd \cgalPkgDescriptionEnd diff --git a/Shape_detection/include/CGAL/Shape_detection/Efficient_RANSAC/Efficient_RANSAC.h b/Shape_detection/include/CGAL/Shape_detection/Efficient_RANSAC/Efficient_RANSAC.h index beff95c50e9..ec22801ba1d 100644 --- a/Shape_detection/include/CGAL/Shape_detection/Efficient_RANSAC/Efficient_RANSAC.h +++ b/Shape_detection/include/CGAL/Shape_detection/Efficient_RANSAC/Efficient_RANSAC.h @@ -511,7 +511,7 @@ namespace CGAL { // Minimum number of points has been set? m_options.min_points = - (m_options.min_points >= m_num_available_points) ? + (m_options.min_points == (std::numeric_limits::max)()) ? (std::size_t)((FT)0.01 * m_num_available_points) : m_options.min_points; m_options.min_points = (m_options.min_points < 10) ? 10 : m_options.min_points; @@ -519,6 +519,9 @@ namespace CGAL { // Initializing the shape index m_shape_index.assign(m_num_available_points, -1); + if (m_options.min_points > m_num_available_points) + return true; + // List of all randomly drawn candidates // with the minimum number of points std::vector candidates;