diff options
Diffstat (limited to 'boost/geometry/algorithms/detail/is_valid/multipolygon.hpp')
-rw-r--r-- | boost/geometry/algorithms/detail/is_valid/multipolygon.hpp | 22 |
1 files changed, 16 insertions, 6 deletions
diff --git a/boost/geometry/algorithms/detail/is_valid/multipolygon.hpp b/boost/geometry/algorithms/detail/is_valid/multipolygon.hpp index 8fe5803323..e2facb7e37 100644 --- a/boost/geometry/algorithms/detail/is_valid/multipolygon.hpp +++ b/boost/geometry/algorithms/detail/is_valid/multipolygon.hpp @@ -1,6 +1,6 @@ // Boost.Geometry (aka GGL, Generic Geometry Library) -// Copyright (c) 2014-2017, Oracle and/or its affiliates. +// Copyright (c) 2014-2019, Oracle and/or its affiliates. // Contributed and/or modified by Menelaos Karavelas, on behalf of Oracle // Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle @@ -119,6 +119,9 @@ private: typedef typename Strategy::envelope_strategy_type envelope_strategy_type; envelope_strategy_type const envelope_strategy = strategy.get_envelope_strategy(); + typedef typename Strategy::disjoint_box_box_strategy_type disjoint_box_box_strategy_type; + disjoint_box_box_strategy_type const disjoint_strategy + = strategy.get_disjoint_box_box_strategy(); // call partition to check if polygons are disjoint from each other typename base::template item_visitor_type<Strategy> item_visitor(strategy); @@ -127,8 +130,15 @@ private: < geometry::model::box<typename point_type<MultiPolygon>::type> >::apply(polygon_iterators, item_visitor, - typename base::template expand_box<envelope_strategy_type>(envelope_strategy), - typename base::template overlaps_box<envelope_strategy_type>(envelope_strategy)); + typename base::template expand_box + < + envelope_strategy_type + >(envelope_strategy), + typename base::template overlaps_box + < + envelope_strategy_type, + disjoint_box_box_strategy_type + >(envelope_strategy, disjoint_strategy)); if (item_visitor.items_overlap) { @@ -283,8 +293,8 @@ public: { typedef debug_validity_phase<MultiPolygon> debug_phase; - if (BOOST_GEOMETRY_CONDITION( - AllowEmptyMultiGeometries && boost::empty(multipolygon))) + if (BOOST_GEOMETRY_CONDITION(AllowEmptyMultiGeometries) + && boost::empty(multipolygon)) { return visitor.template apply<no_failure>(); } @@ -307,7 +317,7 @@ public: // compute turns and check if all are acceptable debug_phase::apply(2); - typedef has_valid_self_turns<MultiPolygon> has_valid_turns; + typedef has_valid_self_turns<MultiPolygon, typename Strategy::cs_tag> has_valid_turns; std::deque<typename has_valid_turns::turn_type> turns; bool has_invalid_turns = |