Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r67395 - in sandbox/geometry/boost/geometry: . algorithms/detail/overlay core multi multi/core
From: barend.gehrels_at_[hidden]
Date: 2010-12-21 16:24:19


Author: barendgehrels
Date: 2010-12-21 16:24:17 EST (Tue, 21 Dec 2010)
New Revision: 67395
URL: http://svn.boost.org/trac/boost/changeset/67395

Log:
Added multi/closure.hpp
Added:
   sandbox/geometry/boost/geometry/multi/core/closure.hpp (contents, props changed)
Text files modified:
   sandbox/geometry/boost/geometry/algorithms/detail/overlay/handle_tangencies.hpp | 5 +++--
   sandbox/geometry/boost/geometry/core/closure.hpp | 7 ++++++-
   sandbox/geometry/boost/geometry/geometry.hpp | 2 ++
   sandbox/geometry/boost/geometry/multi/core/point_order.hpp | 7 +++----
   sandbox/geometry/boost/geometry/multi/multi.hpp | 10 ++++++++++
   5 files changed, 24 insertions(+), 7 deletions(-)

Modified: sandbox/geometry/boost/geometry/algorithms/detail/overlay/handle_tangencies.hpp
==============================================================================
--- sandbox/geometry/boost/geometry/algorithms/detail/overlay/handle_tangencies.hpp (original)
+++ sandbox/geometry/boost/geometry/algorithms/detail/overlay/handle_tangencies.hpp 2010-12-21 16:24:17 EST (Tue, 21 Dec 2010)
@@ -217,9 +217,10 @@
         }
         else
         {
-//#ifdef BOOST_GEOMETRY_DEBUG_ENRICH
+#ifdef BOOST_GEOMETRY_DEBUG_ENRICH
+ // TODO: this still happens in the traverse.cpp test
             std::cout << " iu/ux unhandled" << std::endl;
-//#endif
+#endif
             ret = order == 1;
         }
 

Modified: sandbox/geometry/boost/geometry/core/closure.hpp
==============================================================================
--- sandbox/geometry/boost/geometry/core/closure.hpp (original)
+++ sandbox/geometry/boost/geometry/core/closure.hpp 2010-12-21 16:24:17 EST (Tue, 21 Dec 2010)
@@ -9,6 +9,7 @@
 #define BOOST_GEOMETRY_CORE_CLOSURE_HPP
 
 
+#include <boost/mpl/assert.hpp>
 #include <boost/range.hpp>
 #include <boost/type_traits/remove_const.hpp>
 
@@ -51,7 +52,11 @@
 template <typename Tag, typename Geometry>
 struct closure
 {
- static const closure_selector value = closed;
+ BOOST_MPL_ASSERT_MSG
+ (
+ false, NOT_IMPLEMENTED_FOR_THIS_GEOMETRY_TYPE
+ , (types<Geometry>)
+ );
 };
 
 

Modified: sandbox/geometry/boost/geometry/geometry.hpp
==============================================================================
--- sandbox/geometry/boost/geometry/geometry.hpp (original)
+++ sandbox/geometry/boost/geometry/geometry.hpp 2010-12-21 16:24:17 EST (Tue, 21 Dec 2010)
@@ -41,6 +41,7 @@
 #include <boost/geometry/algorithms/convert.hpp>
 #include <boost/geometry/algorithms/convex_hull.hpp>
 #include <boost/geometry/algorithms/correct.hpp>
+#include <boost/geometry/algorithms/difference.hpp>
 #include <boost/geometry/algorithms/dissolve.hpp>
 #include <boost/geometry/algorithms/distance.hpp>
 #include <boost/geometry/algorithms/envelope.hpp>
@@ -53,6 +54,7 @@
 #include <boost/geometry/algorithms/perimeter.hpp>
 #include <boost/geometry/algorithms/reverse.hpp>
 #include <boost/geometry/algorithms/simplify.hpp>
+#include <boost/geometry/algorithms/sym_difference.hpp>
 #include <boost/geometry/algorithms/transform.hpp>
 #include <boost/geometry/algorithms/union.hpp>
 #include <boost/geometry/algorithms/unique.hpp>

Added: sandbox/geometry/boost/geometry/multi/core/closure.hpp
==============================================================================
--- (empty file)
+++ sandbox/geometry/boost/geometry/multi/core/closure.hpp 2010-12-21 16:24:17 EST (Tue, 21 Dec 2010)
@@ -0,0 +1,47 @@
+// Boost.Geometry (aka GGL, Generic Geometry Library)
+//
+// Copyright Barend Gehrels 2010, Geodan, Amsterdam, the Netherlands.
+// Use, modification and distribution is subject to 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)
+
+#ifndef BOOST_GEOMETRY_MULTI_CORE_CLOSURE_HPP
+#define BOOST_GEOMETRY_MULTI_CORE_CLOSURE_HPP
+
+
+#include <boost/mpl/assert.hpp>
+#include <boost/range.hpp>
+#include <boost/type_traits/remove_const.hpp>
+
+#include <boost/geometry/core/closure.hpp>
+#include <boost/geometry/multi/core/tags.hpp>
+
+namespace boost { namespace geometry
+{
+
+
+#ifndef DOXYGEN_NO_DISPATCH
+namespace core_dispatch
+{
+
+
+// Specialization for polygon: the closure is the closure of its rings
+template <typename MultiPolygon>
+struct closure<multi_polygon_tag, MultiPolygon>
+{
+ static const closure_selector value = core_dispatch::closure
+ <
+ polygon_tag,
+ typename boost::range_value<MultiPolygon>::type
+ >::value ;
+};
+
+
+} // namespace core_dispatch
+#endif // DOXYGEN_NO_DISPATCH
+
+
+}} // namespace boost::geometry
+
+
+#endif // BOOST_GEOMETRY_MULTI_CORE_CLOSURE_HPP

