summaryrefslogtreecommitdiff
path: root/boost/geometry/algorithms/detail/buffer/buffer_policies.hpp
diff options
context:
space:
mode:
authorDongHun Kwak <dh0128.kwak@samsung.com>2016-10-06 10:38:45 +0900
committerDongHun Kwak <dh0128.kwak@samsung.com>2016-10-06 10:39:52 +0900
commit5cde13f21d36c7224b0e13d11c4b49379ae5210d (patch)
treee8269ac85a4b0f7d416e2565fa4f451b5cb41351 /boost/geometry/algorithms/detail/buffer/buffer_policies.hpp
parentd9ec475d945d3035377a0d89ed42e382d8988891 (diff)
downloadboost-5cde13f21d36c7224b0e13d11c4b49379ae5210d.tar.gz
boost-5cde13f21d36c7224b0e13d11c4b49379ae5210d.tar.bz2
boost-5cde13f21d36c7224b0e13d11c4b49379ae5210d.zip
Imported Upstream version 1.61.0
Change-Id: I96a1f878d1e6164f01e9aadd5147f38fca448d90 Signed-off-by: DongHun Kwak <dh0128.kwak@samsung.com>
Diffstat (limited to 'boost/geometry/algorithms/detail/buffer/buffer_policies.hpp')
-rw-r--r--boost/geometry/algorithms/detail/buffer/buffer_policies.hpp56
1 files changed, 51 insertions, 5 deletions
diff --git a/boost/geometry/algorithms/detail/buffer/buffer_policies.hpp b/boost/geometry/algorithms/detail/buffer/buffer_policies.hpp
index 255ac797dc..c0fa7b0e33 100644
--- a/boost/geometry/algorithms/detail/buffer/buffer_policies.hpp
+++ b/boost/geometry/algorithms/detail/buffer/buffer_policies.hpp
@@ -46,15 +46,26 @@ class backtrack_for_buffer
public :
typedef detail::overlay::backtrack_state state_type;
- template <typename Operation, typename Rings, typename Turns, typename Geometry, typename RobustPolicy>
+ template
+ <
+ typename Operation,
+ typename Rings,
+ typename Turns,
+ typename Geometry,
+ typename RobustPolicy,
+ typename Visitor
+ >
static inline void apply(std::size_t size_at_start,
Rings& rings, typename boost::range_value<Rings>::type& ring,
- Turns& turns, Operation& operation,
- std::string const& /*reason*/,
+ Turns& turns,
+ typename boost::range_value<Turns>::type const& turn,
+ Operation& operation,
+ detail::overlay::traverse_error_type traverse_error,
Geometry const& ,
Geometry const& ,
RobustPolicy const& ,
- state_type& state
+ state_type& state,
+ Visitor& visitor
)
{
#if defined(BOOST_GEOMETRY_COUNT_BACKTRACK_WARNINGS)
@@ -62,7 +73,7 @@ extern int g_backtrack_warning_count;
g_backtrack_warning_count++;
#endif
//std::cout << "!";
-//std::cout << "WARNING " << reason << std::endl;
+//std::cout << "WARNING " << traverse_error_string(traverse_error) << std::endl;
state.m_good = false;
@@ -78,6 +89,41 @@ g_backtrack_warning_count++;
}
};
+struct buffer_overlay_visitor
+{
+public :
+ void print(char const* header)
+ {
+ }
+
+ template <typename Turns>
+ void print(char const* header, Turns const& turns, int turn_index)
+ {
+ }
+
+ template <typename Turns>
+ void print(char const* header, Turns const& turns, int turn_index, int op_index)
+ {
+ }
+
+ template <typename Turns>
+ void visit_turns(int , Turns const& ) {}
+
+ template <typename Clusters, typename Turns>
+ void visit_clusters(Clusters const& , Turns const& ) {}
+
+ template <typename Turns, typename Turn, typename Operation>
+ void visit_traverse(Turns const& turns, Turn const& turn, Operation const& op, const char* header)
+ {
+ }
+
+ template <typename Turns, typename Turn, typename Operation>
+ void visit_traverse_reject(Turns const& , Turn const& , Operation const& ,
+ detail::overlay::traverse_error_type )
+ {}
+};
+
+
// Should follow traversal-turn-concept (enrichment, visit structure)
// and adds index in piece vector to find it back
template <typename Point, typename SegmentRatio>