From bc8e1f399da656bb75047f78b58b087e79b4a35c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Loriot?= Date: Sat, 19 Jul 2014 12:20:29 +0200 Subject: [PATCH] workaround a bug in dijsktra algorithm in boost 1.54 affecting normal estimation --- .../bgl_primal_adapter.cpp | 3 +- .../Arrangement_on_surface_2/test_dual.cpp | 3 +- BGL/examples/BGL_arrangement_2/primal.cpp | 3 +- BGL/examples/BGL_triangulation_2/dijkstra.cpp | 3 +- .../dijkstra_with_internal_properties.cpp | 3 +- .../boost/graph/dijkstra_shortest_paths.h | 40 ++ .../boost/graph/dijkstra_shortest_paths.hpp | 629 ++++++++++++++++++ .../Envelope_divide_and_conquer_3.h | 3 +- Installation/changes.html | 8 + .../Point_set_processing_3/CMakeLists.txt | 4 +- .../include/CGAL/mst_orient_normals.h | 8 +- 11 files changed, 686 insertions(+), 21 deletions(-) create mode 100644 BGL/include/CGAL/boost/graph/dijkstra_shortest_paths.h create mode 100644 BGL/include/CGAL/boost/graph/dijkstra_shortest_paths.hpp diff --git a/Arrangement_on_surface_2/examples/Arrangement_on_surface_2/bgl_primal_adapter.cpp b/Arrangement_on_surface_2/examples/Arrangement_on_surface_2/bgl_primal_adapter.cpp index ab115d05b65..9f169f219eb 100644 --- a/Arrangement_on_surface_2/examples/Arrangement_on_surface_2/bgl_primal_adapter.cpp +++ b/Arrangement_on_surface_2/examples/Arrangement_on_surface_2/bgl_primal_adapter.cpp @@ -8,8 +8,7 @@ #include #include -#include -#include +#include #include diff --git a/Arrangement_on_surface_2/test/Arrangement_on_surface_2/test_dual.cpp b/Arrangement_on_surface_2/test/Arrangement_on_surface_2/test_dual.cpp index 7fcd23eef91..39fd5c92f9f 100644 --- a/Arrangement_on_surface_2/test/Arrangement_on_surface_2/test_dual.cpp +++ b/Arrangement_on_surface_2/test/Arrangement_on_surface_2/test_dual.cpp @@ -5,8 +5,7 @@ #include #include -#include // needed as forgot it. -#include +#include #include diff --git a/BGL/examples/BGL_arrangement_2/primal.cpp b/BGL/examples/BGL_arrangement_2/primal.cpp index ab115d05b65..9f169f219eb 100644 --- a/BGL/examples/BGL_arrangement_2/primal.cpp +++ b/BGL/examples/BGL_arrangement_2/primal.cpp @@ -8,8 +8,7 @@ #include #include -#include -#include +#include #include diff --git a/BGL/examples/BGL_triangulation_2/dijkstra.cpp b/BGL/examples/BGL_triangulation_2/dijkstra.cpp index 6a6fe1d91d7..d5dc03e08a5 100644 --- a/BGL/examples/BGL_triangulation_2/dijkstra.cpp +++ b/BGL/examples/BGL_triangulation_2/dijkstra.cpp @@ -2,8 +2,7 @@ #include #include -#include -#include +#include #include typedef CGAL::Exact_predicates_inexact_constructions_kernel K; diff --git a/BGL/examples/BGL_triangulation_2/dijkstra_with_internal_properties.cpp b/BGL/examples/BGL_triangulation_2/dijkstra_with_internal_properties.cpp index c6cab15f596..0a3d0d7b5c7 100644 --- a/BGL/examples/BGL_triangulation_2/dijkstra_with_internal_properties.cpp +++ b/BGL/examples/BGL_triangulation_2/dijkstra_with_internal_properties.cpp @@ -3,8 +3,7 @@ #include #include -#include -#include +#include #include typedef CGAL::Exact_predicates_inexact_constructions_kernel K; diff --git a/BGL/include/CGAL/boost/graph/dijkstra_shortest_paths.h b/BGL/include/CGAL/boost/graph/dijkstra_shortest_paths.h new file mode 100644 index 00000000000..84f80011099 --- /dev/null +++ b/BGL/include/CGAL/boost/graph/dijkstra_shortest_paths.h @@ -0,0 +1,40 @@ +// Copyright (c) 2014 GeometryFactory (France). All rights reserved. +// +// This file is part of CGAL (www.cgal.org); you can redistribute it and/or +// modify it under the terms of the GNU Lesser General Public License as +// published by the Free Software Foundation; either version 3 of the License, +// or (at your option) any later version. +// +// Licensees holding a valid commercial license may use this file in +// accordance with the commercial license agreement provided with the software. +// +// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE +// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. +// +// $URL$ +// $Id$ +// +// +// Author(s) : Sebastien Loriot + + +#ifndef CGAL_BOOST_GRAPH_DIJKSTRA_SHORTEST_PATHS_H +#define CGAL_BOOST_GRAPH_DIJKSTRA_SHORTEST_PATHS_H + +#include +#include + +#if BOOST_VERSION == 105400 + #ifdef BOOST_GRAPH_DIJKSTRA_HPP + # pragma message \ + "Warning: the header file boost/graph/dijkstra_shortest_paths.hpp " \ + "of boost 1.54 contains a bug that may impact some functions in CGAL. " \ + "Please consider including CGAL/boost/graph/dijkstra_shortest_paths.hpp " \ + "before boost header" + #endif + #include +#else + #include +#endif + +#endif // CGAL_BOOST_GRAPH_DIJKSTRA_SHORTEST_PATHS_H diff --git a/BGL/include/CGAL/boost/graph/dijkstra_shortest_paths.hpp b/BGL/include/CGAL/boost/graph/dijkstra_shortest_paths.hpp new file mode 100644 index 00000000000..11d1b1ec926 --- /dev/null +++ b/BGL/include/CGAL/boost/graph/dijkstra_shortest_paths.hpp @@ -0,0 +1,629 @@ +// This file is a copy of the file distributed with boost 1.55 +// It is distributed with CGAL to work around a bug in boost 1.54 +// and must be used only with boost 1.54 by including +// CGAL/boost/graph/dijkstra_shortest_paths.hpp + + +//======================================================================= +// Copyright 1997, 1998, 1999, 2000 University of Notre Dame. +// Authors: Andrew Lumsdaine, Lie-Quan Lee, Jeremy G. Siek +// +// Distributed under the Boost Software License, Version 1.0. (See +// accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) +//======================================================================= +// +// +// Revision History: +// 04 April 2001: Added named parameter variant. (Jeremy Siek) +// 01 April 2001: Modified to use new header. (JMaddock) +// +#ifndef BOOST_GRAPH_DIJKSTRA_HPP +#define BOOST_GRAPH_DIJKSTRA_HPP + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#ifdef BOOST_GRAPH_DIJKSTRA_TESTING +# include +#endif // BOOST_GRAPH_DIJKSTRA_TESTING + +namespace boost { + + /** + * @brief Updates a particular value in a queue used by Dijkstra's + * algorithm. + * + * This routine is called by Dijkstra's algorithm after it has + * decreased the distance from the source vertex to the given @p + * vertex. By default, this routine will just call @c + * Q.update(vertex). However, other queues may provide more + * specialized versions of this routine. + * + * @param Q the queue that will be updated. + * @param vertex the vertex whose distance has been updated + * @param old_distance the previous distance to @p vertex + */ + template + inline void + dijkstra_queue_update(Buffer& Q, Vertex vertex, DistanceType old_distance) + { + (void)old_distance; + Q.update(vertex); + } + +#ifdef BOOST_GRAPH_DIJKSTRA_TESTING + // This is a misnomer now: it now just refers to the "default heap", which is + // currently d-ary (d=4) but can be changed by a #define. + static bool dijkstra_relaxed_heap = true; +#endif + + template + struct DijkstraVisitorConcept { + void constraints() { + BOOST_CONCEPT_ASSERT(( CopyConstructibleConcept )); + vis.initialize_vertex(u, g); + vis.discover_vertex(u, g); + vis.examine_vertex(u, g); + vis.examine_edge(e, g); + vis.edge_relaxed(e, g); + vis.edge_not_relaxed(e, g); + vis.finish_vertex(u, g); + } + Visitor vis; + Graph g; + typename graph_traits::vertex_descriptor u; + typename graph_traits::edge_descriptor e; + }; + + template + class dijkstra_visitor : public bfs_visitor { + public: + dijkstra_visitor() { } + dijkstra_visitor(Visitors vis) + : bfs_visitor(vis) { } + + template + void edge_relaxed(Edge e, Graph& g) { + invoke_visitors(this->m_vis, e, g, on_edge_relaxed()); + } + template + void edge_not_relaxed(Edge e, Graph& g) { + invoke_visitors(this->m_vis, e, g, on_edge_not_relaxed()); + } + private: + template + void tree_edge(Edge u, Graph& g) { } + }; + template + dijkstra_visitor + make_dijkstra_visitor(Visitors vis) { + return dijkstra_visitor(vis); + } + typedef dijkstra_visitor<> default_dijkstra_visitor; + + namespace detail { + + template + struct dijkstra_bfs_visitor + { + typedef typename property_traits::value_type D; + typedef typename property_traits::value_type W; + + dijkstra_bfs_visitor(UniformCostVisitor vis, UpdatableQueue& Q, + WeightMap w, PredecessorMap p, DistanceMap d, + BinaryFunction combine, BinaryPredicate compare, + D zero) + : m_vis(vis), m_Q(Q), m_weight(w), m_predecessor(p), m_distance(d), + m_combine(combine), m_compare(compare), m_zero(zero) { } + + template + void tree_edge(Edge e, Graph& g) { + bool decreased = relax(e, g, m_weight, m_predecessor, m_distance, + m_combine, m_compare); + if (decreased) + m_vis.edge_relaxed(e, g); + else + m_vis.edge_not_relaxed(e, g); + } + template + void gray_target(Edge e, Graph& g) { + D old_distance = get(m_distance, target(e, g)); + + bool decreased = relax(e, g, m_weight, m_predecessor, m_distance, + m_combine, m_compare); + if (decreased) { + dijkstra_queue_update(m_Q, target(e, g), old_distance); + m_vis.edge_relaxed(e, g); + } else + m_vis.edge_not_relaxed(e, g); + } + + template + void initialize_vertex(Vertex u, Graph& g) + { m_vis.initialize_vertex(u, g); } + template + void non_tree_edge(Edge, Graph&) { } + template + void discover_vertex(Vertex u, Graph& g) { m_vis.discover_vertex(u, g); } + template + void examine_vertex(Vertex u, Graph& g) { m_vis.examine_vertex(u, g); } + template + void examine_edge(Edge e, Graph& g) { + // Test for negative-weight edges: + // + // Reasons that other comparisons do not work: + // + // m_compare(e_weight, D(0)): + // m_compare only needs to work on distances, not weights, and those + // types do not need to be the same (bug 8398, + // https://svn.boost.org/trac/boost/ticket/8398). + // m_compare(m_combine(source_dist, e_weight), source_dist): + // if m_combine is project2nd (as in prim_minimum_spanning_tree), + // this test will claim that the edge weight is negative whenever + // the edge weight is less than source_dist, even if both of those + // are positive (bug 9012, + // https://svn.boost.org/trac/boost/ticket/9012). + // m_compare(m_combine(e_weight, source_dist), source_dist): + // would fix project2nd issue, but documentation only requires that + // m_combine be able to take a distance and a weight (in that order) + // and return a distance. + + // W e_weight = get(m_weight, e); + // sd_plus_ew = source_dist + e_weight. + // D sd_plus_ew = m_combine(source_dist, e_weight); + // sd_plus_2ew = source_dist + 2 * e_weight. + // D sd_plus_2ew = m_combine(sd_plus_ew, e_weight); + // The test here is equivalent to e_weight < 0 if m_combine has a + // cancellation law, but always returns false when m_combine is a + // projection operator. + if (m_compare(m_combine(m_zero, get(m_weight, e)), m_zero)) + boost::throw_exception(negative_edge()); + // End of test for negative-weight edges. + + m_vis.examine_edge(e, g); + + } + template + void black_target(Edge, Graph&) { } + template + void finish_vertex(Vertex u, Graph& g) { m_vis.finish_vertex(u, g); } + + UniformCostVisitor m_vis; + UpdatableQueue& m_Q; + WeightMap m_weight; + PredecessorMap m_predecessor; + DistanceMap m_distance; + BinaryFunction m_combine; + BinaryPredicate m_compare; + D m_zero; + }; + + } // namespace detail + + namespace detail { + template + struct vertex_property_map_generator_helper {}; + + template + struct vertex_property_map_generator_helper { + typedef boost::iterator_property_map type; + static type build(const Graph& g, const IndexMap& index, boost::scoped_array& array_holder) { + array_holder.reset(new Value[num_vertices(g)]); + std::fill(array_holder.get(), array_holder.get() + num_vertices(g), Value()); + return make_iterator_property_map(array_holder.get(), index); + } + }; + + template + struct vertex_property_map_generator_helper { + typedef boost::vector_property_map type; + static type build(const Graph& g, const IndexMap& index, boost::scoped_array& array_holder) { + return boost::make_vector_property_map(index); + } + }; + + template + struct vertex_property_map_generator { + typedef boost::is_base_and_derived< + boost::vertex_list_graph_tag, + typename boost::graph_traits::traversal_category> + known_num_vertices; + typedef vertex_property_map_generator_helper helper; + typedef typename helper::type type; + static type build(const Graph& g, const IndexMap& index, boost::scoped_array& array_holder) { + return helper::build(g, index, array_holder); + } + }; + } + + namespace detail { + template + struct default_color_map_generator_helper {}; + + template + struct default_color_map_generator_helper { + typedef boost::two_bit_color_map type; + static type build(const Graph& g, const IndexMap& index) { + size_t nv = num_vertices(g); + return boost::two_bit_color_map(nv, index); + } + }; + + template + struct default_color_map_generator_helper { + typedef boost::vector_property_map type; + static type build(const Graph& g, const IndexMap& index) { + return boost::make_vector_property_map(index); + } + }; + + template + struct default_color_map_generator { + typedef boost::is_base_and_derived< + boost::vertex_list_graph_tag, + typename boost::graph_traits::traversal_category> + known_num_vertices; + typedef default_color_map_generator_helper helper; + typedef typename helper::type type; + static type build(const Graph& g, const IndexMap& index) { + return helper::build(g, index); + } + }; + } + + // Call breadth first search with default color map. + template + inline void + dijkstra_shortest_paths_no_init + (const Graph& g, + SourceInputIter s_begin, SourceInputIter s_end, + PredecessorMap predecessor, DistanceMap distance, WeightMap weight, + IndexMap index_map, + Compare compare, Combine combine, DistZero zero, + DijkstraVisitor vis) + { + typedef + detail::default_color_map_generator + ColorMapHelper; + typedef typename ColorMapHelper::type ColorMap; + ColorMap color = + ColorMapHelper::build(g, index_map); + dijkstra_shortest_paths_no_init( g, s_begin, s_end, predecessor, distance, weight, + index_map, compare, combine, zero, vis, + color); + } + + // Call breadth first search with default color map. + template + inline void + dijkstra_shortest_paths_no_init + (const Graph& g, + typename graph_traits::vertex_descriptor s, + PredecessorMap predecessor, DistanceMap distance, WeightMap weight, + IndexMap index_map, + Compare compare, Combine combine, DistZero zero, + DijkstraVisitor vis) + { + dijkstra_shortest_paths_no_init(g, &s, &s + 1, predecessor, distance, + weight, index_map, compare, combine, zero, + vis); + } + + // Call breadth first search + template + inline void + dijkstra_shortest_paths_no_init + (const Graph& g, + SourceInputIter s_begin, SourceInputIter s_end, + PredecessorMap predecessor, DistanceMap distance, WeightMap weight, + IndexMap index_map, + Compare compare, Combine combine, DistZero zero, + DijkstraVisitor vis, ColorMap color) + { + typedef indirect_cmp IndirectCmp; + IndirectCmp icmp(distance, compare); + + typedef typename graph_traits::vertex_descriptor Vertex; + +#ifdef BOOST_GRAPH_DIJKSTRA_TESTING + if (!dijkstra_relaxed_heap) { + typedef mutable_queue, IndirectCmp, IndexMap> + MutableQueue; + + MutableQueue Q(num_vertices(g), icmp, index_map); + detail::dijkstra_bfs_visitor + bfs_vis(vis, Q, weight, predecessor, distance, combine, compare, zero); + + breadth_first_visit(g, s_begin, s_end, Q, bfs_vis, color); + return; + } +#endif // BOOST_GRAPH_DIJKSTRA_TESTING + +#ifdef BOOST_GRAPH_DIJKSTRA_USE_RELAXED_HEAP + typedef relaxed_heap MutableQueue; + MutableQueue Q(num_vertices(g), icmp, index_map); +#else // Now the default: use a d-ary heap + boost::scoped_array index_in_heap_map_holder; + typedef + detail::vertex_property_map_generator + IndexInHeapMapHelper; + typedef typename IndexInHeapMapHelper::type IndexInHeapMap; + IndexInHeapMap index_in_heap = + IndexInHeapMapHelper::build(g, index_map, index_in_heap_map_holder); + typedef d_ary_heap_indirect + MutableQueue; + MutableQueue Q(distance, index_in_heap, compare); +#endif // Relaxed heap + + detail::dijkstra_bfs_visitor + bfs_vis(vis, Q, weight, predecessor, distance, combine, compare, zero); + + breadth_first_visit(g, s_begin, s_end, Q, bfs_vis, color); + } + + // Call breadth first search + template + inline void + dijkstra_shortest_paths_no_init + (const Graph& g, + typename graph_traits::vertex_descriptor s, + PredecessorMap predecessor, DistanceMap distance, WeightMap weight, + IndexMap index_map, + Compare compare, Combine combine, DistZero zero, + DijkstraVisitor vis, ColorMap color) + { + dijkstra_shortest_paths_no_init(g, &s, &s + 1, predecessor, distance, + weight, index_map, compare, combine, + zero, vis, color); + } + + // Initialize distances and call breadth first search with default color map + template + inline void + dijkstra_shortest_paths + (const VertexListGraph& g, + SourceInputIter s_begin, SourceInputIter s_end, + PredecessorMap predecessor, DistanceMap distance, WeightMap weight, + IndexMap index_map, + Compare compare, Combine combine, DistInf inf, DistZero zero, + DijkstraVisitor vis, + const bgl_named_params& + BOOST_GRAPH_ENABLE_IF_MODELS_PARM(VertexListGraph,vertex_list_graph_tag)) + { + boost::two_bit_color_map color(num_vertices(g), index_map); + dijkstra_shortest_paths(g, s_begin, s_end, predecessor, distance, weight, + index_map, compare, combine, inf, zero, vis, + color); + } + + // Initialize distances and call breadth first search with default color map + template + inline void + dijkstra_shortest_paths + (const VertexListGraph& g, + typename graph_traits::vertex_descriptor s, + PredecessorMap predecessor, DistanceMap distance, WeightMap weight, + IndexMap index_map, + Compare compare, Combine combine, DistInf inf, DistZero zero, + DijkstraVisitor vis, + const bgl_named_params& + BOOST_GRAPH_ENABLE_IF_MODELS_PARM(VertexListGraph,vertex_list_graph_tag)) + { + dijkstra_shortest_paths(g, &s, &s + 1, predecessor, distance, weight, + index_map, compare, combine, inf, zero, vis); + } + + // Initialize distances and call breadth first search + template + inline void + dijkstra_shortest_paths + (const VertexListGraph& g, + SourceInputIter s_begin, SourceInputIter s_end, + PredecessorMap predecessor, DistanceMap distance, WeightMap weight, + IndexMap index_map, + Compare compare, Combine combine, DistInf inf, DistZero zero, + DijkstraVisitor vis, ColorMap color) + { + typedef typename property_traits::value_type ColorValue; + typedef color_traits Color; + typename graph_traits::vertex_iterator ui, ui_end; + for (boost::tie(ui, ui_end) = vertices(g); ui != ui_end; ++ui) { + vis.initialize_vertex(*ui, g); + put(distance, *ui, inf); + put(predecessor, *ui, *ui); + put(color, *ui, Color::white()); + } + for (SourceInputIter it = s_begin; it != s_end; ++it) { + put(distance, *it, zero); + } + + dijkstra_shortest_paths_no_init(g, s_begin, s_end, predecessor, distance, + weight, index_map, compare, combine, zero, vis, + color); + } + + // Initialize distances and call breadth first search + template + inline void + dijkstra_shortest_paths + (const VertexListGraph& g, + typename graph_traits::vertex_descriptor s, + PredecessorMap predecessor, DistanceMap distance, WeightMap weight, + IndexMap index_map, + Compare compare, Combine combine, DistInf inf, DistZero zero, + DijkstraVisitor vis, ColorMap color) + { + dijkstra_shortest_paths(g, &s, &s + 1, predecessor, distance, weight, + index_map, compare, combine, inf, zero, + vis, color); + } + + // Initialize distances and call breadth first search + template + inline void + dijkstra_shortest_paths + (const VertexListGraph& g, + SourceInputIter s_begin, SourceInputIter s_end, + PredecessorMap predecessor, DistanceMap distance, WeightMap weight, + IndexMap index_map, + Compare compare, Combine combine, DistInf inf, DistZero zero, + DijkstraVisitor vis) + { + dijkstra_shortest_paths(g, s_begin, s_end, predecessor, distance, + weight, index_map, + compare, combine, inf, zero, vis, + no_named_parameters()); + } + + // Initialize distances and call breadth first search + template + inline void + dijkstra_shortest_paths + (const VertexListGraph& g, + typename graph_traits::vertex_descriptor s, + PredecessorMap predecessor, DistanceMap distance, WeightMap weight, + IndexMap index_map, + Compare compare, Combine combine, DistInf inf, DistZero zero, + DijkstraVisitor vis) + { + dijkstra_shortest_paths(g, &s, &s + 1, predecessor, distance, + weight, index_map, + compare, combine, inf, zero, vis); + } + + namespace detail { + + // Handle defaults for PredecessorMap and + // Distance Compare, Combine, Inf and Zero + template + inline void + dijkstra_dispatch2 + (const VertexListGraph& g, + typename graph_traits::vertex_descriptor s, + DistanceMap distance, WeightMap weight, IndexMap index_map, + const Params& params) + { + // Default for predecessor map + dummy_property_map p_map; + + typedef typename property_traits::value_type D; + D inf = choose_param(get_param(params, distance_inf_t()), + (std::numeric_limits::max)()); + + dijkstra_shortest_paths + (g, s, + choose_param(get_param(params, vertex_predecessor), p_map), + distance, weight, index_map, + choose_param(get_param(params, distance_compare_t()), + std::less()), + choose_param(get_param(params, distance_combine_t()), + closed_plus(inf)), + inf, + choose_param(get_param(params, distance_zero_t()), + D()), + choose_param(get_param(params, graph_visitor), + make_dijkstra_visitor(null_visitor())), + params); + } + + template + inline void + dijkstra_dispatch1 + (const VertexListGraph& g, + typename graph_traits::vertex_descriptor s, + DistanceMap distance, WeightMap weight, IndexMap index_map, + const Params& params) + { + // Default for distance map + typedef typename property_traits::value_type D; + typename std::vector::size_type + n = is_default_param(distance) ? num_vertices(g) : 1; + std::vector distance_map(n); + + detail::dijkstra_dispatch2 + (g, s, choose_param(distance, make_iterator_property_map + (distance_map.begin(), index_map, + distance_map[0])), + weight, index_map, params); + } + } // namespace detail + + // Named Parameter Variant + template + inline void + dijkstra_shortest_paths + (const VertexListGraph& g, + typename graph_traits::vertex_descriptor s, + const bgl_named_params& params) + { + // Default for edge weight and vertex index map is to ask for them + // from the graph. Default for the visitor is null_visitor. + detail::dijkstra_dispatch1 + (g, s, + get_param(params, vertex_distance), + choose_const_pmap(get_param(params, edge_weight), g, edge_weight), + choose_const_pmap(get_param(params, vertex_index), g, vertex_index), + params); + } + +} // namespace boost + +#ifdef BOOST_GRAPH_USE_MPI +# include +#endif + +#endif // BOOST_GRAPH_DIJKSTRA_HPP diff --git a/Envelope_3/include/CGAL/Envelope_3/Envelope_divide_and_conquer_3.h b/Envelope_3/include/CGAL/Envelope_3/Envelope_divide_and_conquer_3.h index 4324613238a..c6c004ece00 100644 --- a/Envelope_3/include/CGAL/Envelope_3/Envelope_divide_and_conquer_3.h +++ b/Envelope_3/include/CGAL/Envelope_3/Envelope_divide_and_conquer_3.h @@ -43,8 +43,7 @@ #ifdef CGAL_ENVELOPE_USE_BFS_FACE_ORDER #include #include -#include // Needed because BGL forgot it. -#include +#include #endif // this base divide & conquer algorithm splits the input into 2 groups, diff --git a/Installation/changes.html b/Installation/changes.html index 53c75e4555d..5d3e6226b38 100644 --- a/Installation/changes.html +++ b/Installation/changes.html @@ -230,6 +230,14 @@ and src/ directories).
  • Clean up the documentation of the concepts
  • +

    Point Set Processing

    +
      +
    • Workaround a bug in dijsktra shortest path of boost 1.54 by shipping + and using the boost header from the 1.55 release. This header will be used + only if you are using the version 1.54 of boost. +
    • +
    +

    Release 4.4

    diff --git a/Point_set_processing_3/examples/Point_set_processing_3/CMakeLists.txt b/Point_set_processing_3/examples/Point_set_processing_3/CMakeLists.txt index 49501a89822..969769f7bc6 100644 --- a/Point_set_processing_3/examples/Point_set_processing_3/CMakeLists.txt +++ b/Point_set_processing_3/examples/Point_set_processing_3/CMakeLists.txt @@ -46,9 +46,7 @@ if ( CGAL_FOUND ) # Executables that do *not* require EIGEN or LAPACK create_single_source_cgal_program( "average_spacing_example.cpp" ) create_single_source_cgal_program( "grid_simplification_example.cpp" ) - if(NOT Boost_VERSION EQUAL "105400") - create_single_source_cgal_program( "normals_example.cpp" ) - endif() + create_single_source_cgal_program( "normals_example.cpp" ) create_single_source_cgal_program( "property_map.cpp" ) create_single_source_cgal_program( "random_simplification_example.cpp" ) create_single_source_cgal_program( "read_write_xyz_point_set_example.cpp" ) diff --git a/Point_set_processing_3/include/CGAL/mst_orient_normals.h b/Point_set_processing_3/include/CGAL/mst_orient_normals.h index 6080b404a77..7ed54bbcb8d 100644 --- a/Point_set_processing_3/include/CGAL/mst_orient_normals.h +++ b/Point_set_processing_3/include/CGAL/mst_orient_normals.h @@ -35,13 +35,9 @@ #include #include -#include -#if BOOST_VERSION >= 104000 - #include -#else - #include -#endif +#include #include +#include // work around a bug in boost 1.54 #include namespace CGAL {