Modified: sandbox/geometry/boost/geometry/multi/core/point_order.hpp
==============================================================================
--- sandbox/geometry/boost/geometry/multi/core/point_order.hpp (original)
+++ sandbox/geometry/boost/geometry/multi/core/point_order.hpp 2010-12-21 16:24:17 EST (Tue, 21 Dec 2010)
@@ -12,8 +12,7 @@
 #include <boost/range.hpp>
 
 #include <boost/geometry/core/point_order.hpp>
-#include <boost/geometry/core/tag.hpp>
-#include <boost/geometry/core/tags.hpp>
+#include <boost/geometry/multi/core/tags.hpp>
 
 namespace boost { namespace geometry
 {
@@ -24,11 +23,11 @@
 {
 
 template <typename Multi>
-struct point_order<multi_point_tag, Multi>
+struct point_order<multi_point_tag, Multi>
     : public detail::point_order::clockwise {};
 
 template <typename Multi>
-struct point_order<multi_linestring_tag, Multi>
+struct point_order<multi_linestring_tag, Multi>
     : public detail::point_order::clockwise {};
 
 

Modified: sandbox/geometry/boost/geometry/multi/multi.hpp
==============================================================================
--- sandbox/geometry/boost/geometry/multi/multi.hpp (original)
+++ sandbox/geometry/boost/geometry/multi/multi.hpp 2010-12-21 16:24:17 EST (Tue, 21 Dec 2010)
@@ -11,10 +11,13 @@
 #define BOOST_GEOMETRY_MULTI_HPP
 
 
+#include <boost/geometry/multi/core/closure.hpp>
 #include <boost/geometry/multi/core/geometry_id.hpp>
+#include <boost/geometry/multi/core/is_areal.hpp>
 #include <boost/geometry/multi/core/is_multi.hpp>
 #include <boost/geometry/multi/core/interior_rings.hpp>
 #include <boost/geometry/multi/core/num_geometries.hpp>
+#include <boost/geometry/multi/core/point_order.hpp>
 #include <boost/geometry/multi/core/point_type.hpp>
 #include <boost/geometry/multi/core/ring_type.hpp>
 #include <boost/geometry/multi/core/tags.hpp>
@@ -23,6 +26,7 @@
 
 #include <boost/geometry/multi/algorithms/area.hpp>
 #include <boost/geometry/multi/algorithms/centroid.hpp>
+#include <boost/geometry/multi/algorithms/clear.hpp>
 #include <boost/geometry/multi/algorithms/convex_hull.hpp>
 #include <boost/geometry/multi/algorithms/correct.hpp>
 #include <boost/geometry/multi/algorithms/dissolve.hpp>
@@ -34,6 +38,7 @@
 #include <boost/geometry/multi/algorithms/length.hpp>
 #include <boost/geometry/multi/algorithms/num_points.hpp>
 #include <boost/geometry/multi/algorithms/perimeter.hpp>
+#include <boost/geometry/multi/algorithms/reverse.hpp>
 #include <boost/geometry/multi/algorithms/simplify.hpp>
 #include <boost/geometry/multi/algorithms/transform.hpp>
 #include <boost/geometry/multi/algorithms/union.hpp>
@@ -43,9 +48,14 @@
 #include <boost/geometry/multi/algorithms/detail/modify_with_predicate.hpp>
 #include <boost/geometry/multi/algorithms/detail/multi_sum.hpp>
 
+#include <boost/geometry/multi/algorithms/detail/sections/range_by_section.hpp>
 #include <boost/geometry/multi/algorithms/detail/sections/sectionalize.hpp>
 
+#include <boost/geometry/multi/algorithms/detail/overlay/add_to_containment.hpp>
+#include <boost/geometry/multi/algorithms/detail/overlay/copy_segment_point.hpp>
 #include <boost/geometry/multi/algorithms/detail/overlay/copy_segments.hpp>
+#include <boost/geometry/multi/algorithms/detail/overlay/get_ring.hpp>
+#include <boost/geometry/multi/algorithms/detail/overlay/get_turns.hpp>
 #include <boost/geometry/multi/algorithms/detail/overlay/self_turn_points.hpp>
 
 #include <boost/geometry/multi/geometries/multi_point.hpp>


Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk