![]() |
Boost-Commit : |
Subject: [Boost-commit] svn:boost r83918 - in branches/release: boost/polygon boost/polygon/detail libs/polygon/doc libs/polygon/doc/images libs/polygon/example/input_data/primary libs/polygon/example/output_data/primary libs/polygon/test
From: sydorchuk.andriy_at_[hidden]
Date: 2013-04-15 18:27:51
Author: asydorchuk
Date: 2013-04-15 18:27:46 EDT (Mon, 15 Apr 2013)
New Revision: 83918
URL: http://svn.boost.org/trac/boost/changeset/83918
Log:
[Polygon] Merging from trunk for the upcoming release: 1) Updated Voronoi documentation. 2) Fixed #8026, #8197, #8257.
Added:
branches/release/libs/polygon/doc/images/voronoi1.png (contents, props changed)
branches/release/libs/polygon/example/input_data/primary/primary_072.txt (contents, props changed)
branches/release/libs/polygon/example/output_data/primary/primary_072.png (contents, props changed)
Removed:
branches/release/libs/polygon/doc/voronoi_predicates.htm
branches/release/libs/polygon/doc/voronoi_robust_fpt.htm
Text files modified:
branches/release/boost/polygon/detail/boolean_op_45.hpp | 6
branches/release/boost/polygon/detail/polygon_45_set_view.hpp | 9
branches/release/boost/polygon/detail/polygon_set_view.hpp | 5
branches/release/boost/polygon/detail/scan_arbitrary.hpp | 11
branches/release/boost/polygon/detail/voronoi_predicates.hpp | 11
branches/release/boost/polygon/gtl.hpp | 12
branches/release/boost/polygon/polygon_45_set_data.hpp | 6
branches/release/boost/polygon/polygon_traits.hpp | 3
branches/release/boost/polygon/voronoi.hpp | 36
branches/release/boost/polygon/voronoi_diagram.hpp | 2
branches/release/libs/polygon/doc/analysis.htm | 296 +++---
branches/release/libs/polygon/doc/gtl_connectivity_extraction.htm | 308 +++---
branches/release/libs/polygon/doc/gtl_connectivity_extraction_45.htm | 308 +++---
branches/release/libs/polygon/doc/gtl_connectivity_extraction_90.htm | 308 +++---
branches/release/libs/polygon/doc/gtl_coordinate_concept.htm | 301 +++---
branches/release/libs/polygon/doc/gtl_custom_point.htm | 26
branches/release/libs/polygon/doc/gtl_design_overview.htm | 398 ++++----
branches/release/libs/polygon/doc/gtl_interval_concept.htm | 1073 ++++++++++++-----------
branches/release/libs/polygon/doc/gtl_isotropy.htm | 1061 ++++++++++++-----------
branches/release/libs/polygon/doc/gtl_point_concept.htm | 886 +++++++++++--------
branches/release/libs/polygon/doc/gtl_polygon_45_concept.htm | 738 ++++++++-------
branches/release/libs/polygon/doc/gtl_polygon_45_set_concept.htm | 1522 +++++++++++++++++----------------
branches/release/libs/polygon/doc/gtl_polygon_45_with_holes_concept.htm | 820 +++++++++--------
branches/release/libs/polygon/doc/gtl_polygon_90_concept.htm | 824 +++++++++--------
branches/release/libs/polygon/doc/gtl_polygon_90_set_concept.htm | 1795 +++++++++++++++++++++------------------
branches/release/libs/polygon/doc/gtl_polygon_90_with_holes_concept.htm | 924 ++++++++++---------
branches/release/libs/polygon/doc/gtl_polygon_concept.htm | 741 ++++++++-------
branches/release/libs/polygon/doc/gtl_polygon_set_concept.htm | 1324 +++++++++++++++--------------
branches/release/libs/polygon/doc/gtl_polygon_with_holes_concept.htm | 817 +++++++++--------
branches/release/libs/polygon/doc/gtl_property_merge.htm | 315 +++---
branches/release/libs/polygon/doc/gtl_property_merge_45.htm | 314 +++---
branches/release/libs/polygon/doc/gtl_property_merge_90.htm | 314 +++---
branches/release/libs/polygon/doc/gtl_rectangle_concept.htm | 1548 ++++++++++++++++++----------------
branches/release/libs/polygon/doc/gtl_segment_concept.htm | 737 ++++++++++-----
branches/release/libs/polygon/doc/index.htm | 534 +++++-----
branches/release/libs/polygon/doc/voronoi_benchmark.htm | 296 +++--
branches/release/libs/polygon/doc/voronoi_builder.htm | 388 ++++----
branches/release/libs/polygon/doc/voronoi_diagram.htm | 1101 ++++++++++++------------
branches/release/libs/polygon/doc/voronoi_main.htm | 584 +++++++-----
branches/release/libs/polygon/test/gtl_boost_unit_test.cpp | 4
40 files changed, 11071 insertions(+), 9635 deletions(-)
Modified: branches/release/boost/polygon/detail/boolean_op_45.hpp
==============================================================================
--- branches/release/boost/polygon/detail/boolean_op_45.hpp (original)
+++ branches/release/boost/polygon/detail/boolean_op_45.hpp 2013-04-15 18:27:46 EDT (Mon, 15 Apr 2013)
@@ -370,6 +370,7 @@
template <int op>
static bool applyLogic(Count2 count) {
#ifdef BOOST_POLYGON_MSVC
+#pragma warning (push)
#pragma warning (disable: 4127)
#endif
if(op == 0) { //apply or
@@ -383,7 +384,7 @@
} else
return false;
#ifdef BOOST_POLYGON_MSVC
-#pragma warning (default: 4127)
+#pragma warning (pop)
#endif
}
@@ -405,6 +406,7 @@
template <int op>
static bool applyLogic(Count1 count) {
#ifdef BOOST_POLYGON_MSVC
+#pragma warning (push)
#pragma warning (disable: 4127)
#endif
if(op == 0) { //apply or
@@ -416,7 +418,7 @@
} else
return false;
#ifdef BOOST_POLYGON_MSVC
-#pragma warning (default: 4127)
+#pragma warning (pop)
#endif
}
Modified: branches/release/boost/polygon/detail/polygon_45_set_view.hpp
==============================================================================
--- branches/release/boost/polygon/detail/polygon_45_set_view.hpp (original)
+++ branches/release/boost/polygon/detail/polygon_45_set_view.hpp 2013-04-15 18:27:46 EDT (Mon, 15 Apr 2013)
@@ -39,6 +39,7 @@
rinput_.set(polygon_45_set_traits<rtype>::begin(rvalue_),
polygon_45_set_traits<rtype>::end(rvalue_));
#ifdef BOOST_POLYGON_MSVC
+#pragma warning (push)
#pragma warning (disable: 4127)
#endif
if(op_type == 0)
@@ -50,7 +51,7 @@
else
output_ -= rinput_;
#ifdef BOOST_POLYGON_MSVC
-#pragma warning (default: 4127)
+#pragma warning (pop)
#endif
}
};
@@ -62,6 +63,7 @@
output_.set(polygon_45_set_traits<ltype>::begin(lvalue_),
polygon_45_set_traits<ltype>::end(lvalue_));
#ifdef BOOST_POLYGON_MSVC
+#pragma warning (push)
#pragma warning (disable: 4127)
#endif
if(op_type == 0)
@@ -73,7 +75,7 @@
else
output_ -= rvalue_;
#ifdef BOOST_POLYGON_MSVC
-#pragma warning (default: 4127)
+#pragma warning (pop)
#endif
}
};
@@ -153,6 +155,7 @@
rinput_.set(polygon_45_set_traits<rtype>::begin(rvalue_),
polygon_45_set_traits<rtype>::end(rvalue_));
#ifdef BOOST_POLYGON_MSVC
+#pragma warning (push)
#pragma warning (disable: 4127)
#endif
if(op_type == 0)
@@ -164,7 +167,7 @@
else
output_ -= rinput_;
#ifdef BOOST_POLYGON_MSVC
-#pragma warning (default: 4127)
+#pragma warning (pop)
#endif
polygon_45_set_mutable_traits<geometry_type_1>::set(lvalue_, output_.begin(), output_.end());
return lvalue_;
Modified: branches/release/boost/polygon/detail/polygon_set_view.hpp
==============================================================================
--- branches/release/boost/polygon/detail/polygon_set_view.hpp (original)
+++ branches/release/boost/polygon/detail/polygon_set_view.hpp 2013-04-15 18:27:46 EDT (Mon, 15 Apr 2013)
@@ -13,7 +13,7 @@
template <typename coordinate_type>
inline void polygon_set_data<coordinate_type>::clean() const {
if(dirty_) {
- polygon_45_set_data<coordinate_type> tmp;
+ //polygon_45_set_data<coordinate_type> tmp;
//very important:
//the 45 degree algorithm does not satisfy
//the precondition of arbitrary polygon formation
@@ -102,6 +102,7 @@
// if(linput_.downcast(l45) && rinput_.downcast(r45)) {
// //the op codes are screwed up between 45 and arbitrary
//#ifdef BOOST_POLYGON_MSVC
+//#pragma warning (push)
//#pragma warning (disable: 4127)
//#endif
// if(op_type < 2)
@@ -111,7 +112,7 @@
// else
// l45.template applyAdaptiveBoolean_<2>(o45, r45);
//#ifdef BOOST_POLYGON_MSVC
-//#pragma warning (default: 4127)
+//#pragma warning (pop)
//#endif
// output_.insert(o45);
// } else {
Modified: branches/release/boost/polygon/detail/scan_arbitrary.hpp
==============================================================================
--- branches/release/boost/polygon/detail/scan_arbitrary.hpp (original)
+++ branches/release/boost/polygon/detail/scan_arbitrary.hpp 2013-04-15 18:27:46 EDT (Mon, 15 Apr 2013)
@@ -1038,7 +1038,8 @@
bool first_iteration = true;
//we want to return from inside the loop when we hit end or new x
#ifdef BOOST_POLYGON_MSVC
-#pragma warning( disable: 4127 )
+#pragma warning (push)
+#pragma warning (disable: 4127)
#endif
while(true) {
if(begin == end || (!first_iteration && ((*begin).first.first.get(VERTICAL) != y ||
@@ -1146,7 +1147,7 @@
}
}
#ifdef BOOST_POLYGON_MSVC
-#pragma warning( default: 4127 )
+#pragma warning (pop)
#endif
}
@@ -2292,11 +2293,12 @@
stdcout << polys[j] << "\n";
stdcout << polys90[j] << "\n";
#ifdef BOOST_POLYGON_ICC
+#pragma warning (push)
#pragma warning (disable:1572)
#endif
if(area(polys[j]) != area(polys90[j])) {
#ifdef BOOST_POLYGON_ICC
-#pragma warning (default:1572)
+#pragma warning (pop)
#endif
stdcout << "merge failed with area mismatch\n";
failed = true;
@@ -2539,6 +2541,7 @@
if(edge.second < edge.first) elem.second *= -1;
if(scanline_base<Unit>::is_vertical(edge)) elem.second *= -1;
#ifdef BOOST_POLYGON_MSVC
+#pragma warning (push)
#pragma warning (disable: 4127)
#endif
if(op_type == 0) { //OR
@@ -2569,7 +2572,7 @@
}
}
#ifdef BOOST_POLYGON_MSVC
-#pragma warning (default: 4127)
+#pragma warning (pop)
#endif
if(right.size() == 1) {
if((*(right.begin())) == 0) {
Modified: branches/release/boost/polygon/detail/voronoi_predicates.hpp
==============================================================================
--- branches/release/boost/polygon/detail/voronoi_predicates.hpp (original)
+++ branches/release/boost/polygon/detail/voronoi_predicates.hpp 2013-04-15 18:27:46 EDT (Mon, 15 Apr 2013)
@@ -35,7 +35,8 @@
enum {
ULPS = 64,
- ULPSx2 = 128
+ ULPSx2 = 128,
+ ULPSx5 = 320
};
template <typename Point>
@@ -160,21 +161,21 @@
bool operator()(const site_type& lhs, const circle_type& rhs) const {
typename ulp_cmp_type::Result xCmp =
- ulp_cmp(to_fpt(lhs.x()), to_fpt(rhs.lower_x()), ULPS);
+ ulp_cmp(to_fpt(lhs.x()), to_fpt(rhs.lower_x()), ULPSx5);
if (xCmp != ulp_cmp_type::EQUAL)
return xCmp == ulp_cmp_type::LESS;
typename ulp_cmp_type::Result yCmp =
- ulp_cmp(to_fpt(lhs.y()), to_fpt(rhs.lower_y()), ULPS);
+ ulp_cmp(to_fpt(lhs.y()), to_fpt(rhs.lower_y()), ULPSx5);
return yCmp == ulp_cmp_type::LESS;
}
bool operator()(const circle_type& lhs, const site_type& rhs) const {
typename ulp_cmp_type::Result xCmp =
- ulp_cmp(to_fpt(lhs.lower_x()), to_fpt(rhs.x()), ULPS);
+ ulp_cmp(to_fpt(lhs.lower_x()), to_fpt(rhs.x()), ULPSx5);
if (xCmp != ulp_cmp_type::EQUAL)
return xCmp == ulp_cmp_type::LESS;
typename ulp_cmp_type::Result yCmp =
- ulp_cmp(to_fpt(lhs.lower_y()), to_fpt(rhs.y()), ULPS);
+ ulp_cmp(to_fpt(lhs.lower_y()), to_fpt(rhs.y()), ULPSx5);
return yCmp == ulp_cmp_type::LESS;
}
Modified: branches/release/boost/polygon/gtl.hpp
==============================================================================
--- branches/release/boost/polygon/gtl.hpp (original)
+++ branches/release/boost/polygon/gtl.hpp 2013-04-15 18:27:46 EDT (Mon, 15 Apr 2013)
@@ -9,10 +9,12 @@
#define GTL_GTL_HPP
#ifdef __ICC
+#pragma warning (push)
#pragma warning (disable:1125)
#endif
#ifdef WIN32
+#pragma warning (push)
#pragma warning( disable: 4996 )
#pragma warning( disable: 4800 )
#endif
@@ -21,7 +23,13 @@
#include "polygon.hpp"
namespace gtl = boost::polygon;
using namespace boost::polygon::operators;
-#if __ICC
-#pragma warning (default:1125)
+
+#ifdef WIN32
+#pragma warning (pop)
+#endif
+
+#ifdef __ICC
+#pragma warning (pop)
#endif
+
#endif
Modified: branches/release/boost/polygon/polygon_45_set_data.hpp
==============================================================================
--- branches/release/boost/polygon/polygon_45_set_data.hpp (original)
+++ branches/release/boost/polygon/polygon_45_set_data.hpp 2013-04-15 18:27:46 EDT (Mon, 15 Apr 2013)
@@ -1551,6 +1551,7 @@
l90sd.sort();
r90sd.sort();
#ifdef BOOST_POLYGON_MSVC
+#pragma warning (push)
#pragma warning (disable: 4127)
#endif
if(op == 0) {
@@ -1567,7 +1568,7 @@
r90sd.begin(), r90sd.end(), boolean_op::BinaryCount<boolean_op::BinaryXor>());
}
#ifdef BOOST_POLYGON_MSVC
-#pragma warning (default: 4127)
+#pragma warning (pop)
#endif
result.data_.clear();
result.insert(output);
@@ -1678,6 +1679,7 @@
}
l90sd.sort();
#ifdef BOOST_POLYGON_MSVC
+#pragma warning (push)
#pragma warning (disable: 4127)
#endif
if(op == 0) {
@@ -1688,7 +1690,7 @@
l90sd.self_xor();
}
#ifdef BOOST_POLYGON_MSVC
-#pragma warning (default: 4127)
+#pragma warning (pop)
#endif
result.data_.clear();
result.insert(l90sd);
Modified: branches/release/boost/polygon/polygon_traits.hpp
==============================================================================
--- branches/release/boost/polygon/polygon_traits.hpp (original)
+++ branches/release/boost/polygon/polygon_traits.hpp 2013-04-15 18:27:46 EDT (Mon, 15 Apr 2013)
@@ -985,11 +985,12 @@
area_type x1 = (area_type)x(previous);
area_type x2 = (area_type)x(*begin_range);
#ifdef BOOST_POLYGON_ICC
+#pragma warning (push)
#pragma warning (disable:1572)
#endif
if(x1 != x2) {
#ifdef BOOST_POLYGON_ICC
-#pragma warning (default:1572)
+#pragma warning (pop)
#endif
// do trapezoid area accumulation
area += (x2 - x1) * (((area_type)y(*begin_range) - y_base) +
Modified: branches/release/boost/polygon/voronoi.hpp
==============================================================================
--- branches/release/boost/polygon/voronoi.hpp (original)
+++ branches/release/boost/polygon/voronoi.hpp 2013-04-15 18:27:46 EDT (Mon, 15 Apr 2013)
@@ -17,10 +17,10 @@
#include "voronoi_builder.hpp"
#include "voronoi_diagram.hpp"
-// Public methods to compute Voronoi diagram.
+// Public methods to compute Voronoi diagram of a set of points and segments.
// Coordinates of the points and of the endpoints of the segments should belong
// to the 32-bit signed integer range [-2^31, 2^31-1]. To use wider input
-// coordinate range voronoi_builder configuration via coordinate type traits is
+// coordinate range voronoi_builder configuration via coordinate type traits
// is required.
// Complexity - O(N*logN), memory usage - O(N), N - number of input objects.
namespace boost {
@@ -34,8 +34,7 @@
>::type
>::type,
std::size_t
->::type
-insert(const Point& point, VB* vb) {
+>::type insert(const Point& point, VB* vb) {
return vb->insert_point(x(point), y(point));
}
@@ -49,8 +48,7 @@
>::type
>::type,
void
->::type
-insert(PointIterator first, const PointIterator last, VB* vb) {
+>::type insert(const PointIterator first, const PointIterator last, VB* vb) {
for (PointIterator it = first; it != last; ++it) {
insert(*it, vb);
}
@@ -64,8 +62,7 @@
>::type
>::type,
std::size_t
->::type
-insert(const Segment& segment, VB* vb) {
+>::type insert(const Segment& segment, VB* vb) {
return vb->insert_segment(
x(low(segment)), y(low(segment)),
x(high(segment)), y(high(segment)));
@@ -81,8 +78,9 @@
>::type
>::type,
void
->::type
-insert(SegmentIterator first, SegmentIterator last, VB* vb) {
+>::type insert(const SegmentIterator first,
+ const SegmentIterator last,
+ VB* vb) {
for (SegmentIterator it = first; it != last; ++it) {
insert(*it, vb);
}
@@ -98,8 +96,9 @@
>::type
>::type,
void
->::type
-construct_voronoi(PointIterator first, PointIterator last, VD* vd) {
+>::type construct_voronoi(const PointIterator first,
+ const PointIterator last,
+ VD* vd) {
default_voronoi_builder builder;
insert(first, last, &builder);
builder.construct(vd);
@@ -115,8 +114,9 @@
>::type
>::type,
void
->::type
-construct_voronoi(SegmentIterator first, SegmentIterator last, VD* vd) {
+>::type construct_voronoi(const SegmentIterator first,
+ const SegmentIterator last,
+ VD* vd) {
default_voronoi_builder builder;
insert(first, last, &builder);
builder.construct(vd);
@@ -141,9 +141,11 @@
>::type
>::type,
void
->::type
-construct_voronoi(PointIterator p_first, PointIterator p_last,
- SegmentIterator s_first, SegmentIterator s_last, VD* vd) {
+>::type construct_voronoi(const PointIterator p_first,
+ const PointIterator p_last,
+ const SegmentIterator s_first,
+ const SegmentIterator s_last,
+ VD* vd) {
default_voronoi_builder builder;
insert(p_first, p_last, &builder);
insert(s_first, s_last, &builder);
Modified: branches/release/boost/polygon/voronoi_diagram.hpp
==============================================================================
--- branches/release/boost/polygon/voronoi_diagram.hpp (original)
+++ branches/release/boost/polygon/voronoi_diagram.hpp 2013-04-15 18:27:46 EDT (Mon, 15 Apr 2013)
@@ -328,7 +328,7 @@
return vertices_.size();
}
- void _reserve(int num_sites) {
+ void _reserve(std::size_t num_sites) {
cells_.reserve(num_sites);
vertices_.reserve(num_sites << 1);
edges_.reserve((num_sites << 2) + (num_sites << 1));
Modified: branches/release/libs/polygon/doc/analysis.htm
==============================================================================
--- branches/release/libs/polygon/doc/analysis.htm (original)
+++ branches/release/libs/polygon/doc/analysis.htm 2013-04-15 18:27:46 EDT (Mon, 15 Apr 2013)
@@ -1,20 +1,28 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"><head><!--
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
+<head>
+<!--
Copyright 2009-2010 Intel Corporation
license banner
---><title>Boost Polygon Library: Performance Analysis</title>
-
-
-
- <meta http-equiv="content-type" content="text/html;charset=ISO-8859-1" /><!-- <link type="text/css" rel="stylesheet" href="adobe_source.css"> --></head><body><table style="margin: 0pt; padding: 0pt; width: 100%;" border="0" cellpadding="0" cellspacing="0"><tbody><tr>
-<td style="background-color: rgb(238, 238, 238);" nowrap="1" valign="top">
- <div style="padding: 5px;" align="center">
- <img src="images/boost.png" border="0" height="86" width="277" /><a title="www.boost.org home page" href="http://www.boost.org/" tabindex="2" style="border: medium none ;">
- </a>
- </div>
- <div style="margin: 5px;">
- <h3 class="navbar">Contents</h3>
- <ul>
+-->
+ <title>Boost Polygon Library: Performance Analysis</title>
+ <meta http-equiv="content-type" content="text/html;charset=ISO-8859-1" />
+<!-- <link type="text/css" rel="stylesheet" href="adobe_source.css"> -->
+</head>
+<body>
+<table style="margin: 0pt; padding: 0pt; width: 100%;" border="0"
+ cellpadding="0" cellspacing="0">
+ <tbody>
+ <tr>
+ <td style="background-color: rgb(238, 238, 238);" nowrap="1"
+ valign="top">
+ <div style="padding: 5px;" align="center"> <img
+ src="images/boost.png" border="0" height="86" width="277" /><a
+ title="www.boost.org home page" href="http://www.boost.org/"
+ tabindex="2" style="border: medium none ;"> </a> </div>
+ <div style="margin: 5px;">
+ <h3 class="navbar">Contents</h3>
+ <ul>
<li>Boost.Polygon Main Page</li>
<li>Design Overview</li>
<li>Isotropy</li>
@@ -46,19 +54,14 @@
<li>Property Merge 90</li>
<li>Property Merge 45</li>
<li>Property Merge</li>
- <li>Voronoi Main Page
- </li>
+ <li>Voronoi Main Page </li>
<li>Voronoi Benchmark</li>
<li>Voronoi Builder<br />
</li>
<li>Voronoi Diagram</li>
- <li>Voronoi Predicates</li>
- <li>Voronoi Robust FPT<br />
- </li>
-
-</ul>
- <h3 class="navbar">Other Resources</h3>
- <ul>
+ </ul>
+ <h3 class="navbar">Other Resources</h3>
+ <ul>
<li>GTL Boostcon 2009 Paper</li>
<li><a href="GTL_boostcon_draft03.pdf">GTL Boostcon 2009
Presentation</a></li>
@@ -68,120 +71,133 @@
<li>Voronoi Basic Tutorial</li>
<li><a href="voronoi_advanced_tutorial.htm">Voronoi Advanced
Tutorial</a></li>
-</ul>
- </div>
- <h3 class="navbar">Polygon Sponsor</h3>
- <div style="padding: 5px;" align="center">
- <img src="images/intlogo.gif" border="0" height="51" width="127" /><a title="www.adobe.com home page" href="http://www.adobe.com/" tabindex="2" style="border: medium none ;">
- </a>
- </div>
-</td>
-<td style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;" valign="top" width="100%">
-
-<!-- End Header -->
-
-<br />
-<p>
-</p><h1>Polygon Set Algorithms Analysis</h1>
-<p>Most non-trivial algorithms in the Boost.Polygon library are
-instantiations of generic sweep-line algorithms that provide the capability to
-perform Manhattan and 45-degree line segment intersection, n-layer map overlay,
-connectivity graph extraction and clipping/Booleans. These algorithms have O(n log n)
-runtime complexity for n equal to input vertices plus intersection vertices. The
-arbitrary angle line segment intersection algorithm is not implemented as a
-sweep-line due to complications related to achieving numerical robustness.
-The general line segment intersection algorithm is implemented as an recursive
-adaptive heuristic divide and conquer in the y dimension followed by sorting
-line segments in each subdivision by x coordinates and scanning left to right.
-By one-dimensional decomposition of the problem space in both x and y the
-algorithm approximates the optimal O(n log n) Bentley-Ottmann line segment intersection
-runtime complexity in the common case. Specific examples of inputs that
-defeat one dimensional decomposition of the problem space can result in
-pathological quadratic runtime complexity to which the Bentley-Ottmann algorithm
-is immune.</p>
-<p>Below is shown a log-log plot of runtime versus input size for inputs that
-increase quadratically in size. The inputs were generated by
-pseudo-randomly distributing small axis-parallel rectangles within a square area
-proportional the the number of rectangles specified for each trial. In
-this way the probability of intersections being produced remains constant as the
-input size grows. Because intersection vertices are expected to be a
-constant factor of input vertices we can examine runtime complexity in terms of
-input vertices. The operation performed was a union (Boolean OR) of the
-input rectangles by each of the Manhattan, 45-degree and arbitrary angle
-Booleans algorithms, which are labeled "boolean 90", "boolean 45" and "boolean".
-Also shown in the plot is the performance of the arbitrary angle Booleans
-algorithm as prior to the addition of divide and conquer recursive subdivision,
-which was described in the paper
-presented at
-boostcon 2009. Finally, the
-time required to sort the input points is shown as a common reference for O(n log n)
-runtime to put the data into context.</p><img src="images/perf_graph.PNG" border="0" height="414" width="391" /><p>
-We can see in the log-log plot that sorting and the three Booleans algorithms
-provided by the Boost.Polygon library have nearly 45 degree "linear"
-scaling with empirical exponents just slightly larger than 1.0 and can be
-observed to scale proportional to O(n log n) for
-these inputs. The "old boolean" algorithm presented at boostcon 2009
-exhibits scaling close to the expected O(n<sup><font size="2">1.5</font></sup>)
-scaling. Because the speedup provided by the divide and conquer approach
-is algorithmic, the 10X potential performance improvement alluded to in the paper is
-realized at inputs of 200,000 rectangles and larger. Even for small inputs
-of 2K rectangles the algorithm is 2X faster and now can be expected to be
-roughly as fast as GPC at small scales,
-while algorithmically faster at large scales.</p>
-<p>
-
-
-From the plot we can compare the constant factor performance of the various
-Booleans algorithms with the runtime of std::sort as a baseline for O(n log n)
-algorithms. If you consider sort to be one unit of O(n log n) algorithmic
-work we can see that Manhattan Booleans cost roughly five units of O(n log n)
-work, 45-degree Booleans cost roughly
-
-
-ten units of O(n log n) work and arbitrary angle Booleans cost roughly
-seventy units of O(n log n) work. Sorting the input vertices is the first
-step in a Booleans algorithm and therefore provides a hard lower bound for the
-runtime of an optimal Booleans algorithm.</p><p>
-
-
-One final thing to note about performance of the arbitrary angle Booleans
-algorithm is that the use of GMP
- infinite precision rational data type for numerically robust
-computations can be employed by including boost/polygon/gmp_override.hpp and linking
-to lgmpxx and lgmp. This provides
-100% assurance that the algorithm will succeed and produce an output snapped to
-the integer grid with a minimum of one integer grid of error on polygon
-boundaries upon which intersection points are introduced. However, the
-infinite precision data type is never used for predicates (see the boostcon
-presentation or paper for description of robust predicates) and is only used for
-constructions of intersection coordinate values in the very rare case that long
-double computation of the intersection of two line segments fails to produce an
-intersection point within one integer unit of both line segments. This
-means that there is effectively no runtime penalty for the use of infinite
-precision to ensure 100% robustness. Most inputs will process through the
-algorithm without ever resorting to GMP.</p></td></tr><tr>
-<td style="background-color: rgb(238, 238, 238);" nowrap="1" valign="top">
- </td>
-<td style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;" valign="top" width="100%">
-
-
-<table class="docinfo" id="table1" frame="void" rules="none">
- <colgroup>
- <col class="docinfo-name" /><col class="docinfo-content" />
- </colgroup>
- <tbody valign="top">
- <tr>
- <th class="docinfo-name">Copyright:</th>
- <td>Copyright © Intel Corporation 2008-2010.</td>
- </tr>
- <tr class="field">
- <th class="docinfo-name">License:</th>
- <td class="field-body">Distributed under the Boost Software License,
- Version 1.0. (See accompanying file <tt class="literal">
- <span class="pre">LICENSE_1_0.txt</span></tt> or copy at
- <a class="reference" target="_top" href="http://www.boost.org/LICENSE_1_0.txt">
- http://www.boost.org/LICENSE_1_0.txt>)</td>
- </tr>
-</tbody></table>
-
-</td></tr></tbody></table></body></html>
\ No newline at end of file
+ </ul>
+ </div>
+ <h3 class="navbar">Polygon Sponsor</h3>
+ <div style="padding: 5px;" align="center"> <img
+ src="images/intlogo.gif" border="0" height="51" width="127" /><a
+ title="www.adobe.com home page" href="http://www.adobe.com/"
+ tabindex="2" style="border: medium none ;"> </a> </div>
+ </td>
+ <td
+ style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;"
+ valign="top" width="100%">
+<!-- End Header --><br />
+ <p>
+ </p>
+ <h1>Polygon Set Algorithms Analysis</h1>
+ <p>Most non-trivial algorithms in the Boost.Polygon library are
+instantiations of generic sweep-line algorithms that provide the
+capability to perform Manhattan and 45-degree line segment
+intersection, n-layer map overlay, connectivity graph extraction and
+clipping/Booleans. These algorithms have O(n log n) runtime
+complexity for n equal to input vertices plus intersection
+vertices. The arbitrary angle line segment intersection algorithm
+is not implemented as a sweep-line due to complications related to
+achieving numerical robustness. The general line segment
+intersection algorithm is implemented as an recursive adaptive
+heuristic divide and conquer in the y dimension followed by sorting
+line segments in each subdivision by x coordinates and scanning left to
+right. By one-dimensional decomposition of the problem space in
+both x and y the algorithm approximates the optimal O(n log n)
+Bentley-Ottmann line segment intersection runtime complexity in the
+common case. Specific examples of inputs that defeat one
+dimensional decomposition of the problem space can result in
+pathological quadratic runtime complexity to which the Bentley-Ottmann
+algorithm is immune.</p>
+ <p>Below is shown a log-log plot of runtime versus input size for
+inputs that increase quadratically in size. The inputs were
+generated by pseudo-randomly distributing small axis-parallel
+rectangles within a square area proportional the the number of
+rectangles specified for each trial. In this way the probability
+of intersections being produced remains constant as the input size
+grows. Because intersection vertices are expected to be a
+constant factor of input vertices we can examine runtime complexity in
+terms of input vertices. The operation performed was a union
+(Boolean OR) of the input rectangles by each of the Manhattan,
+45-degree and arbitrary angle Booleans algorithms, which are labeled
+"boolean 90", "boolean 45" and "boolean". Also shown in the plot
+is the performance of the arbitrary angle Booleans algorithm as prior
+to the addition of divide and conquer recursive subdivision, which was
+described in the paper <a
+ href="GTL_boostcon_draft03.pdf">presented</a> at
+ boostcon 2009.
+Finally, the time required to sort the input points is shown as a
+common reference for O(n log n) runtime to put the data into context.</p>
+ <img src="images/perf_graph.PNG" border="0" height="414"
+ width="391" />
+ <p>We can see in the log-log plot that sorting and the three
+Booleans algorithms provided by the Boost.Polygon library have nearly
+45 degree "linear" scaling with empirical exponents just slightly
+larger than 1.0 and can be observed to scale proportional to O(n log n)
+for these inputs. The "old boolean" algorithm presented at
+boostcon 2009 exhibits scaling close to the expected O(n<sup><font
+ size="2">1.5</font></sup>) scaling. Because the speedup provided
+by the divide and conquer approach is algorithmic, the 10X potential
+performance improvement alluded to in the paper is realized at inputs
+of 200,000 rectangles and larger. Even for small inputs of 2K
+rectangles the algorithm is 2X faster and now can be expected to be
+roughly as fast as <a
+ href="http://www.cs.manchester.ac.uk/%7Etoby/alan/software/">GPC</a>
+at small scales, while algorithmically faster at large scales.</p>
+ <p>
+From the plot we can compare the constant factor performance of the
+various Booleans algorithms with the runtime of std::sort as a baseline
+for O(n log n) algorithms. If you consider sort to be one unit of
+O(n log n) algorithmic work we can see that Manhattan Booleans cost
+roughly five units of O(n log n) work, 45-degree Booleans cost
+roughly
+ten units of O(n log n) work and arbitrary angle Booleans cost roughly
+seventy units of O(n log n) work. Sorting the input vertices is
+the first step in a Booleans algorithm and therefore provides a hard
+lower bound for the runtime of an optimal Booleans algorithm.</p>
+ <p>One final thing to note about performance of the arbitrary
+angle Booleans algorithm is that the use of GMP
+infinite precision rational data type for numerically robust
+computations can be employed by including
+boost/polygon/gmp_override.hpp and linking to lgmpxx and lgmp.
+This provides 100% assurance that the algorithm will succeed and
+produce an output snapped to the integer grid with a minimum of one
+integer grid of error on polygon boundaries upon which intersection
+points are introduced. However, the infinite precision data type
+is never used for predicates (see the boostcon presentation or paper
+for description of robust predicates) and is only used for
+constructions of intersection coordinate values in the very rare case
+that long double computation of the intersection of two line segments
+fails to produce an intersection point within one integer unit of both
+line segments. This means that there is effectively no runtime
+penalty for the use of infinite precision to ensure 100%
+robustness. Most inputs will process through the algorithm
+without ever resorting to GMP.</p>
+ </td>
+ </tr>
+ <tr>
+ <td style="background-color: rgb(238, 238, 238);" nowrap="1"
+ valign="top"> </td>
+ <td
+ style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;"
+ valign="top" width="100%">
+ <table class="docinfo" id="table1" frame="void" rules="none">
+ <colgroup> <col class="docinfo-name" /><col
+ class="docinfo-content" /> </colgroup> <tbody valign="top">
+ <tr>
+ <th class="docinfo-name">Copyright:</th>
+ <td>Copyright © Intel Corporation 2008-2010.</td>
+ </tr>
+ <tr class="field">
+ <th class="docinfo-name">License:</th>
+ <td class="field-body">Distributed under the Boost Software
+License, Version 1.0. (See accompanying file <tt class="literal"> <span
+ class="pre">LICENSE_1_0.txt</span></tt> or copy at <a
+ class="reference" target="_top"
+ href="http://www.boost.org/LICENSE_1_0.txt">
+http://www.boost.org/LICENSE_1_0.txt>)</td>
+ </tr>
+ </tbody>
+ </table>
+ </td>
+ </tr>
+ </tbody>
+</table>
+</body>
+</html>
Modified: branches/release/libs/polygon/doc/gtl_connectivity_extraction.htm
==============================================================================
--- branches/release/libs/polygon/doc/gtl_connectivity_extraction.htm (original)
+++ branches/release/libs/polygon/doc/gtl_connectivity_extraction.htm 2013-04-15 18:27:46 EDT (Mon, 15 Apr 2013)
@@ -1,159 +1,185 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:(null)1="http://www.w3.org/TR/REC-html40" lang="en"><head>
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"
+ xmlns:v="urn:schemas-microsoft-com:vml"
+ xmlns:o="urn:schemas-microsoft-com:office:office"
+ xmlns:(null)1="http://www.w3.org/TR/REC-html40" lang="en">
+<head>
<!--
Copyright 2009-2010 Intel Corporation
license banner
---><title>Boost Polygon Library: Connectivity Extraction 45</title>
-
-
-
- <meta http-equiv="content-type" content="text/html;charset=ISO-8859-1" /><!-- <link type="text/css" rel="stylesheet" href="adobe_source.css"> --></head><body><table style="margin: 0pt; padding: 0pt; width: 100%;" border="0" cellpadding="0" cellspacing="0"><tbody><tr>
-<td style="background-color: rgb(238, 238, 238);" nowrap="1" valign="top">
- <div style="padding: 5px;" align="center">
- <img src="images/boost.png" border="0" height="86" width="277" /><a title="www.boost.org home page" href="http://www.boost.org/" tabindex="2" style="border: medium none ;">
- </a>
- </div>
- <div style="margin: 5px;">
- <h3 class="navbar">Contents</h3>
- <ul>
- <li>Boost.Polygon Main Page</li>
- <li>Design Overview</li>
- <li>Isotropy</li>
- <li>Coordinate Concept</li>
- <li>Interval Concept</li>
- <li>Point Concept</li>
+-->
+ <title>Boost Polygon Library: Connectivity Extraction 45</title>
+ <meta http-equiv="content-type" content="text/html;charset=ISO-8859-1" />
+<!-- <link type="text/css" rel="stylesheet" href="adobe_source.css"> -->
+</head>
+<body>
+<table style="margin: 0pt; padding: 0pt; width: 100%;" border="0"
+ cellpadding="0" cellspacing="0">
+ <tbody>
+ <tr>
+ <td style="background-color: rgb(238, 238, 238);" nowrap="1"
+ valign="top">
+ <div style="padding: 5px;" align="center"> <img
+ src="images/boost.png" border="0" height="86" width="277" /><a
+ title="www.boost.org home page" href="http://www.boost.org/"
+ tabindex="2" style="border: medium none ;"> </a> </div>
+ <div style="margin: 5px;">
+ <h3 class="navbar">Contents</h3>
+ <ul>
+ <li>Boost.Polygon Main Page</li>
+ <li>Design Overview</li>
+ <li>Isotropy</li>
+ <li>Coordinate Concept</li>
+ <li>Interval Concept</li>
+ <li>Point Concept</li>
<li>Segment Concept</li>
-
- <li>Rectangle Concept</li>
- <li>Polygon 90 Concept</li>
- <li>Polygon 90 With Holes Concept</li>
- <li>Polygon 45 Concept</li>
- <li>Polygon 45 With Holes Concept</li>
- <li>Polygon Concept</li>
- <li>Polygon With Holes Concept</li>
- <li>Polygon 90 Set Concept</li>
- <li>Polygon 45 Set Concept</li>
- <li>Polygon Set Concept</li>
- <li>Connectivity Extraction 90</li>
- <li>Connectivity Extraction 45</li>
- <li>Connectivity Extraction</li>
- <li>Property Merge 90</li>
- <li>Property Merge 45</li>
- <li>Property Merge</li>
+ <li>Rectangle Concept</li>
+ <li>Polygon 90 Concept</li>
+ <li><a href="gtl_polygon_90_with_holes_concept.htm">Polygon 90
+With Holes Concept</a></li>
+ <li>Polygon 45 Concept</li>
+ <li><a href="gtl_polygon_45_with_holes_concept.htm">Polygon 45
+With Holes Concept</a></li>
+ <li>Polygon Concept</li>
+ <li><a href="gtl_polygon_with_holes_concept.htm">Polygon With
+Holes Concept</a></li>
+ <li><a href="gtl_polygon_90_set_concept.htm">Polygon 90 Set
+Concept</a></li>
+ <li><a href="gtl_polygon_45_set_concept.htm">Polygon 45 Set
+Concept</a></li>
+ <li>Polygon Set Concept</li>
+ <li><a href="gtl_connectivity_extraction_90.htm">Connectivity
+Extraction 90</a></li>
+ <li><a href="gtl_connectivity_extraction_45.htm">Connectivity
+Extraction 45</a></li>
+ <li>Connectivity Extraction</li>
+ <li>Property Merge 90</li>
+ <li>Property Merge 45</li>
+ <li>Property Merge</li>
<li><a href="voronoi_main.htm">Voronoi Main Page<br />
-</a></li>
+ </a></li>
<li>Voronoi Benchmark<br />
</li>
<li>Voronoi Builder</li>
- <li><a href="voronoi_diagram.htm">Voronoi Diagram<br />
-</a></li>
- <li>Voronoi Predicates</li>
- <li>Voronoi Robust FPT<br />
- </li>
-
-
- </ul>
- <h3 class="navbar">Other Resources</h3>
- <ul>
+ <li>Voronoi Diagram</li>
+ </ul>
+ <h3 class="navbar">Other Resources</h3>
+ <ul>
<li>GTL Boostcon 2009 Paper</li>
- <li><a href="GTL_boostcon_draft03.pdf">GTL Boostcon 2009
- Presentation</a></li>
+ <li><a href="GTL_boostcon_draft03.pdf">GTL Boostcon 2009
+Presentation</a></li>
<li>Performance Analysis</li>
<li>Layout Versus Schematic Tutorial</li>
<li>Minkowski Sum Tutorial</li>
<li>Voronoi Basic Tutorial</li>
- <li>Voronoi Advanced Tutorial</li>
-</ul>
- </div>
- <h3 class="navbar">Polygon Sponsor</h3>
- <div style="padding: 5px;" align="center">
- <img src="images/intlogo.gif" border="0" height="51" width="127" /><a title="www.adobe.com home page" href="http://www.adobe.com/" tabindex="2" style="border: medium none ;">
- </a>
- </div>
-</td>
-<td style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;" valign="top" width="100%">
-
-<!-- End Header -->
-
-<br />
-<p>
-</p><h1>Connectivity Extraction</h1>
-
-<p>
-</p><p>The connectivity extraction algorithm constructs the connectivity graph where
-input polygon sets are modeled as graph nodes and assigned node ids and
-overlap/touching between input polygon sets is modeled as graph edges. One
-supported graph formats is std::vector<std::set<int> > where node ids index into
-the vector and the sets of integers at each index are the ids of nodes for which
-an edge exists in the graph. It is required that such vector pre-allocate
-sufficient elements to store the graph generated by the algorithm, because only
-the operator[] is used internally to access the graph The other
-supported graph format is std::map<int, std::set<int> > which is slightly easier to
-work with, but potentially more expensive. Improving the interface to
-support more generic graph concepts is deferred to future work.</p><p>The following
-is the declaration of the connectivity extraction algorithm.</p><p>
-<font face="Courier New">template <typename coordinate_type><br />
-class connectivity_extraction;</font></p><p>
-Example code connectivity_extraction_usage.cpp
- demonstrates using the connectivity extraction algorithm to build a
-connectivity graph on geometry.</p><h2>Member Functions</h2>
-<table id="table1" border="1" width="100%">
- <tbody><tr>
- <td width="586"><b><font face="Courier New">connectivity_extraction</font></b><font face="Courier New">()</font></td>
- <td>Default constructor. </td>
- </tr>
- <tr>
- <td width="586"><b><font face="Courier New">connectivity_extraction</font></b><font face="Courier New">(<br /> const
- connectivity_extraction& that)</font></td>
- <td>Copy construct.</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">unsigned int <br /><b>insert</b>(const polygon_set_data<coordinate_type>& ps)</font></td>
- <td>I<font face="Times New Roman">nsert a polygon set graph node, the
- value returned is the id of the graph node.</font></td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">
+ <li><a href="voronoi_advanced_tutorial.htm">Voronoi Advanced
+Tutorial</a></li>
+ </ul>
+ </div>
+ <h3 class="navbar">Polygon Sponsor</h3>
+ <div style="padding: 5px;" align="center"> <img
+ src="images/intlogo.gif" border="0" height="51" width="127" /><a
+ title="www.adobe.com home page" href="http://www.adobe.com/"
+ tabindex="2" style="border: medium none ;"> </a> </div>
+ </td>
+ <td
+ style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;"
+ valign="top" width="100%">
+<!-- End Header --><br />
+ <p>
+ </p>
+ <h1>Connectivity Extraction</h1>
+ <p> </p>
+ <p>The connectivity extraction algorithm constructs the
+connectivity graph where input polygon sets are modeled as graph nodes
+and assigned node ids and overlap/touching between input polygon sets
+is modeled as graph edges. One supported graph formats is
+std::vector<std::set<int> > where node ids index into the
+vector and the sets of integers at each index are the ids of nodes for
+which an edge exists in the graph. It is required that such
+vector pre-allocate sufficient elements to store the graph generated by
+the algorithm, because only the operator[] is used internally to access
+the graph The other supported graph format is
+std::map<int, std::set<int> > which is slightly easier to
+work with, but potentially more expensive. Improving the
+interface to support more generic graph concepts is deferred to future
+work.</p>
+ <p>The following is the declaration of the connectivity
+extraction algorithm.</p>
+ <p><font face="Courier New">template <typename
+coordinate_type><br />
+class connectivity_extraction;</font></p>
+ <p>Example code connectivity_extraction_usage.cpp
+demonstrates using the connectivity extraction algorithm to build a
+connectivity graph on geometry.</p>
+ <h2>Member Functions</h2>
+ <table id="table1" border="1" width="100%">
+ <tbody>
+ <tr>
+ <td width="586"><b><font face="Courier New">connectivity_extraction</font></b><font
+ face="Courier New">()</font></td>
+ <td>Default constructor. </td>
+ </tr>
+ <tr>
+ <td width="586"><b><font face="Courier New">connectivity_extraction</font></b><font
+ face="Courier New">(<br />
+ const connectivity_extraction& that)</font></td>
+ <td>Copy construct.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">unsigned int <br />
+ <b>insert</b>(const
+polygon_set_data<coordinate_type>& ps)</font></td>
+ <td>I<font face="Times New Roman">nsert a polygon set graph
+node, the value returned is the id of the graph node.</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">
template <class GeoObjT><br />
unsigned int <b>insert</b>(const GeoObjT& geoObj)</font></td>
- <td>Insert a geometry object that is a refinement of polygon set as a
- graph node, the return value is the id of the graph node.</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">
+ <td>Insert a geometry object that is a refinement of
+polygon set as a graph node, the return value is the id of the graph
+node.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">
template <class GraphT><br />
void <b>extract</b>(GraphT& graph)</font></td>
- <td>Accepts a graph object that conforms to the expectations defined
- above. Performs connectivity extraction and populates the graph
- object.</td>
- </tr>
- </tbody></table>
- </td></tr><tr>
-<td style="background-color: rgb(238, 238, 238);" nowrap="1" valign="top">
- </td>
-<td style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;" valign="top" width="100%">
-
-
-<table class="docinfo" id="table2" frame="void" rules="none">
- <colgroup>
- <col class="docinfo-name" /><col class="docinfo-content" />
- </colgroup>
- <tbody valign="top">
- <tr>
- <th class="docinfo-name">Copyright:</th>
- <td>Copyright © Intel Corporation 2008-2010.</td>
- </tr>
- <tr class="field">
- <th class="docinfo-name">License:</th>
- <td class="field-body">Distributed under the Boost Software License,
- Version 1.0. (See accompanying file <tt class="literal">
- <span class="pre">LICENSE_1_0.txt</span></tt> or copy at
- <a class="reference" target="_top" href="http://www.boost.org/LICENSE_1_0.txt">
- http://www.boost.org/LICENSE_1_0.txt>)</td>
- </tr>
-</tbody></table>
-
-</td></tr></tbody></table></body></html>
\ No newline at end of file
+ <td>Accepts a graph object that conforms to the
+expectations defined above. Performs connectivity extraction and
+populates the graph object.</td>
+ </tr>
+ </tbody>
+ </table>
+ </td>
+ </tr>
+ <tr>
+ <td style="background-color: rgb(238, 238, 238);" nowrap="1"
+ valign="top"> </td>
+ <td
+ style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;"
+ valign="top" width="100%">
+ <table class="docinfo" id="table2" frame="void" rules="none">
+ <colgroup> <col class="docinfo-name" /><col
+ class="docinfo-content" /> </colgroup> <tbody valign="top">
+ <tr>
+ <th class="docinfo-name">Copyright:</th>
+ <td>Copyright © Intel Corporation 2008-2010.</td>
+ </tr>
+ <tr class="field">
+ <th class="docinfo-name">License:</th>
+ <td class="field-body">Distributed under the Boost Software
+License, Version 1.0. (See accompanying file <tt class="literal"> <span
+ class="pre">LICENSE_1_0.txt</span></tt> or copy at <a
+ class="reference" target="_top"
+ href="http://www.boost.org/LICENSE_1_0.txt">
+http://www.boost.org/LICENSE_1_0.txt>)</td>
+ </tr>
+ </tbody>
+ </table>
+ </td>
+ </tr>
+ </tbody>
+</table>
+</body>
+</html>
Modified: branches/release/libs/polygon/doc/gtl_connectivity_extraction_45.htm
==============================================================================
--- branches/release/libs/polygon/doc/gtl_connectivity_extraction_45.htm (original)
+++ branches/release/libs/polygon/doc/gtl_connectivity_extraction_45.htm 2013-04-15 18:27:46 EDT (Mon, 15 Apr 2013)
@@ -1,159 +1,185 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:(null)1="http://www.w3.org/TR/REC-html40" lang="en"><head>
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"
+ xmlns:v="urn:schemas-microsoft-com:vml"
+ xmlns:o="urn:schemas-microsoft-com:office:office"
+ xmlns:(null)1="http://www.w3.org/TR/REC-html40" lang="en">
+<head>
<!--
Copyright 2009-2010 Intel Corporation
license banner
---><title>Boost Polygon Library: Connectivity Extraction 45</title>
-
-
-
- <meta http-equiv="content-type" content="text/html;charset=ISO-8859-1" /><!-- <link type="text/css" rel="stylesheet" href="adobe_source.css"> --></head><body><table style="margin: 0pt; padding: 0pt; width: 100%;" border="0" cellpadding="0" cellspacing="0"><tbody><tr>
-<td style="background-color: rgb(238, 238, 238);" nowrap="1" valign="top">
- <div style="padding: 5px;" align="center">
- <img src="images/boost.png" border="0" height="86" width="277" /><a title="www.boost.org home page" href="http://www.boost.org/" tabindex="2" style="border: medium none ;">
- </a>
- </div>
- <div style="margin: 5px;">
- <h3 class="navbar">Contents</h3>
- <ul>
- <li>Boost.Polygon Main Page</li>
- <li>Design Overview</li>
- <li>Isotropy</li>
- <li>Coordinate Concept</li>
- <li>Interval Concept</li>
- <li>Point Concept</li>
+-->
+ <title>Boost Polygon Library: Connectivity Extraction 45</title>
+ <meta http-equiv="content-type" content="text/html;charset=ISO-8859-1" />
+<!-- <link type="text/css" rel="stylesheet" href="adobe_source.css"> -->
+</head>
+<body>
+<table style="margin: 0pt; padding: 0pt; width: 100%;" border="0"
+ cellpadding="0" cellspacing="0">
+ <tbody>
+ <tr>
+ <td style="background-color: rgb(238, 238, 238);" nowrap="1"
+ valign="top">
+ <div style="padding: 5px;" align="center"> <img
+ src="images/boost.png" border="0" height="86" width="277" /><a
+ title="www.boost.org home page" href="http://www.boost.org/"
+ tabindex="2" style="border: medium none ;"> </a> </div>
+ <div style="margin: 5px;">
+ <h3 class="navbar">Contents</h3>
+ <ul>
+ <li>Boost.Polygon Main Page</li>
+ <li>Design Overview</li>
+ <li>Isotropy</li>
+ <li>Coordinate Concept</li>
+ <li>Interval Concept</li>
+ <li>Point Concept</li>
<li>Segment Concept</li>
-
- <li>Rectangle Concept</li>
- <li>Polygon 90 Concept</li>
- <li>Polygon 90 With Holes Concept</li>
- <li>Polygon 45 Concept</li>
- <li>Polygon 45 With Holes Concept</li>
- <li>Polygon Concept</li>
- <li>Polygon With Holes Concept</li>
- <li>Polygon 90 Set Concept</li>
- <li>Polygon 45 Set Concept</li>
- <li>Polygon Set Concept</li>
- <li>Connectivity Extraction 90</li>
- <li>Connectivity Extraction 45</li>
- <li>Connectivity Extraction</li>
- <li>Property Merge 90</li>
- <li>Property Merge 45</li>
- <li>Property Merge</li>
+ <li>Rectangle Concept</li>
+ <li>Polygon 90 Concept</li>
+ <li><a href="gtl_polygon_90_with_holes_concept.htm">Polygon 90
+With Holes Concept</a></li>
+ <li>Polygon 45 Concept</li>
+ <li><a href="gtl_polygon_45_with_holes_concept.htm">Polygon 45
+With Holes Concept</a></li>
+ <li>Polygon Concept</li>
+ <li><a href="gtl_polygon_with_holes_concept.htm">Polygon With
+Holes Concept</a></li>
+ <li><a href="gtl_polygon_90_set_concept.htm">Polygon 90 Set
+Concept</a></li>
+ <li><a href="gtl_polygon_45_set_concept.htm">Polygon 45 Set
+Concept</a></li>
+ <li>Polygon Set Concept</li>
+ <li><a href="gtl_connectivity_extraction_90.htm">Connectivity
+Extraction 90</a></li>
+ <li>Connectivity Extraction 45</li>
+ <li><a href="gtl_connectivity_extraction.htm">Connectivity
+Extraction</a></li>
+ <li>Property Merge 90</li>
+ <li>Property Merge 45</li>
+ <li>Property Merge</li>
<li><a href="voronoi_main.htm">Voronoi Main Page<br />
-</a></li>
+ </a></li>
<li>Voronoi Benchmark<br />
</li>
<li>Voronoi Builder</li>
- <li><a href="voronoi_diagram.htm">Voronoi Diagram<br />
-</a></li>
- <li>Voronoi Predicates</li>
- <li>Voronoi Robust FPT<br />
- </li>
-
-
- </ul>
- <h3 class="navbar">Other Resources</h3>
- <ul>
+ <li>Voronoi Diagram</li>
+ </ul>
+ <h3 class="navbar">Other Resources</h3>
+ <ul>
<li>GTL Boostcon 2009 Paper</li>
- <li><a href="GTL_boostcon_draft03.pdf">GTL Boostcon 2009
- Presentation</a></li>
+ <li><a href="GTL_boostcon_draft03.pdf">GTL Boostcon 2009
+Presentation</a></li>
<li>Performance Analysis</li>
<li>Layout Versus Schematic Tutorial</li>
<li>Minkowski Sum Tutorial</li>
<li>Voronoi Basic Tutorial</li>
- <li>Voronoi Advanced Tutorial</li>
-</ul>
- </div>
- <h3 class="navbar">Polygon Sponsor</h3>
- <div style="padding: 5px;" align="center">
- <img src="images/intlogo.gif" border="0" height="51" width="127" /><a title="www.adobe.com home page" href="http://www.adobe.com/" tabindex="2" style="border: medium none ;">
- </a>
- </div>
-</td>
-<td style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;" valign="top" width="100%">
-
-<!-- End Header -->
-
-<br />
-<p>
-</p><h1>Connectivity Extraction 45</h1>
-
-<p>
-</p><p>The connectivity extraction algorithm constructs the connectivity graph where
-input polygon sets are modeled as graph nodes and assigned node ids and
-overlap/touching between input polygon sets is modeled as graph edges. One
-supported graph formats is std::vector<std::set<int> > where node ids index into
-the vector and the sets of integers at each index are the ids of nodes for which
-an edge exists in the graph. It is required that such vector pre-allocate
-sufficient elements to store the graph generated by the algorithm, because only
-the operator[] is used internally to access the graph The other
-supported graph format is std::map<int, std::set<int> > which is slightly easier to
-work with, but potentially more expensive. Improving the interface to
-support more generic graph concepts is deferred to future work.</p><p>The following
-is the declaration of the connectivity extraction algorithm.</p><p>
-<font face="Courier New">template <typename coordinate_type><br />
-class connectivity_extraction_45;</font></p><p>
-Example code connectivity_extraction_usage.cpp
- demonstrates using the connectivity extraction algorithm to build a
-connectivity graph on geometry.</p><h2>Member Functions</h2>
-<table id="table1" border="1" width="100%">
- <tbody><tr>
- <td width="586"><b><font face="Courier New">connectivity_extraction_45</font></b><font face="Courier New">()</font></td>
- <td>Default constructor. </td>
- </tr>
- <tr>
- <td width="586"><b><font face="Courier New">connectivity_extraction_45</font></b><font face="Courier New">(<br /> const
- connectivity_extraction_45& that)</font></td>
- <td>Copy construct.</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">unsigned int <br /><b>insert</b>(const polygon_45_set_data<coordinate_type>& ps)</font></td>
- <td>I<font face="Times New Roman">nsert a polygon set graph node, the
- value returned is the id of the graph node.</font></td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">
+ <li><a href="voronoi_advanced_tutorial.htm">Voronoi Advanced
+Tutorial</a></li>
+ </ul>
+ </div>
+ <h3 class="navbar">Polygon Sponsor</h3>
+ <div style="padding: 5px;" align="center"> <img
+ src="images/intlogo.gif" border="0" height="51" width="127" /><a
+ title="www.adobe.com home page" href="http://www.adobe.com/"
+ tabindex="2" style="border: medium none ;"> </a> </div>
+ </td>
+ <td
+ style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;"
+ valign="top" width="100%">
+<!-- End Header --><br />
+ <p>
+ </p>
+ <h1>Connectivity Extraction 45</h1>
+ <p> </p>
+ <p>The connectivity extraction algorithm constructs the
+connectivity graph where input polygon sets are modeled as graph nodes
+and assigned node ids and overlap/touching between input polygon sets
+is modeled as graph edges. One supported graph formats is
+std::vector<std::set<int> > where node ids index into the
+vector and the sets of integers at each index are the ids of nodes for
+which an edge exists in the graph. It is required that such
+vector pre-allocate sufficient elements to store the graph generated by
+the algorithm, because only the operator[] is used internally to access
+the graph The other supported graph format is
+std::map<int, std::set<int> > which is slightly easier to
+work with, but potentially more expensive. Improving the
+interface to support more generic graph concepts is deferred to future
+work.</p>
+ <p>The following is the declaration of the connectivity
+extraction algorithm.</p>
+ <p><font face="Courier New">template <typename
+coordinate_type><br />
+class connectivity_extraction_45;</font></p>
+ <p>Example code connectivity_extraction_usage.cpp
+demonstrates using the connectivity extraction algorithm to build a
+connectivity graph on geometry.</p>
+ <h2>Member Functions</h2>
+ <table id="table1" border="1" width="100%">
+ <tbody>
+ <tr>
+ <td width="586"><b><font face="Courier New">connectivity_extraction_45</font></b><font
+ face="Courier New">()</font></td>
+ <td>Default constructor. </td>
+ </tr>
+ <tr>
+ <td width="586"><b><font face="Courier New">connectivity_extraction_45</font></b><font
+ face="Courier New">(<br />
+ const connectivity_extraction_45& that)</font></td>
+ <td>Copy construct.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">unsigned int <br />
+ <b>insert</b>(const
+polygon_45_set_data<coordinate_type>& ps)</font></td>
+ <td>I<font face="Times New Roman">nsert a polygon set graph
+node, the value returned is the id of the graph node.</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">
template <class GeoObjT><br />
unsigned int <b>insert</b>(const GeoObjT& geoObj)</font></td>
- <td>Insert a geometry object that is a refinement of polygon 45 set as a
- graph node, the return value is the id of the graph node.</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">
+ <td>Insert a geometry object that is a refinement of
+polygon 45 set as a graph node, the return value is the id of the graph
+node.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">
template <class GraphT><br />
void <b>extract</b>(GraphT& graph)</font></td>
- <td>Accepts a graph object that conforms to the expectations defined
- above. Performs connectivity extraction and populates the graph
- object.</td>
- </tr>
- </tbody></table>
- </td></tr><tr>
-<td style="background-color: rgb(238, 238, 238);" nowrap="1" valign="top">
- </td>
-<td style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;" valign="top" width="100%">
-
-
-<table class="docinfo" id="table2" frame="void" rules="none">
- <colgroup>
- <col class="docinfo-name" /><col class="docinfo-content" />
- </colgroup>
- <tbody valign="top">
- <tr>
- <th class="docinfo-name">Copyright:</th>
- <td>Copyright © Intel Corporation 2008-2010.</td>
- </tr>
- <tr class="field">
- <th class="docinfo-name">License:</th>
- <td class="field-body">Distributed under the Boost Software License,
- Version 1.0. (See accompanying file <tt class="literal">
- <span class="pre">LICENSE_1_0.txt</span></tt> or copy at
- <a class="reference" target="_top" href="http://www.boost.org/LICENSE_1_0.txt">
- http://www.boost.org/LICENSE_1_0.txt>)</td>
- </tr>
-</tbody></table>
-
-</td></tr></tbody></table></body></html>
\ No newline at end of file
+ <td>Accepts a graph object that conforms to the
+expectations defined above. Performs connectivity extraction and
+populates the graph object.</td>
+ </tr>
+ </tbody>
+ </table>
+ </td>
+ </tr>
+ <tr>
+ <td style="background-color: rgb(238, 238, 238);" nowrap="1"
+ valign="top"> </td>
+ <td
+ style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;"
+ valign="top" width="100%">
+ <table class="docinfo" id="table2" frame="void" rules="none">
+ <colgroup> <col class="docinfo-name" /><col
+ class="docinfo-content" /> </colgroup> <tbody valign="top">
+ <tr>
+ <th class="docinfo-name">Copyright:</th>
+ <td>Copyright © Intel Corporation 2008-2010.</td>
+ </tr>
+ <tr class="field">
+ <th class="docinfo-name">License:</th>
+ <td class="field-body">Distributed under the Boost Software
+License, Version 1.0. (See accompanying file <tt class="literal"> <span
+ class="pre">LICENSE_1_0.txt</span></tt> or copy at <a
+ class="reference" target="_top"
+ href="http://www.boost.org/LICENSE_1_0.txt">
+http://www.boost.org/LICENSE_1_0.txt>)</td>
+ </tr>
+ </tbody>
+ </table>
+ </td>
+ </tr>
+ </tbody>
+</table>
+</body>
+</html>
Modified: branches/release/libs/polygon/doc/gtl_connectivity_extraction_90.htm
==============================================================================
--- branches/release/libs/polygon/doc/gtl_connectivity_extraction_90.htm (original)
+++ branches/release/libs/polygon/doc/gtl_connectivity_extraction_90.htm 2013-04-15 18:27:46 EDT (Mon, 15 Apr 2013)
@@ -1,159 +1,185 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:(null)1="http://www.w3.org/TR/REC-html40" lang="en"><head>
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"
+ xmlns:v="urn:schemas-microsoft-com:vml"
+ xmlns:o="urn:schemas-microsoft-com:office:office"
+ xmlns:(null)1="http://www.w3.org/TR/REC-html40" lang="en">
+<head>
<!--
Copyright 2009-2010 Intel Corporation
license banner
---><title>Boost Polygon Library: Connectivity Extraction 90</title>
-
-
-
- <meta http-equiv="content-type" content="text/html;charset=ISO-8859-1" /><!-- <link type="text/css" rel="stylesheet" href="adobe_source.css"> --></head><body><table style="margin: 0pt; padding: 0pt; width: 100%;" border="0" cellpadding="0" cellspacing="0"><tbody><tr>
-<td style="background-color: rgb(238, 238, 238);" nowrap="1" valign="top">
- <div style="padding: 5px;" align="center">
- <img src="images/boost.png" border="0" height="86" width="277" /><a title="www.boost.org home page" href="http://www.boost.org/" tabindex="2" style="border: medium none ;">
- </a>
- </div>
- <div style="margin: 5px;">
- <h3 class="navbar">Contents</h3>
- <ul>
- <li>Boost.Polygon Main Page</li>
- <li>Design Overview</li>
- <li>Isotropy</li>
- <li>Coordinate Concept</li>
- <li>Interval Concept</li>
- <li>Point Concept</li>
+-->
+ <title>Boost Polygon Library: Connectivity Extraction 90</title>
+ <meta http-equiv="content-type" content="text/html;charset=ISO-8859-1" />
+<!-- <link type="text/css" rel="stylesheet" href="adobe_source.css"> -->
+</head>
+<body>
+<table style="margin: 0pt; padding: 0pt; width: 100%;" border="0"
+ cellpadding="0" cellspacing="0">
+ <tbody>
+ <tr>
+ <td style="background-color: rgb(238, 238, 238);" nowrap="1"
+ valign="top">
+ <div style="padding: 5px;" align="center"> <img
+ src="images/boost.png" border="0" height="86" width="277" /><a
+ title="www.boost.org home page" href="http://www.boost.org/"
+ tabindex="2" style="border: medium none ;"> </a> </div>
+ <div style="margin: 5px;">
+ <h3 class="navbar">Contents</h3>
+ <ul>
+ <li>Boost.Polygon Main Page</li>
+ <li>Design Overview</li>
+ <li>Isotropy</li>
+ <li>Coordinate Concept</li>
+ <li>Interval Concept</li>
+ <li>Point Concept</li>
<li>Segment Concept</li>
-
- <li>Rectangle Concept</li>
- <li>Polygon 90 Concept</li>
- <li>Polygon 90 With Holes Concept</li>
- <li>Polygon 45 Concept</li>
- <li>Polygon 45 With Holes Concept</li>
- <li>Polygon Concept</li>
- <li>Polygon With Holes Concept</li>
- <li>Polygon 90 Set Concept</li>
- <li>Polygon 45 Set Concept</li>
- <li>Polygon Set Concept</li>
- <li>Connectivity Extraction 90</li>
- <li>Connectivity Extraction 45</li>
- <li>Connectivity Extraction</li>
- <li>Property Merge 90</li>
- <li>Property Merge 45</li>
- <li>Property Merge</li>
+ <li>Rectangle Concept</li>
+ <li>Polygon 90 Concept</li>
+ <li><a href="gtl_polygon_90_with_holes_concept.htm">Polygon 90
+With Holes Concept</a></li>
+ <li>Polygon 45 Concept</li>
+ <li><a href="gtl_polygon_45_with_holes_concept.htm">Polygon 45
+With Holes Concept</a></li>
+ <li>Polygon Concept</li>
+ <li><a href="gtl_polygon_with_holes_concept.htm">Polygon With
+Holes Concept</a></li>
+ <li><a href="gtl_polygon_90_set_concept.htm">Polygon 90 Set
+Concept</a></li>
+ <li><a href="gtl_polygon_45_set_concept.htm">Polygon 45 Set
+Concept</a></li>
+ <li>Polygon Set Concept</li>
+ <li>Connectivity Extraction 90</li>
+ <li><a href="gtl_connectivity_extraction_45.htm">Connectivity
+Extraction 45</a></li>
+ <li><a href="gtl_connectivity_extraction.htm">Connectivity
+Extraction</a></li>
+ <li>Property Merge 90</li>
+ <li>Property Merge 45</li>
+ <li>Property Merge</li>
<li><a href="voronoi_main.htm">Voronoi Main Page<br />
-</a></li>
+ </a></li>
<li>Voronoi Benchmark<br />
</li>
<li>Voronoi Builder</li>
- <li><a href="voronoi_diagram.htm">Voronoi Diagram<br />
-</a></li>
- <li>Voronoi Predicates</li>
- <li>Voronoi Robust FPT<br />
- </li>
-
-
- </ul>
- <h3 class="navbar">Other Resources</h3>
- <ul>
+ <li>Voronoi Diagram</li>
+ </ul>
+ <h3 class="navbar">Other Resources</h3>
+ <ul>
<li>GTL Boostcon 2009 Paper</li>
- <li><a href="GTL_boostcon_draft03.pdf">GTL Boostcon 2009
- Presentation</a></li>
+ <li><a href="GTL_boostcon_draft03.pdf">GTL Boostcon 2009
+Presentation</a></li>
<li>Performance Analysis</li>
<li>Layout Versus Schematic Tutorial</li>
<li>Minkowski Sum Tutorial</li>
<li>Voronoi Basic Tutorial</li>
- <li>Voronoi Advanced Tutorial</li>
-</ul>
- </div>
- <h3 class="navbar">Polygon Sponsor</h3>
- <div style="padding: 5px;" align="center">
- <img src="images/intlogo.gif" border="0" height="51" width="127" /><a title="www.adobe.com home page" href="http://www.adobe.com/" tabindex="2" style="border: medium none ;">
- </a>
- </div>
-</td>
-<td style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;" valign="top" width="100%">
-
-<!-- End Header -->
-
-<br />
-<p>
-</p><h1>Connectivity Extraction 90</h1>
-
-<p>
-</p><p>The connectivity extraction algorithm constructs the connectivity graph where
-input polygon sets are modeled as graph nodes and assigned node ids and
-overlap/touching between input polygon sets is modeled as graph edges. One
-supported graph formats is std::vector<std::set<int> > where node ids index into
-the vector and the sets of integers at each index are the ids of nodes for which
-an edge exists in the graph. It is required that such vector pre-allocate
-sufficient elements to store the graph generated by the algorithm, because only
-the operator[] is used internally to access the graph The other
-supported graph format is std::map<int, std::set<int> > which is slightly easier to
-work with, but potentially more expensive. Improving the interface to
-support more generic graph concepts is deferred to future work.</p><p>The following
-is the declaration of the connectivity extraction algorithm.</p><p>
-<font face="Courier New">template <typename coordinate_type><br />
-class connectivity_extraction_90;</font></p><p>
-Example code connectivity_extraction_usage.cpp
- demonstrates using the connectivity extraction algorithm to build a
-connectivity graph on geometry.</p><h2>Member Functions</h2>
-<table id="table1" border="1" width="100%">
- <tbody><tr>
- <td width="586"><b><font face="Courier New">connectivity_extraction_90</font></b><font face="Courier New">()</font></td>
- <td>Default constructor. </td>
- </tr>
- <tr>
- <td width="586"><b><font face="Courier New">connectivity_extraction_90</font></b><font face="Courier New">(<br /> const
- connectivity_extraction_90& that)</font></td>
- <td>Copy construct.</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">unsigned int <br /><b>insert</b>(const polygon_90_set_data<coordinate_type>& ps)</font></td>
- <td>I<font face="Times New Roman">nsert a polygon set graph node, the
- value returned is the id of the graph node.</font></td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">
+ <li><a href="voronoi_advanced_tutorial.htm">Voronoi Advanced
+Tutorial</a></li>
+ </ul>
+ </div>
+ <h3 class="navbar">Polygon Sponsor</h3>
+ <div style="padding: 5px;" align="center"> <img
+ src="images/intlogo.gif" border="0" height="51" width="127" /><a
+ title="www.adobe.com home page" href="http://www.adobe.com/"
+ tabindex="2" style="border: medium none ;"> </a> </div>
+ </td>
+ <td
+ style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;"
+ valign="top" width="100%">
+<!-- End Header --><br />
+ <p>
+ </p>
+ <h1>Connectivity Extraction 90</h1>
+ <p> </p>
+ <p>The connectivity extraction algorithm constructs the
+connectivity graph where input polygon sets are modeled as graph nodes
+and assigned node ids and overlap/touching between input polygon sets
+is modeled as graph edges. One supported graph formats is
+std::vector<std::set<int> > where node ids index into the
+vector and the sets of integers at each index are the ids of nodes for
+which an edge exists in the graph. It is required that such
+vector pre-allocate sufficient elements to store the graph generated by
+the algorithm, because only the operator[] is used internally to access
+the graph The other supported graph format is
+std::map<int, std::set<int> > which is slightly easier to
+work with, but potentially more expensive. Improving the
+interface to support more generic graph concepts is deferred to future
+work.</p>
+ <p>The following is the declaration of the connectivity
+extraction algorithm.</p>
+ <p><font face="Courier New">template <typename
+coordinate_type><br />
+class connectivity_extraction_90;</font></p>
+ <p>Example code connectivity_extraction_usage.cpp
+demonstrates using the connectivity extraction algorithm to build a
+connectivity graph on geometry.</p>
+ <h2>Member Functions</h2>
+ <table id="table1" border="1" width="100%">
+ <tbody>
+ <tr>
+ <td width="586"><b><font face="Courier New">connectivity_extraction_90</font></b><font
+ face="Courier New">()</font></td>
+ <td>Default constructor. </td>
+ </tr>
+ <tr>
+ <td width="586"><b><font face="Courier New">connectivity_extraction_90</font></b><font
+ face="Courier New">(<br />
+ const connectivity_extraction_90& that)</font></td>
+ <td>Copy construct.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">unsigned int <br />
+ <b>insert</b>(const
+polygon_90_set_data<coordinate_type>& ps)</font></td>
+ <td>I<font face="Times New Roman">nsert a polygon set graph
+node, the value returned is the id of the graph node.</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">
template <class GeoObjT><br />
unsigned int <b>insert</b>(const GeoObjT& geoObj)</font></td>
- <td>Insert a geometry object that is a refinement of polygon 90 set as a
- graph node, the return value is the id of the graph node.</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">
+ <td>Insert a geometry object that is a refinement of
+polygon 90 set as a graph node, the return value is the id of the graph
+node.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">
template <class GraphT><br />
void <b>extract</b>(GraphT& graph)</font></td>
- <td>Accepts a graph object that conforms to the expectations defined
- above. Performs connectivity extraction and populates the graph
- object.</td>
- </tr>
- </tbody></table>
- </td></tr><tr>
-<td style="background-color: rgb(238, 238, 238);" nowrap="1" valign="top">
- </td>
-<td style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;" valign="top" width="100%">
-
-
-<table class="docinfo" id="table2" frame="void" rules="none">
- <colgroup>
- <col class="docinfo-name" /><col class="docinfo-content" />
- </colgroup>
- <tbody valign="top">
- <tr>
- <th class="docinfo-name">Copyright:</th>
- <td>Copyright © Intel Corporation 2008-2010.</td>
- </tr>
- <tr class="field">
- <th class="docinfo-name">License:</th>
- <td class="field-body">Distributed under the Boost Software License,
- Version 1.0. (See accompanying file <tt class="literal">
- <span class="pre">LICENSE_1_0.txt</span></tt> or copy at
- <a class="reference" target="_top" href="http://www.boost.org/LICENSE_1_0.txt">
- http://www.boost.org/LICENSE_1_0.txt>)</td>
- </tr>
-</tbody></table>
-
-</td></tr></tbody></table></body></html>
\ No newline at end of file
+ <td>Accepts a graph object that conforms to the
+expectations defined above. Performs connectivity extraction and
+populates the graph object.</td>
+ </tr>
+ </tbody>
+ </table>
+ </td>
+ </tr>
+ <tr>
+ <td style="background-color: rgb(238, 238, 238);" nowrap="1"
+ valign="top"> </td>
+ <td
+ style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;"
+ valign="top" width="100%">
+ <table class="docinfo" id="table2" frame="void" rules="none">
+ <colgroup> <col class="docinfo-name" /><col
+ class="docinfo-content" /> </colgroup> <tbody valign="top">
+ <tr>
+ <th class="docinfo-name">Copyright:</th>
+ <td>Copyright © Intel Corporation 2008-2010.</td>
+ </tr>
+ <tr class="field">
+ <th class="docinfo-name">License:</th>
+ <td class="field-body">Distributed under the Boost Software
+License, Version 1.0. (See accompanying file <tt class="literal"> <span
+ class="pre">LICENSE_1_0.txt</span></tt> or copy at <a
+ class="reference" target="_top"
+ href="http://www.boost.org/LICENSE_1_0.txt">
+http://www.boost.org/LICENSE_1_0.txt>)</td>
+ </tr>
+ </tbody>
+ </table>
+ </td>
+ </tr>
+ </tbody>
+</table>
+</body>
+</html>
Modified: branches/release/libs/polygon/doc/gtl_coordinate_concept.htm
==============================================================================
--- branches/release/libs/polygon/doc/gtl_coordinate_concept.htm (original)
+++ branches/release/libs/polygon/doc/gtl_coordinate_concept.htm 2013-04-15 18:27:46 EDT (Mon, 15 Apr 2013)
@@ -1,102 +1,114 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:(null)1="http://www.w3.org/TR/REC-html40" lang="en"><head><!--
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"
+ xmlns:v="urn:schemas-microsoft-com:vml"
+ xmlns:o="urn:schemas-microsoft-com:office:office"
+ xmlns:(null)1="http://www.w3.org/TR/REC-html40" lang="en">
+<head>
+<!--
Copyright 2009-2010 Intel Corporation
license banner
---><title>Boost Polygon Library: Coordinate Concept</title>
-
-
-
-
-
- <meta http-equiv="content-type" content="text/html;charset=ISO-8859-1" /><!-- <link type="text/css" rel="stylesheet" href="adobe_source.css"> --></head><body><table style="margin: 0pt; padding: 0pt; width: 100%;" border="0" cellpadding="0" cellspacing="0"><tbody><tr>
-<td style="background-color: rgb(238, 238, 238);" nowrap="1" valign="top">
- <div style="padding: 5px;" align="center">
- <img src="images/boost.png" border="0" height="86" width="277" /><a title="www.boost.org home page" href="http://www.boost.org/" tabindex="2" style="border: medium none ;">
- </a>
- </div>
- <div style="margin: 5px;">
- <h3 class="navbar">Contents</h3>
- <ul>
- <li>Boost.Polygon Main Page</li>
- <li>Design Overview</li>
- <li>Isotropy</li>
- <li>Coordinate Concept</li>
- <li>Interval Concept</li>
- <li>Point Concept</li>
+-->
+ <title>Boost Polygon Library: Coordinate Concept</title>
+ <meta http-equiv="content-type" content="text/html;charset=ISO-8859-1" />
+<!-- <link type="text/css" rel="stylesheet" href="adobe_source.css"> -->
+</head>
+<body>
+<table style="margin: 0pt; padding: 0pt; width: 100%;" border="0"
+ cellpadding="0" cellspacing="0">
+ <tbody>
+ <tr>
+ <td style="background-color: rgb(238, 238, 238);" nowrap="1"
+ valign="top">
+ <div style="padding: 5px;" align="center"> <img
+ src="images/boost.png" border="0" height="86" width="277" /><a
+ title="www.boost.org home page" href="http://www.boost.org/"
+ tabindex="2" style="border: medium none ;"> </a> </div>
+ <div style="margin: 5px;">
+ <h3 class="navbar">Contents</h3>
+ <ul>
+ <li>Boost.Polygon Main Page</li>
+ <li>Design Overview</li>
+ <li>Isotropy</li>
+ <li>Coordinate Concept</li>
+ <li>Interval Concept</li>
+ <li>Point Concept</li>
<li>Segment Concept</li>
-
- <li>Rectangle Concept</li>
- <li>Polygon 90 Concept</li>
- <li>Polygon 90 With Holes Concept</li>
- <li>Polygon 45 Concept</li>
- <li>Polygon 45 With Holes Concept</li>
- <li>Polygon Concept</li>
- <li>Polygon With Holes Concept</li>
- <li>Polygon 90 Set Concept</li>
- <li>Polygon 45 Set Concept</li>
- <li>Polygon Set Concept</li>
- <li>Connectivity Extraction 90</li>
- <li>Connectivity Extraction 45</li>
- <li>Connectivity Extraction</li>
- <li>Property Merge 90</li>
- <li>Property Merge 45</li>
- <li>Property Merge</li>
+ <li>Rectangle Concept</li>
+ <li>Polygon 90 Concept</li>
+ <li><a href="gtl_polygon_90_with_holes_concept.htm">Polygon 90
+With Holes Concept</a></li>
+ <li>Polygon 45 Concept</li>
+ <li><a href="gtl_polygon_45_with_holes_concept.htm">Polygon 45
+With Holes Concept</a></li>
+ <li>Polygon Concept</li>
+ <li><a href="gtl_polygon_with_holes_concept.htm">Polygon With
+Holes Concept</a></li>
+ <li><a href="gtl_polygon_90_set_concept.htm">Polygon 90 Set
+Concept</a></li>
+ <li><a href="gtl_polygon_45_set_concept.htm">Polygon 45 Set
+Concept</a></li>
+ <li>Polygon Set Concept</li>
+ <li><a href="gtl_connectivity_extraction_90.htm">Connectivity
+Extraction 90</a></li>
+ <li><a href="gtl_connectivity_extraction_45.htm">Connectivity
+Extraction 45</a></li>
+ <li><a href="gtl_connectivity_extraction.htm">Connectivity
+Extraction</a></li>
+ <li>Property Merge 90</li>
+ <li>Property Merge 45</li>
+ <li>Property Merge</li>
<li><a href="voronoi_main.htm">Voronoi Main Page<br />
-</a></li>
+ </a></li>
<li>Voronoi Benchmark<br />
</li>
<li>Voronoi Builder</li>
- <li><a href="voronoi_diagram.htm">Voronoi Diagram<br />
-</a></li>
- <li>Voronoi Predicates</li>
- <li>Voronoi Robust FPT<br />
- </li>
-
-
- </ul>
- <h3 class="navbar">Other Resources</h3>
- <ul>
+ <li>Voronoi Diagram</li>
+ </ul>
+ <h3 class="navbar">Other Resources</h3>
+ <ul>
<li>GTL Boostcon 2009 Paper</li>
- <li><a href="GTL_boostcon_draft03.pdf">GTL Boostcon 2009
- Presentation</a></li>
+ <li><a href="GTL_boostcon_draft03.pdf">GTL Boostcon 2009
+Presentation</a></li>
<li>Performance Analysis</li>
<li>Layout Versus Schematic Tutorial</li>
<li>Minkowski Sum Tutorial</li>
<li>Voronoi Basic Tutorial</li>
- <li>Voronoi Advanced Tutorial</li>
-</ul>
- </div>
- <h3 class="navbar">Polygon Sponsor</h3>
- <div style="padding: 5px;" align="center">
- <img src="images/intlogo.gif" border="0" height="51" width="127" /><a title="www.adobe.com home page" href="http://www.adobe.com/" tabindex="2" style="border: medium none ;">
- </a>
- </div>
-</td>
-<td style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;" valign="top" width="100%">
-
-<!-- End Header -->
-
-<br />
-<p>
-</p><h1>Coordinate Concept</h1>
-
-<p>
-The coordinate concept tag is <font face="Courier New">
-coordinate_concept</font></p><p>
-To register a user defined type as a model of coordinate concept, specialize the
-geometry concept meta-function for that type. In the example below
-CCoordinate is registered as a model of coordinate concept.</p><p>
-<font face="Courier New">template <><br />
-struct geometry_concept<CCoordinate> { typedef coordinate_concept type; };</font></p><p>
-The coordinate type is expected to be integral and built-in numerical data types
-such as float and int already have concept type traits specializations in the
-library. In the coordinate traits are type definitions for related types
-are provided to allow the library to choose the best type to cast to under
-various circumstances. The definition of coordinate_traits and its
-specialization for int are shown below.</p><p>
-<font face="Courier New">template <typename T><br />
+ <li><a href="voronoi_advanced_tutorial.htm">Voronoi Advanced
+Tutorial</a></li>
+ </ul>
+ </div>
+ <h3 class="navbar">Polygon Sponsor</h3>
+ <div style="padding: 5px;" align="center"> <img
+ src="images/intlogo.gif" border="0" height="51" width="127" /><a
+ title="www.adobe.com home page" href="http://www.adobe.com/"
+ tabindex="2" style="border: medium none ;"> </a> </div>
+ </td>
+ <td
+ style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;"
+ valign="top" width="100%">
+<!-- End Header --><br />
+ <p>
+ </p>
+ <h1>Coordinate Concept</h1>
+ <p> The coordinate concept tag is <font face="Courier New">
+coordinate_concept</font></p>
+ <p> To register a user defined type as a model of coordinate
+concept, specialize the geometry concept meta-function for that
+type. In the example below CCoordinate is registered as a model
+of coordinate concept.</p>
+ <p> <font face="Courier New">template <><br />
+struct geometry_concept<CCoordinate> { typedef coordinate_concept
+type; };</font></p>
+ <p> The coordinate type is expected to be integral and built-in
+numerical data types such as float and int already have concept type
+traits specializations in the library. In the coordinate traits
+are type definitions for related types are provided to allow the
+library to choose the best type to cast to under various
+circumstances. The definition of coordinate_traits and its
+specialization for int are shown below.</p>
+ <p> <font face="Courier New">template <typename T><br />
struct coordinate_traits {};<br />
-<br />
+ <br />
template <><br />
struct coordinate_traits<int> {<br />
typedef int coordinate_type;<br />
@@ -105,58 +117,71 @@
typedef unsigned long long unsigned_area_type;<br />
typedef long long coordinate_difference;<br />
typedef long double coordinate_distance;<br />
-};</font></p><p>
-By making use of the coordinate traits of int the library is able to avoid
-overflow and handle the normal issues encountered when programming integer
-geometry. For the out of the ordinary issues there is a special
-meta-function that provides the library with a numerical type suitable for exact
-numerical calculations. It defaults to the highest precision data type
-available in most compilers, long double, but can be overridden by specializing
-for a particular coordinate type. Use of gmp multi-precision rational or
-similar data type is recommended for numerically robust calculations in the
-general polygon algorithms.</p><p>
-<font face="Courier New">template <typename T><br />
+};</font></p>
+ <p> By making use of the coordinate traits of int the library is
+able to avoid overflow and handle the normal issues encountered when
+programming integer geometry. For the out of the ordinary issues
+there is a special meta-function that provides the library with a
+numerical type suitable for exact numerical calculations. It
+defaults to the highest precision data type available in most
+compilers, long double, but can be overridden by specializing for a
+particular coordinate type. Use of gmp multi-precision rational
+or similar data type is recommended for numerically robust calculations
+in the general polygon algorithms.</p>
+ <p> <font face="Courier New">template <typename T><br />
struct high_precision_type {<br />
typedef long double type;<br />
-};</font></p><p>
-There is only one generic function on coordinate concepts, Euclidean distance.</p><p>
-<font face="Courier New">template <typename coordinate_type_1, typename
-coordinate_type_2><br />
-coordinate_difference euclidean_distance(coordinate_type_1, coordinate_type_2)</font></p><p>
-This function returns the absolution value of the difference between the two
-coordinates.</p><p>
-Note: older versions of the stl define a fully generic distance(T, T) function
-for computing the difference between two iterators. We were forced to name
-our distance function euclidean_distance to avoid name collision.</p><p>
-The
-<a href="http://www.mentor.com/products/esl/high_level_synthesis/ac_datatypes">
-Algorithmic C</a> ac_int<128> is an example of a user defined coordinate data
-type that satisfies the coordinate concept. In general a data type should
-define std::numeric_limits and be integer-like. Floating point coordinate
-types are not supported by all the algorithms and generally not suitable for use
-with the library at present.</p></td></tr><tr>
-<td style="background-color: rgb(238, 238, 238);" nowrap="1" valign="top">
- </td>
-<td style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;" valign="top" width="100%">
-
-
-<table class="docinfo" id="table1" frame="void" rules="none">
- <colgroup>
- <col class="docinfo-name" /><col class="docinfo-content" />
- </colgroup>
- <tbody valign="top">
- <tr>
- <th class="docinfo-name">Copyright:</th>
- <td>Copyright © Intel Corporation 2008-2010.</td>
- </tr>
- <tr class="field">
- <th class="docinfo-name">License:</th>
- <td class="field-body">Distributed under the Boost Software License,
- Version 1.0. (See accompanying file <tt class="literal">
- <span class="pre">LICENSE_1_0.txt</span></tt> or copy at
- <a class="reference" target="_top" href="http://www.boost.org/LICENSE_1_0.txt">
- http://www.boost.org/LICENSE_1_0.txt>)</td>
- </tr>
-</tbody></table>
-
-</td></tr></tbody></table></body></html>
\ No newline at end of file
+};</font></p>
+ <p> There is only one generic function on coordinate concepts,
+Euclidean distance.</p>
+ <p> <font face="Courier New">template <typename
+coordinate_type_1, typename coordinate_type_2><br />
+coordinate_difference euclidean_distance(coordinate_type_1,
+coordinate_type_2)</font></p>
+ <p> This function returns the absolution value of the difference
+between the two coordinates.</p>
+ <p> Note: older versions of the stl define a fully generic
+distance(T, T) function for computing the difference between two
+iterators. We were forced to name our distance function
+euclidean_distance to avoid name collision.</p>
+ <p> The
+ <a
+ href="http://www.mentor.com/products/esl/high_level_synthesis/ac_datatypes">
+Algorithmic C</a> ac_int<128> is an example of a user defined
+coordinate data type that satisfies the coordinate concept. In
+general a data type should define std::numeric_limits and be
+integer-like. Floating point coordinate types are not supported
+by all the algorithms and generally not suitable for use with the
+library at present.</p>
+ </td>
+ </tr>
+ <tr>
+ <td style="background-color: rgb(238, 238, 238);" nowrap="1"
+ valign="top"> </td>
+ <td
+ style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;"
+ valign="top" width="100%">
+ <table class="docinfo" id="table1" frame="void" rules="none">
+ <colgroup> <col class="docinfo-name" /><col
+ class="docinfo-content" /> </colgroup> <tbody valign="top">
+ <tr>
+ <th class="docinfo-name">Copyright:</th>
+ <td>Copyright © Intel Corporation 2008-2010.</td>
+ </tr>
+ <tr class="field">
+ <th class="docinfo-name">License:</th>
+ <td class="field-body">Distributed under the Boost Software
+License, Version 1.0. (See accompanying file <tt class="literal"> <span
+ class="pre">LICENSE_1_0.txt</span></tt> or copy at <a
+ class="reference" target="_top"
+ href="http://www.boost.org/LICENSE_1_0.txt">
+http://www.boost.org/LICENSE_1_0.txt>)</td>
+ </tr>
+ </tbody>
+ </table>
+ </td>
+ </tr>
+ </tbody>
+</table>
+</body>
+</html>
Modified: branches/release/libs/polygon/doc/gtl_custom_point.htm
==============================================================================
--- branches/release/libs/polygon/doc/gtl_custom_point.htm (original)
+++ branches/release/libs/polygon/doc/gtl_custom_point.htm 2013-04-15 18:27:46 EDT (Mon, 15 Apr 2013)
@@ -1,11 +1,8 @@
-<html>
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
+<html><head>
-<head>
-<meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
-<title>Custom Point</title>
-</head>
-<body>
+<meta http-equiv="Content-Type" content="text/html; charset=windows-1252"><title>Custom Point</title></head><body>
<p><font face="Courier New">/*<br>
Copyright 2008 Intel Corporation<br>
@@ -95,7 +92,11 @@
};<br>
<br>
template <><br>
-struct point_mutable_traits<CPoint> {<br>
+struct point_mutable_traits<CPoint> {<br>
+ typedef int coordinate_type;<br>
+<br>
+</font></p>
+<p><font face="Courier New">
static inline void set(CPoint& point, orientation_2d orient, int value) {<br>
@@ -137,11 +138,12 @@
</font></p>
-<table class="docinfo" rules="none" frame="void" id="table1">
+
+<table class="docinfo" id="table1" frame="void" rules="none">
<colgroup>
<col class="docinfo-name"><col class="docinfo-content">
</colgroup>
- <tbody vAlign="top">
+ <tbody valign="top">
<tr>
<th class="docinfo-name">Copyright:</th>
<td>Copyright © Intel Corporation 2008-2010.</td>
@@ -154,8 +156,6 @@
<a class="reference" target="_top" href="http://www.boost.org/LICENSE_1_0.txt">
http://www.boost.org/LICENSE_1_0.txt>)</td>
</tr>
-</table>
-
-</body>
+</tbody></table>
-</html>
+</body></html>
\ No newline at end of file
Modified: branches/release/libs/polygon/doc/gtl_design_overview.htm
==============================================================================
--- branches/release/libs/polygon/doc/gtl_design_overview.htm (original)
+++ branches/release/libs/polygon/doc/gtl_design_overview.htm 2013-04-15 18:27:46 EDT (Mon, 15 Apr 2013)
@@ -1,194 +1,224 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:(null)1="http://www.w3.org/TR/REC-html40" lang="en"><head>
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"
+ xmlns:v="urn:schemas-microsoft-com:vml"
+ xmlns:o="urn:schemas-microsoft-com:office:office"
+ xmlns:(null)1="http://www.w3.org/TR/REC-html40" lang="en">
+<head>
<!--
Copyright 2009-2010 Intel Corporation
license banner
---><title>Boost Polygon Library: Overview</title>
-
-
-
- <meta http-equiv="content-type" content="text/html;charset=ISO-8859-1" /><!-- <link type="text/css" rel="stylesheet" href="adobe_source.css"> --></head><body><table style="margin: 0pt; padding: 0pt; width: 100%;" border="0" cellpadding="0" cellspacing="0"><tbody><tr>
-<td style="background-color: rgb(238, 238, 238);" nowrap="1" valign="top">
- <div style="padding: 5px;" align="center">
- <img src="images/boost.png" border="0" height="86" width="277" /><a title="www.boost.org home page" href="http://www.boost.org/" tabindex="2" style="border: medium none ;">
- </a>
- </div>
- <div style="margin: 5px;">
- <h3 class="navbar">Contents</h3>
- <ul>
- <li>Boost.Polygon Main Page</li>
- <li>Design Overview</li>
- <li>Isotropy</li>
- <li>Coordinate Concept</li>
- <li>Interval Concept</li>
- <li>
- Point Concept</li>
+-->
+ <title>Boost Polygon Library: Overview</title>
+ <meta http-equiv="content-type" content="text/html;charset=ISO-8859-1" />
+<!-- <link type="text/css" rel="stylesheet" href="adobe_source.css"> -->
+</head>
+<body>
+<table style="margin: 0pt; padding: 0pt; width: 100%;" border="0"
+ cellpadding="0" cellspacing="0">
+ <tbody>
+ <tr>
+ <td style="background-color: rgb(238, 238, 238);" nowrap="1"
+ valign="top">
+ <div style="padding: 5px;" align="center"> <img
+ src="images/boost.png" border="0" height="86" width="277" /><a
+ title="www.boost.org home page" href="http://www.boost.org/"
+ tabindex="2" style="border: medium none ;"> </a> </div>
+ <div style="margin: 5px;">
+ <h3 class="navbar">Contents</h3>
+ <ul>
+ <li>Boost.Polygon Main Page</li>
+ <li>Design Overview</li>
+ <li>Isotropy</li>
+ <li>Coordinate Concept</li>
+ <li>Interval Concept</li>
+ <li> Point Concept</li>
<li>Segment Concept</li>
-
- <li>Rectangle Concept</li>
- <li>Polygon 90 Concept</li>
- <li>Polygon 90 With Holes Concept</li>
- <li>Polygon 45 Concept</li>
- <li>Polygon 45 With Holes Concept</li>
- <li>Polygon Concept</li>
- <li>Polygon With Holes Concept</li>
- <li>Polygon 90 Set Concept</li>
- <li>Polygon 45 Set Concept</li>
- <li>Polygon Set Concept</li>
- <li>Connectivity Extraction 90</li>
- <li>Connectivity Extraction 45</li>
- <li>Connectivity Extraction</li>
- <li>Property Merge 90</li>
- <li>Property Merge 45</li>
- <li>Property Merge</li>
+ <li>Rectangle Concept</li>
+ <li>Polygon 90 Concept</li>
+ <li><a href="gtl_polygon_90_with_holes_concept.htm">Polygon 90
+With Holes Concept</a></li>
+ <li>Polygon 45 Concept</li>
+ <li><a href="gtl_polygon_45_with_holes_concept.htm">Polygon 45
+With Holes Concept</a></li>
+ <li>Polygon Concept</li>
+ <li><a href="gtl_polygon_with_holes_concept.htm">Polygon With
+Holes Concept</a></li>
+ <li><a href="gtl_polygon_90_set_concept.htm">Polygon 90 Set
+Concept</a></li>
+ <li><a href="gtl_polygon_45_set_concept.htm">Polygon 45 Set
+Concept</a></li>
+ <li>Polygon Set Concept</li>
+ <li><a href="gtl_connectivity_extraction_90.htm">Connectivity
+Extraction 90</a></li>
+ <li><a href="gtl_connectivity_extraction_45.htm">Connectivity
+Extraction 45</a></li>
+ <li><a href="gtl_connectivity_extraction.htm">Connectivity
+Extraction</a></li>
+ <li>Property Merge 90</li>
+ <li>Property Merge 45</li>
+ <li>Property Merge</li>
<li><a href="voronoi_main.htm">Voronoi Main Page<br />
-</a></li>
+ </a></li>
<li>Voronoi Benchmark<br />
</li>
<li>Voronoi Builder</li>
- <li><a href="voronoi_diagram.htm">Voronoi Diagram<br />
-</a></li>
- <li>Voronoi Predicates</li>
- <li>Voronoi Robust FPT<br />
- </li>
-
-
- </ul>
- <h3 class="navbar">Other Resources</h3>
- <ul>
- <li>GTL Boostcon 2009 Paper</li>
- <li><a href="GTL_boostcon_draft03.pdf">GTL Boostcon 2009
- Presentation</a></li>
- <li>Performance Analysis</li>
- <li>Layout Versus Schematic Tutorial</li>
- <li>Minkowski Sum Tutorial</li>
+ <li>Voronoi Diagram</li>
+ </ul>
+ <h3 class="navbar">Other Resources</h3>
+ <ul>
+ <li>GTL Boostcon 2009 Paper</li>
+ <li><a href="GTL_boostcon_draft03.pdf">GTL Boostcon 2009
+Presentation</a></li>
+ <li>Performance Analysis</li>
+ <li>Layout Versus Schematic Tutorial</li>
+ <li>Minkowski Sum Tutorial</li>
<li>Voronoi Basic Tutorial</li>
- <li>Voronoi Advanced Tutorial</li>
-
- </ul>
- </div>
- <h3 class="navbar">Polygon Sponsor</h3>
- <div style="padding: 5px;" align="center">
- <img src="images/intlogo.gif" border="0" height="51" width="127" /><a title="www.adobe.com home page" href="http://www.adobe.com/" tabindex="2" style="border: medium none ;">
- </a>
- </div>
-</td>
-<td style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;" valign="top" width="100%">
-
-<!-- End Header -->
-
-<br />
-<p>
-</p><h1>Polygon Library Design Overview</h1>
-
-<p>
-</p><p>The Polygon library uses C++-Concepts inspired template programming to
-provide generic library functions overloaded on concept type. There are
-currently thirteen concepts in the Polygon library type system. A concept
-object in the Polygon library is just an empty struct similar to a tag that
-would be used for tag dispatching. These concepts are shown in the
-refinement diagram below.</p>
-
-
-<img src="images/refinements.png" border="0" height="369" width="466" /><p>
-The arrows between diagram bubbles show concept refinement relationships. This is
-similar, but not identical to, inheritance relationships between normal classes.
-A refinement of a concept narrows down the definition of a more general concept.
-For example, the rectangle concept is a refinement of a polygon concept because
-it restricts the polygon to a four sided, axis-parallel, rectilinear figure. A refinement
-of a concept is always acceptable to an API that expects read only access to a
-given concept, but never acceptable to an API that expects to write to that
-concept. There are three types of geometry in the polygon library, the
-general case, the case restricted to angles that are multiples of 45 degrees,
-and the Manhattan/rectilinear case where angles are restricted to multiples of
-90 degrees. The refinement diagram shows that 90 degree concepts are
-refinements of 45 degree concepts, which are themselves refinements of the
-general case. This allows the compiler to choose between the three
-implementations of algorithms to select the best algorithm for the conceptual
-data types passed to an overload of a function including heterogeneous
-combinations of 90, 45 and general case geometry. To provide the
-<font face="Courier New">operator&</font> that performs the intersection on any
-pair of objects from the ten conceptual types related to each other through
-refinement in the diagraph above fully one hundred distinct combinations of
-conceptual types are supported by the library, but only three overloads are
-required to implement the operator (one for 90, one for 45 and one for arbitrary
-angle version of the intersection operation) because refinement generalizes the
-implementation of the interface. In this way a fully symmetric, complete
-and internally consistent API is implemented to provide meaningful and correct
-behaviors for all combinations of argument types in all APIs where those types
-make sense. For example, it doesn't make sense to copy data from a polygon
-into a rectangle, so attempting to do so yields a syntax error, while copying a
-rectangle into a polygon does make sense. The <font face="Courier New">
-assign()</font> function that is used to copy geometry data between concepts
-instantiates for the 49 combinations of concepts that make sense, but not for
-the 51 combinations that are illegal. The syntax error you will see when
-attempting an illegal assign operation is simple and clear because use of SFINAE
-by the library to overload generic functions means no matching function is found
-by the compiler in cases where no overload is provided.</p>
-<p>
-<font face="Courier New">error: no matching function for call to 'assign(rectangle_data<int>&,
-polygon_data<int>&)'</font></p>
-<p>Associated with each concept is a traits struct that generally must be
-specialized for a given data type to provide the concept mapping between the
-interfaces of the data type and the expected behaviors of an object of that type
-required by the library. The library also provides its own data types for
-each concept that conform to the default traits definition. These library
-provided data types are no more than dumb containers that provide access to
-their data and rely on the generic library functions to enforce invariants and
-provide useful behaviors specific to their type of geometry that would normally
-be member functions of the data type in an OO design. The library data
-types conform to the default traits associated with their related geometry
-concept and are registered as models of that concept. When a data
-type has been mapped to a concept through traits it needs to be registered
-as that conceptual type with the library by
-specializing the geometry_concept meta-function. Once mapped and
-registered, a user data type can be used interchangeably with library data types
-in the generic free functions that are overloaded on concept.</p><p>Traits for
-mapping a data type to a concept are broken down into mutable and read only
-traits. Read only traits are specialized internally to work with any types
-that are refinements of a concept. The mutable traits are defined only for
-objects that exactly model the concept. Both read only traits and mutable
-traits need to be defined for a type to model a concept, but a type can be used
-without defining the mutable traits as long as no API that needs to modify the
-object is used with that type. For example, a triangle type could be
-registered as a polygon_concept and the read only traits but not the mutable
-traits defined for that triangle type. This would allow the triangle type
-to be passed into any API that expects a const reference to an object that models
-polygon.
-</p><p>An object that is a model of a given concept can usually be viewed as a model of any of its
-refinements if it is determined at runtime to conform to the restrictions of
-those concepts. This concept casting is accomplished through the
-<font face="Courier New">view_as<>()</font> function. For example if
-an object of conceptual type polygon 90 has four sides it must be a rectangle,
-and can be viewed as a rectangle with the following syntax:</p>
-<p><font face="Courier New">view_as<rectangle_concept>(polygon_90_object)</font></p>
-<p>The return value of <font face="Courier New">view_as<>()</font> can be
-passed into any interface that expects an object of the conceptual type
-specified in its template parameter. The exception to this ability to
-concept cast geometric objects is that polygon set objects cannot be viewed as
-individual polygons or rectangles.</p> </td></tr><tr>
-<td style="background-color: rgb(238, 238, 238);" nowrap="1" valign="top">
- </td>
-<td style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;" valign="top" width="100%">
-
-
-<table class="docinfo" id="table1" frame="void" rules="none">
- <colgroup>
- <col class="docinfo-name" /><col class="docinfo-content" />
- </colgroup>
- <tbody valign="top">
- <tr>
- <th class="docinfo-name">Copyright:</th>
- <td>Copyright © Intel Corporation 2008-2010.</td>
- </tr>
- <tr class="field">
- <th class="docinfo-name">License:</th>
- <td class="field-body">Distributed under the Boost Software License,
- Version 1.0. (See accompanying file <tt class="literal">
- <span class="pre">LICENSE_1_0.txt</span></tt> or copy at
- <a class="reference" target="_top" href="http://www.boost.org/LICENSE_1_0.txt">
- http://www.boost.org/LICENSE_1_0.txt>)</td>
- </tr>
-</tbody></table>
-
-</td></tr></tbody></table></body></html>
\ No newline at end of file
+ <li><a href="voronoi_advanced_tutorial.htm">Voronoi Advanced
+Tutorial</a></li>
+ </ul>
+ </div>
+ <h3 class="navbar">Polygon Sponsor</h3>
+ <div style="padding: 5px;" align="center"> <img
+ src="images/intlogo.gif" border="0" height="51" width="127" /><a
+ title="www.adobe.com home page" href="http://www.adobe.com/"
+ tabindex="2" style="border: medium none ;"> </a> </div>
+ </td>
+ <td
+ style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;"
+ valign="top" width="100%">
+<!-- End Header --><br />
+ <p>
+ </p>
+ <h1>Polygon Library Design Overview</h1>
+ <p> </p>
+ <p>The Polygon library uses C++-Concepts inspired template
+programming to provide generic library functions overloaded on concept
+type. There are currently thirteen concepts in the Polygon
+library type system. A concept object in the Polygon library is
+just an empty struct similar to a tag that would be used for tag
+dispatching. These concepts are shown in the refinement
+diagram below.</p>
+ <img src="images/refinements.png" border="0" height="369"
+ width="466" />
+ <p>The arrows between diagram bubbles show concept refinement
+relationships. This is similar, but not identical to, inheritance
+relationships between normal classes. A refinement of a concept
+narrows down the definition of a more general concept. For
+example, the rectangle concept is a refinement of a polygon concept
+because it restricts the polygon to a four sided, axis-parallel,
+rectilinear figure. A refinement of a concept is always
+acceptable to an API that expects read only access to a given concept,
+but never acceptable to an API that expects to write to that
+concept. There are three types of geometry in the polygon
+library, the general case, the case restricted to angles that are
+multiples of 45 degrees, and the Manhattan/rectilinear case where
+angles are restricted to multiples of 90 degrees. The
+refinement diagram shows that 90 degree concepts are refinements of 45
+degree concepts, which are themselves refinements of the general
+case. This allows the compiler to choose between the three
+implementations of algorithms to select the best algorithm for the
+conceptual data types passed to an overload of a function including
+heterogeneous combinations of 90, 45 and general case geometry.
+To provide the
+ <font face="Courier New">operator&</font> that performs the
+intersection on any pair of objects from the ten conceptual types
+related to each other through refinement in the diagraph above fully
+one hundred distinct combinations of conceptual types are supported by
+the library, but only three overloads are required to implement the
+operator (one for 90, one for 45 and one for arbitrary angle version of
+the intersection operation) because refinement generalizes the
+implementation of the interface. In this way a fully symmetric,
+complete and internally consistent API is implemented to provide
+meaningful and correct behaviors for all combinations of argument types
+in all APIs where those types make sense. For example, it doesn't
+make sense to copy data from a polygon into a rectangle, so attempting
+to do so yields a syntax error, while copying a rectangle into a
+polygon does make sense. The <font face="Courier New">
+assign()</font> function that is used to copy geometry data between
+concepts instantiates for the 49 combinations of concepts that make
+sense, but not for the 51 combinations that are illegal. The
+syntax error you will see when attempting an illegal assign operation
+is simple and clear because use of SFINAE by the library to overload
+generic functions means no matching function is found by the compiler
+in cases where no overload is provided.</p>
+ <p>
+ <font face="Courier New">error: no matching function for call to
+'assign(rectangle_data<int>&, polygon_data<int>&)'</font></p>
+ <p>Associated with each concept is a traits struct that generally
+must be specialized for a given data type to provide the concept
+mapping between the interfaces of the data type and the expected
+behaviors of an object of that type required by the library. The
+library also provides its own data types for each concept that conform
+to the default traits definition. These library provided data
+types are no more than dumb containers that provide access to their
+data and rely on the generic library functions to enforce invariants
+and provide useful behaviors specific to their type of geometry that
+would normally be member functions of the data type in an OO
+design. The library data types conform to the default traits
+associated with their related geometry concept and are registered as
+models of that concept. When a data type has been mapped to a
+concept through traits it needs to be registered as that conceptual
+type with the library by specializing the geometry_concept
+meta-function. Once mapped and registered, a user data type can
+be used interchangeably with library data types in the generic free
+functions that are overloaded on concept.</p>
+ <p>Traits for mapping a data type to a concept are broken down
+into mutable and read only traits. Read only traits are
+specialized internally to work with any types that are refinements of a
+concept. The mutable traits are defined only for objects that
+exactly model the concept. Both read only traits and mutable
+traits need to be defined for a type to model a concept, but a type can
+be used without defining the mutable traits as long as no API that
+needs to modify the object is used with that type. For example, a
+triangle type could be registered as a polygon_concept and the read
+only traits but not the mutable traits defined for that triangle
+type. This would allow the triangle type to be passed into any
+API that expects a const reference to an object that models
+polygon. </p>
+ <p>An object that is a model of a given concept can usually be
+viewed as a model of any of its refinements if it is determined at
+runtime to conform to the restrictions of those concepts. This
+concept casting is accomplished through the
+ <font face="Courier New">view_as<>()</font> function.
+For example if an object of conceptual type polygon 90 has four sides
+it must be a rectangle, and can be viewed as a rectangle with the
+following syntax:</p>
+ <p><font face="Courier New">view_as<rectangle_concept>(polygon_90_object)</font></p>
+ <p>The return value of <font face="Courier New">view_as<>()</font>
+can be passed into any interface that expects an object of the
+conceptual type specified in its template parameter. The
+exception to this ability to concept cast geometric objects is that
+polygon set objects cannot be viewed as individual polygons or
+rectangles.</p>
+ </td>
+ </tr>
+ <tr>
+ <td style="background-color: rgb(238, 238, 238);" nowrap="1"
+ valign="top"> </td>
+ <td
+ style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;"
+ valign="top" width="100%">
+ <table class="docinfo" id="table1" frame="void" rules="none">
+ <colgroup> <col class="docinfo-name" /><col
+ class="docinfo-content" /> </colgroup> <tbody valign="top">
+ <tr>
+ <th class="docinfo-name">Copyright:</th>
+ <td>Copyright © Intel Corporation 2008-2010.</td>
+ </tr>
+ <tr class="field">
+ <th class="docinfo-name">License:</th>
+ <td class="field-body">Distributed under the Boost Software
+License, Version 1.0. (See accompanying file <tt class="literal"> <span
+ class="pre">LICENSE_1_0.txt</span></tt> or copy at <a
+ class="reference" target="_top"
+ href="http://www.boost.org/LICENSE_1_0.txt">
+http://www.boost.org/LICENSE_1_0.txt>)</td>
+ </tr>
+ </tbody>
+ </table>
+ </td>
+ </tr>
+ </tbody>
+</table>
+</body>
+</html>
Modified: branches/release/libs/polygon/doc/gtl_interval_concept.htm
==============================================================================
--- branches/release/libs/polygon/doc/gtl_interval_concept.htm (original)
+++ branches/release/libs/polygon/doc/gtl_interval_concept.htm 2013-04-15 18:27:46 EDT (Mon, 15 Apr 2013)
@@ -1,555 +1,620 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:(null)1="http://www.w3.org/TR/REC-html40" lang="en"><head>
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"
+ xmlns:v="urn:schemas-microsoft-com:vml"
+ xmlns:o="urn:schemas-microsoft-com:office:office"
+ xmlns:(null)1="http://www.w3.org/TR/REC-html40" lang="en">
+<head>
<!--
Copyright 2009-2010 Intel Corporation
license banner
---><title>Boost Polygon Library: Interval Concept</title>
-
-
-
-
-
- <meta http-equiv="content-type" content="text/html;charset=ISO-8859-1" /><!-- <link type="text/css" rel="stylesheet" href="adobe_source.css"> --></head><body><table style="margin: 0pt; padding: 0pt; width: 100%;" border="0" cellpadding="0" cellspacing="0"><tbody><tr>
-<td style="background-color: rgb(238, 238, 238);" nowrap="1" valign="top">
- <div style="padding: 5px;" align="center">
- <img src="images/boost.png" border="0" height="86" width="277" /><a title="www.boost.org home page" href="http://www.boost.org/" tabindex="2" style="border: medium none ;">
- </a>
- </div>
- <div style="margin: 5px;">
- <h3 class="navbar">Contents</h3>
- <ul>
- <li>Boost.Polygon Main Page</li>
- <li>Design Overview</li>
- <li>Isotropy</li>
- <li>Coordinate Concept</li>
- <li>Interval Concept</li>
- <li>Point Concept</li>
+-->
+ <title>Boost Polygon Library: Interval Concept</title>
+ <meta http-equiv="content-type" content="text/html;charset=ISO-8859-1" />
+<!-- <link type="text/css" rel="stylesheet" href="adobe_source.css"> -->
+</head>
+<body>
+<table style="margin: 0pt; padding: 0pt; width: 100%;" border="0"
+ cellpadding="0" cellspacing="0">
+ <tbody>
+ <tr>
+ <td style="background-color: rgb(238, 238, 238);" nowrap="1"
+ valign="top">
+ <div style="padding: 5px;" align="center"> <img
+ src="images/boost.png" border="0" height="86" width="277" /><a
+ title="www.boost.org home page" href="http://www.boost.org/"
+ tabindex="2" style="border: medium none ;"> </a> </div>
+ <div style="margin: 5px;">
+ <h3 class="navbar">Contents</h3>
+ <ul>
+ <li>Boost.Polygon Main Page</li>
+ <li>Design Overview</li>
+ <li>Isotropy</li>
+ <li>Coordinate Concept</li>
+ <li>Interval Concept</li>
+ <li>Point Concept</li>
<li>Segment Concept</li>
-
- <li>Rectangle Concept</li>
- <li>Polygon 90 Concept</li>
- <li>Polygon 90 With Holes Concept</li>
- <li>Polygon 45 Concept</li>
- <li>Polygon 45 With Holes Concept</li>
- <li>Polygon Concept</li>
- <li>Polygon With Holes Concept</li>
- <li>Polygon 90 Set Concept</li>
- <li>Polygon 45 Set Concept</li>
- <li>Polygon Set Concept</li>
- <li>Connectivity Extraction 90</li>
- <li>Connectivity Extraction 45</li>
- <li>Connectivity Extraction</li>
- <li>Property Merge 90</li>
- <li>Property Merge 45</li>
- <li>Property Merge</li>
+ <li>Rectangle Concept</li>
+ <li>Polygon 90 Concept</li>
+ <li><a href="gtl_polygon_90_with_holes_concept.htm">Polygon 90
+With Holes Concept</a></li>
+ <li>Polygon 45 Concept</li>
+ <li><a href="gtl_polygon_45_with_holes_concept.htm">Polygon 45
+With Holes Concept</a></li>
+ <li>Polygon Concept</li>
+ <li><a href="gtl_polygon_with_holes_concept.htm">Polygon With
+Holes Concept</a></li>
+ <li><a href="gtl_polygon_90_set_concept.htm">Polygon 90 Set
+Concept</a></li>
+ <li><a href="gtl_polygon_45_set_concept.htm">Polygon 45 Set
+Concept</a></li>
+ <li>Polygon Set Concept</li>
+ <li><a href="gtl_connectivity_extraction_90.htm">Connectivity
+Extraction 90</a></li>
+ <li><a href="gtl_connectivity_extraction_45.htm">Connectivity
+Extraction 45</a></li>
+ <li><a href="gtl_connectivity_extraction.htm">Connectivity
+Extraction</a></li>
+ <li>Property Merge 90</li>
+ <li>Property Merge 45</li>
+ <li>Property Merge</li>
<li><a href="voronoi_main.htm">Voronoi Main Page<br />
-</a></li>
+ </a></li>
<li>Voronoi Benchmark<br />
</li>
<li>Voronoi Builder</li>
- <li><a href="voronoi_diagram.htm">Voronoi Diagram<br />
-</a></li>
- <li>Voronoi Predicates</li>
- <li>Voronoi Robust FPT<br />
- </li>
-
-
- </ul>
- <h3 class="navbar">Other Resources</h3>
- <ul>
- <li>GTL Boostcon 2009 Paper</li>
- <li><a href="GTL_boostcon_draft03.pdf">GTL Boostcon 2009
- Presentation</a></li>
- <li>Performance Analysis</li>
- <li>Layout Versus Schematic Tutorial</li>
- <li>Minkowski Sum Tutorial</li>
+ <li>Voronoi Diagram</li>
+ </ul>
+ <h3 class="navbar">Other Resources</h3>
+ <ul>
+ <li>GTL Boostcon 2009 Paper</li>
+ <li><a href="GTL_boostcon_draft03.pdf">GTL Boostcon 2009
+Presentation</a></li>
+ <li>Performance Analysis</li>
+ <li>Layout Versus Schematic Tutorial</li>
+ <li>Minkowski Sum Tutorial</li>
<li>Voronoi Basic Tutorial</li>
- <li>Voronoi Advanced Tutorial</li>
-
- </ul>
- </div>
- <h3 class="navbar">Polygon Sponsor</h3>
- <div style="padding: 5px;" align="center">
- <img src="images/intlogo.gif" border="0" height="51" width="127" /><a title="www.adobe.com home page" href="http://www.adobe.com/" tabindex="2" style="border: medium none ;">
- </a>
- </div>
-</td>
-<td style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;" valign="top" width="100%">
-
-<!-- End Header -->
-
-<br />
-<p>
-</p><h1>Interval Concept</h1>
-
-<p>
-</p><p>The interval concept tag is <font face="Courier New">
+ <li><a href="voronoi_advanced_tutorial.htm">Voronoi Advanced
+Tutorial</a></li>
+ </ul>
+ </div>
+ <h3 class="navbar">Polygon Sponsor</h3>
+ <div style="padding: 5px;" align="center"> <img
+ src="images/intlogo.gif" border="0" height="51" width="127" /><a
+ title="www.adobe.com home page" href="http://www.adobe.com/"
+ tabindex="2" style="border: medium none ;"> </a> </div>
+ </td>
+ <td
+ style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;"
+ valign="top" width="100%">
+<!-- End Header --><br />
+ <p>
+ </p>
+ <h1>Interval Concept</h1>
+ <p> </p>
+ <p>The interval concept tag is <font face="Courier New">
interval_concept</font></p>
-<p>
-To register a user defined type as a model of interval concept, specialize the
-geometry concept meta-function for that type. In the example below
-CInterval is registered as a model of interval concept.</p><p>
-<font face="Courier New">template <><br />
-struct geometry_concept<CInterval> { typedef interval_concept type; };</font></p><p>
-<font face="Times New Roman">The semantic of an interval is that it has a low
-and high coordinate and there is an invariant that low is less than or equal to
-high. This invariant is enforced by the generic library functions that
-operate on intervals, and is not expected of the data type itself or the concept
-mapping of that data type to the interval concept through its traits. In
-this way a std::pair<int, int>, boost::tuple<int, int> or boost::array<int, 2>
-could all be made models of interval by simply providing indirect access to their
-elements through traits.</font></p><p>
-<font face="Times New Roman">Below is shown the default interval traits.
-Specialization of these traits is required for types that don't conform to the
-default behavior.</font></p><p>
-<font face="Courier New">template <typename T><br />
+ <p> To register a user defined type as a model of interval
+concept, specialize the geometry concept meta-function for that
+type. In the example below CInterval is registered as a model of
+interval concept.</p>
+ <p> <font face="Courier New">template <><br />
+struct geometry_concept<CInterval> { typedef interval_concept
+type; };</font></p>
+ <p> <font face="Times New Roman">The semantic of an interval is
+that it has a low and high coordinate and there is an invariant that
+low is less than or equal to high. This invariant is enforced by
+the generic library functions that operate on intervals, and is not
+expected of the data type itself or the concept mapping of that data
+type to the interval concept through its traits. In this way a
+std::pair<int, int>, boost::tuple<int, int> or
+boost::array<int, 2> could all be made models of interval by
+simply providing indirect access to their elements through traits.</font></p>
+ <p> <font face="Times New Roman">Below is shown the default
+interval traits. Specialization of these traits is required for
+types that don't conform to the default behavior.</font></p>
+ <p> <font face="Courier New">template <typename T><br />
struct interval_traits {<br />
typedef typename T::coordinate_type coordinate_type;<br />
-<br />
- static inline coordinate_type get(const T& interval, direction_1d dir) {<br />
+ <br />
+ static inline coordinate_type get(const T& interval,
+direction_1d dir) {<br />
return interval.get(dir); <br />
}<br />
};<br />
-<br />
+ <br />
template <typename T><br />
struct interval_mutable_traits {<br />
+ </font><font face="Courier New">typedef typename
+T::coordinate_type coordinate_type;</font><br />
+ <font face="Courier New"><br />
static inline void set(T& interval, direction_1d dir, </font>
-<br />
-<font face="Courier New">
+ <br />
+ <font face="Courier New">
typename interval_traits<T>::coordinate_type value) {<br />
interval.set(dir, value); <br />
}<br />
-static inline T construct(typename interval_traits<T>::coordinate_type low_value,
-<br />
+static inline T construct(typename
+interval_traits<T>::coordinate_type low_value,
+ <br />
typename interval_traits<T>::coordinate_type high_value) {<br />
return T(low_value, high_value); <br />
}<br />
-};</font></p><h2>Functions</h2>
-<table id="table1" border="1" width="100%">
- <tbody><tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- coordinate_type <b>get</b>(const T& interval, direction_1d)</font></td>
- <td><font face="Times New Roman">Expects a model of interval.
- Returns the low or high coordinate of the interval, depending on the
- direction_1d value.</font><font face="Courier New"><br />
+};</font></p>
+ <h2>Functions</h2>
+ <table id="table1" border="1" width="100%">
+ <tbody>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+coordinate_type <b>get</b>(const T& interval, direction_1d)</font></td>
+ <td><font face="Times New Roman">Expects a model of
+interval. Returns the low or high coordinate of the interval,
+depending on the direction_1d value.</font><font face="Courier New"><br />
</font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T, typename
- coordinate_type><br />
- void <b>set</b>(T& interval, direction_1d, coordinate_type)</font></td>
- <td><font face="Times New Roman">Expects a model of interval.
- Sets the low or high coordinate of the interval to the coordinate,
- depending on the direction_1d value. If low would be greater than
- high after this change then both are set to the input coordinate value.</font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- T <b>construct</b>(coordinate_type low, coordinate_type high)</font></td>
- <td>Construct an object that is a model of interval given low and high
- coordinate values.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- T1& <b>assign</b>(T1& left, const T2& right)</font></td>
- <td>Copies data from right object that models interval into left object
- that models interval.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T, typename
- T2><br />
- bool <b>equivalence</b>(const T& interval1, const T2& interval2)</font></td>
- <td>Given two objects that model interval, compares and returns true if
- their low and high values are respectively equal to each other.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- bool <b>contains</b>(const T&, coordinate_type, <br />
-
- bool consider_touch=true)</font></td>
- <td>Given an object that models interval and a coordinate, returns true
- if the interval contains the coordinate. If the consider_touch
- flag is true will return true if the coordinate is equal to one of the
- interval ends.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- bool <b>contains</b>(const T1& a, const T2& b, <br />
-
- bool consider_touch = true) </font></td>
- <td>Returns true if model of interval a contains both ends of model of
- interval b. If the consider_touch flag is true will consider the
- end of b contained within a even if it is equal to an end of a.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename
- interval_type><br />
- coordinate_type <b>low</b>(const interval_type& interval)</font></td>
- <td>Returns the low end of an object that models interval.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename
- interval_type><br />
- coordinate_type <b>high</b>(const interval_type& interval)</font></td>
- <td>Returns the high end of an object that models interval.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">// get the center coordinate<br />
- template <typename interval_type><br />
- coordinate_type <b>center</b>(const interval_type& interval)</font></td>
- <td>Returns the center coordinate of an object that models interval.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename
- interval_type><br />
- void <b>low</b>(interval_type& interval, coordinate_type )</font></td>
- <td>Sets the low end of the object that models interval to the
- coordinate value. If the low end would be set to larger than high
- end then both are set to the coordinate value.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename
- interval_type><br />
- void <b>high</b>(interval_type& interval, coordinate_type )</font></td>
- <td>Sets the high end of the object that models interval to the
- coordinate value. If the high end would be set to less than low
- end then both are set to the coordinate value.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename
- interval_type><br />
- coordinate_difference <b>delta</b>(const interval_type& interval)</font></td>
- <td>Returns the distance from low to high end of an object that models
- interval.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename
- interval_type><br />
- interval_type& <b>flip</b>(interval_type& interval,<br />
-
- coordinate_type axis = 0)</font></td>
- <td>Flips an object that models interval about the axis coordinate.
- If no axis is provided the interval is flipped across the the origin.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename
- interval_type><br />
- interval_type& <b>scale_up</b>(interval_type& interval, <br />
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename coordinate_type><br />
+void <b>set</b>(T& interval, direction_1d, coordinate_type)</font></td>
+ <td><font face="Times New Roman">Expects a model of
+interval. Sets the low or high coordinate of the interval
+to the coordinate, depending on the direction_1d value. If low
+would be greater than high after this change then both are set to the
+input coordinate value.</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+T <b>construct</b>(coordinate_type low, coordinate_type high)</font></td>
+ <td>Construct an object that is a model of interval given
+low and high coordinate values.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+T1& <b>assign</b>(T1& left, const T2& right)</font></td>
+ <td>Copies data from right object that models interval into
+left object that models interval.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename T2><br />
+bool <b>equivalence</b>(const T& interval1, const T2&
+interval2)</font></td>
+ <td>Given two objects that model interval, compares and
+returns true if their low and high values are respectively equal to
+each other.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+bool <b>contains</b>(const T&, coordinate_type, <br />
+
+bool consider_touch=true)</font></td>
+ <td>Given an object that models interval and a coordinate,
+returns true if the interval contains the coordinate. If the
+consider_touch flag is true will return true if the coordinate is equal
+to one of the interval ends.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+bool <b>contains</b>(const T1& a, const T2& b, <br />
+
+bool consider_touch = true) </font></td>
+ <td>Returns true if model of interval a contains both ends
+of model of interval b. If the consider_touch flag is true will
+consider the end of b contained within a even if it is equal to an end
+of a.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename interval_type><br />
+coordinate_type <b>low</b>(const interval_type& interval)</font></td>
+ <td>Returns the low end of an object that models interval.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename interval_type><br />
+coordinate_type <b>high</b>(const interval_type& interval)</font></td>
+ <td>Returns the high end of an object that models interval.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">// get the center
+coordinate<br />
+template <typename interval_type><br />
+coordinate_type <b>center</b>(const interval_type& interval)</font></td>
+ <td>Returns the center coordinate of an object that models
+interval.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename interval_type><br />
+void <b>low</b>(interval_type& interval, coordinate_type )</font></td>
+ <td>Sets the low end of the object that models interval to
+the coordinate value. If the low end would be set to larger than
+high end then both are set to the coordinate value.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename interval_type><br />
+void <b>high</b>(interval_type& interval, coordinate_type )</font></td>
+ <td>Sets the high end of the object that models interval to
+the coordinate value. If the high end would be set to less than
+low end then both are set to the coordinate value.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename interval_type><br />
+coordinate_difference <b>delta</b>(const interval_type& interval)</font></td>
+ <td>Returns the distance from low to high end of an object
+that models interval.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename interval_type><br />
+interval_type& <b>flip</b>(interval_type& interval,<br />
+
+coordinate_type axis = 0)</font></td>
+ <td>Flips an object that models interval about the axis
+coordinate. If no axis is provided the interval is flipped across
+the the origin.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename interval_type><br />
+interval_type& <b>scale_up</b>(interval_type& interval, <br />
unsigned_area_type factor)</font></td>
- <td>Multiplies low and high ends of an object that models interval by
- unsigned factor.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename
- interval_type><br />
- interval_type& <b>scale_down</b>(interval_type& interval, <br />
+ <td>Multiplies low and high ends of an object that models
+interval by unsigned factor.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename interval_type><br />
+interval_type& <b>scale_down</b>(interval_type& interval, <br />
unsigned_area_type factor)</font></td>
- <td>Divides low and high ends of an object that models interval by
- unsigned factor.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename
- interval_type><br />
- interval_type& <b>scale</b>(interval_type& interval,<br />
-
- double factor) </font></td>
- <td>Multiplies low and high ends of an object that models interval by
- floating point value.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename
- interval_type><br />
- interval_type& <b>move</b>(interval_type& interval,<br />
-
- coordinate_difference displacement)</font></td>
- <td>Adds displacement value to low and high ends of an object that
- models interval.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename
- interval_type><br />
- interval_type& <b>convolve</b>(interval_type& interval,<br />
+ <td>Divides low and high ends of an object that models
+interval by unsigned factor.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename interval_type><br />
+interval_type& <b>scale</b>(interval_type& interval,<br />
+
+double factor) </font></td>
+ <td>Multiplies low and high ends of an object that models
+interval by floating point value.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename interval_type><br />
+interval_type& <b>move</b>(interval_type& interval,<br />
+
+coordinate_difference displacement)</font></td>
+ <td>Adds displacement value to low and high ends of an
+object that models interval.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename interval_type><br />
+interval_type& <b>convolve</b>(interval_type& interval,<br />
coordinate_type b)</font></td>
- <td>Adds coordinate value to low and high ends of an object that models
- interval.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename
- interval_type><br />
- interval_type& <b>deconvolve</b>(interval_type& interval,<br />
+ <td>Adds coordinate value to low and high ends of an object
+that models interval.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename interval_type><br />
+interval_type& <b>deconvolve</b>(interval_type& interval,<br />
coordinate_type b)</font></td>
- <td>Subtracts coordinate value from low and high ends of an object that
- models interval.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- T1& <b>convolve</b>(T1& a, const T2& b)</font></td>
- <td>Adds low end of b to low end of a and adds high end of b to high end
- of a.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- T1& <b>deconvolve</b>(T1& a, const T2& b)</font></td>
- <td>Subtracts low end of b from low end of a and subtracts high end of b
- from high end of a. </td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- T1& <b>reflected_convolve</b>(T1& a, const T2& b)</font></td>
- <td>Adds high end of b to low end of a and adds low end of b to high end
- of a.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- T1& <b>reflected_deconvolve</b>(T1& a, const T2& b)</font></td>
- <td>Subtracts high end of b from low end of a and subtracts low end of b
- from high end of a.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- coordinate_difference <b>euclidean_distance</b>(const T&,<br />
-
- coordinate_type)</font></td>
- <td>Returns the distance from an object that models interval to a
- coordinate. Returns zero if the coordinate is equal to an end of
- the interval or contained within the interval.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- bool <b>intersects</b>(const T1& interval, const T2& b, <br />
-
- bool consider_touch = true)</font></td>
- <td>Returns true if two objects that model interval overlap. If
- the consider_touch flag is true touching at the endpoints is considered
- overlap.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- bool <b>boundaries_intersect</b>(const T1& interval, const T2& b, <br />
+ <td>Subtracts coordinate value from low and high ends of an
+object that models interval.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+T1& <b>convolve</b>(T1& a, const T2& b)</font></td>
+ <td>Adds low end of b to low end of a and adds high end of
+b to high end of a.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+T1& <b>deconvolve</b>(T1& a, const T2& b)</font></td>
+ <td>Subtracts low end of b from low end of a and subtracts
+high end of b from high end of a. </td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+T1& <b>reflected_convolve</b>(T1& a, const T2& b)</font></td>
+ <td>Adds high end of b to low end of a and adds low end of
+b to high end of a.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+T1& <b>reflected_deconvolve</b>(T1& a, const T2& b)</font></td>
+ <td>Subtracts high end of b from low end of a and subtracts
+low end of b from high end of a.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+coordinate_difference <b>euclidean_distance</b>(const T&,<br />
+
+coordinate_type)</font></td>
+ <td>Returns the distance from an object that models
+interval to a coordinate. Returns zero if the coordinate is equal
+to an end of the interval or contained within the interval.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+bool <b>intersects</b>(const T1& interval, const T2& b, <br />
+
+bool consider_touch = true)</font></td>
+ <td>Returns true if two objects that model interval
+overlap. If the consider_touch flag is true touching at the
+endpoints is considered overlap.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+bool <b>boundaries_intersect</b>(const T1& interval, const T2&
+b, <br />
bool consider_touch = true)</font></td>
- <td>Returns true is two objects that model interval partially overlap
- such that one end point of each is contained within the other. If
- the consider_touch flag is true a coordinate is considered contained
- even if it is equal to an end.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- bool <b>abuts</b>(const T1& a, const T2& b,<br />
- direction_1d dir)
- </font></td>
- <td>Returns true if interval b abuts but down not overlap interval a on
- the end of interval a specified by dir.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- bool <b>abuts</b>(const T1& a, const T2& b)</font></td>
- <td>Returns true if interval b abuts but down not overlap interval a.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- bool <b>intersect</b>(T1& a, const T2& b,<br />
-
- bool consider_touch = true) </font></td>
- <td>Sets interval a to the intersection of interval a and interval b and
- return true. If the two intervals do not intersect interval a is
- unchanged and the function returns false. If the flag
- consider_touch is true intervals that abut are considered to intersect.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- T& <b>generalized_intersect</b>(T1& a, const T2& b)</font></td>
- <td>Same as intersect, but if they do not intersect set a to the
- interval between a and b.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- T& <b>bloat</b>(T& interval, coordinate_type)</font></td>
- <td>Adds the coordinate value to high end of interval and subtracts it
- from low end of interval.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- T& <b>bloat</b>(T& interval, direction_1d, coordinate_type)</font></td>
- <td>Adds the coordinate value to high end of interval or subtracts it
- from low end of interval depending on the direction_1d.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- T& <b>shrink</b>(T& interval, coordinate_type)</font></td>
- <td>Subtracts the coordinate value from high end of interval and adds it
- to low end of interval.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- T& <b>shrink</b>(T& interval, direction_1d, coordinate_type)</font></td>
- <td>Subtracts the coordinate value from high end of interval or adds it
- to low end of interval depending on the direction_1d.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- bool <b>encompass</b>(T1& a, const T2& b)</font></td>
- <td>Sets low of a to min of low of a and low of b and sets high of a to
- max of high of a and high of b. Returns true if b was not
- contained within a to begin with.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- bool <b>encompass</b>(T& a, coordinate_type)</font></td>
- <td>Sets low of a to min of low of a and coordinate value and sets high
- of a to max of high of a and coordinate value. Returns true if
- coordinate value was not contained within a to begin with.</td>
- </tr>
-</tbody></table>
- <h1>Interval Data</h1>
-
-<p>
-</p><p>The library provides a model of interval concept declared
-<font face="Courier New">
-template<typename T> interval_data </font>where T is the coordinate type.</p>
-<p>This data type is used internally when an interval is needed and is available
-to the library user who finds it convenient to use a library interval data type
-instead of providing their own. The data type is implemented to be
-convenient to use with the library traits.</p>
-<h2>Members</h2>
-<table id="table2" border="1" width="100%">
- <tbody><tr>
- <td width="586"><b><font face="Courier New">geometry_type</font></b></td>
- <td><font face="Times New Roman">interval_concept</font></td>
- </tr>
- <tr>
- <td width="586"><b><font face="Courier New">coordinate_type</font></b></td>
- <td><font face="Times New Roman">T</font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New"><b>interval_data</b>()</font></td>
- <td><font face="Times New Roman">Default constructs the two coordinate
- values of the interval.</font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New"><b>interval_data</b>(T low, T
- high)</font></td>
- <td><font face="Times New Roman">Constructs an interval with two
- coordinates.</font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New"><b>interval_data</b>(const
- interval_data& that)</font></td>
- <td><font face="Times New Roman">Copy construct</font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">interval_data& <b>operator=</b>(const
- interval_data& that)</font></td>
- <td>Assignment operator.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename IntervalType><b>
- <br /> </b>interval_data& <b>operator=</b>(</font><font face="Courier New">const IntervalType</font><font face="Courier New">& that) const</font></td>
- <td>Assign from an object that is a model of interval.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New"><b />bool<b>
- operator==</b>(const </font><font face="Courier New">interval_data</font><font face="Courier New">& that) const</font></td>
- <td>Equality operator overload.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">bool<b>
- operator!=</b>(const </font><font face="Courier New">interval_data</font><font face="Courier New">& that) const</font></td>
- <td>Inequality operator overload.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">bool<b>
- operator<</b>(const </font><font face="Courier New">interval_data</font><font face="Courier New">& that) const</font></td>
- <td>Compares low coordinates then high coordinates to break ties.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">bool<b>
- operator<=</b>(const </font><font face="Courier New">interval_data</font><font face="Courier New">& that) const</font></td>
- <td>Compares low coordinates then high coordinates to break ties.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">bool<b>
- operator></b>(const </font><font face="Courier New">interval_data</font><font face="Courier New">& that) const</font></td>
- <td>Compares low coordinates then high coordinates to break ties.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">bool<b>
- operator>=</b>(const </font><font face="Courier New">interval_data</font><font face="Courier New">& that) const</font></td>
- <td>Compares low coordinates then high coordinates to break ties.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">T <b>get</b>(direction_1d dir)
- const</font></td>
- <td>Get the coordinate in the given direction.</td>
- </tr>
- <tr>
- <td style="vertical-align: top;"><font face="Courier New">T <span style="font-weight: bold;">low</span>() const</font></td>
+ <td>Returns true is two objects that model interval
+partially overlap such that one end point of each is contained within
+the other. If the consider_touch flag is true a coordinate is
+considered contained even if it is equal to an end.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+bool <b>abuts</b>(const T1& a, const T2& b,<br />
+
+direction_1d dir) </font></td>
+ <td>Returns true if interval b abuts but down not overlap
+interval a on the end of interval a specified by dir.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+bool <b>abuts</b>(const T1& a, const T2& b)</font></td>
+ <td>Returns true if interval b abuts but down not overlap
+interval a.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+bool <b>intersect</b>(T1& a, const T2& b,<br />
+
+bool consider_touch = true) </font></td>
+ <td>Sets interval a to the intersection of interval a and
+interval b and return true. If the two intervals do not intersect
+interval a is unchanged and the function returns false. If the
+flag consider_touch is true intervals that abut are considered to
+intersect.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+T& <b>generalized_intersect</b>(T1& a, const T2& b)</font></td>
+ <td>Same as intersect, but if they do not intersect set a
+to the interval between a and b.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+T& <b>bloat</b>(T& interval, coordinate_type)</font></td>
+ <td>Adds the coordinate value to high end of interval and
+subtracts it from low end of interval.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+T& <b>bloat</b>(T& interval, direction_1d, coordinate_type)</font></td>
+ <td>Adds the coordinate value to high end of interval or
+subtracts it from low end of interval depending on the direction_1d.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+T& <b>shrink</b>(T& interval, coordinate_type)</font></td>
+ <td>Subtracts the coordinate value from high end of
+interval and adds it to low end of interval.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+T& <b>shrink</b>(T& interval, direction_1d, coordinate_type)</font></td>
+ <td>Subtracts the coordinate value from high end of
+interval or adds it to low end of interval depending on the
+direction_1d.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+bool <b>encompass</b>(T1& a, const T2& b)</font></td>
+ <td>Sets low of a to min of low of a and low of b and sets
+high of a to max of high of a and high of b. Returns true if b
+was not contained within a to begin with.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+bool <b>encompass</b>(T& a, coordinate_type)</font></td>
+ <td>Sets low of a to min of low of a and coordinate value
+and sets high of a to max of high of a and coordinate value.
+Returns true if coordinate value was not contained within a to begin
+with.</td>
+ </tr>
+ </tbody>
+ </table>
+ <h1>Interval Data</h1>
+ <p> </p>
+ <p>The library provides a model of interval concept declared
+ <font face="Courier New">template<typename T> interval_data
+ </font>where T is the coordinate type.</p>
+ <p>This data type is used internally when an interval is needed
+and is available to the library user who finds it convenient to use a
+library interval data type instead of providing their own. The
+data type is implemented to be convenient to use with the library
+traits.</p>
+ <h2>Members</h2>
+ <table id="table2" border="1" width="100%">
+ <tbody>
+ <tr>
+ <td width="586"><b><font face="Courier New">geometry_type</font></b></td>
+ <td><font face="Times New Roman">interval_concept</font></td>
+ </tr>
+ <tr>
+ <td width="586"><b><font face="Courier New">coordinate_type</font></b></td>
+ <td><font face="Times New Roman">T</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New"><b>interval_data</b>()</font></td>
+ <td><font face="Times New Roman">Default constructs the two
+coordinate values of the interval.</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New"><b>interval_data</b>(T
+low, T high)</font></td>
+ <td><font face="Times New Roman">Constructs an interval
+with two coordinates.</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New"><b>interval_data</b>(const
+interval_data& that)</font></td>
+ <td><font face="Times New Roman">Copy construct</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">interval_data&
+ <b>operator=</b>(const interval_data& that)</font></td>
+ <td>Assignment operator.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename IntervalType><b> <br />
+ </b>interval_data& <b>operator=</b>(</font><font
+ face="Courier New">const IntervalType</font><font face="Courier New">&
+that) const</font></td>
+ <td>Assign from an object that is a model of interval.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New"><b>bool<b>
+operator==</b>(const </b></font><b><font face="Courier New">interval_data</font><font
+ face="Courier New">& that) const</font></b></td>
+ <td>Equality operator overload.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">bool<b> operator!=</b>(const
+ </font><font face="Courier New">interval_data</font><font
+ face="Courier New">& that) const</font></td>
+ <td>Inequality operator overload.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">bool<b>
+operator<</b>(const </font><font face="Courier New">interval_data</font><font
+ face="Courier New">& that) const</font></td>
+ <td>Compares low coordinates then high coordinates to break
+ties.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">bool<b>
+operator<=</b>(const </font><font face="Courier New">interval_data</font><font
+ face="Courier New">& that) const</font></td>
+ <td>Compares low coordinates then high coordinates to break
+ties.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">bool<b>
+operator></b>(const </font><font face="Courier New">interval_data</font><font
+ face="Courier New">& that) const</font></td>
+ <td>Compares low coordinates then high coordinates to break
+ties.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">bool<b>
+operator>=</b>(const </font><font face="Courier New">interval_data</font><font
+ face="Courier New">& that) const</font></td>
+ <td>Compares low coordinates then high coordinates to break
+ties.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">T <b>get</b>(direction_1d
+dir) const</font></td>
+ <td>Get the coordinate in the given direction.</td>
+ </tr>
+ <tr>
+ <td style="vertical-align: top;"><font face="Courier New">T
+ <span style="font-weight: bold;">low</span>() const</font></td>
<td style="vertical-align: top;">Retrieves the low value.</td>
</tr>
<tr>
- <td style="vertical-align: top;"><font face="Courier New">T <span style="font-weight: bold;">high</span>() const</font></td>
- <td style="vertical-align: top;">Retrieves the high endpoint.</td>
+ <td style="vertical-align: top;"><font face="Courier New">T
+ <span style="font-weight: bold;">high</span>() const</font></td>
+ <td style="vertical-align: top;">Retrieves the high
+endpoint.</td>
</tr>
-<tr>
- <td width="586"><font face="Courier New">void <b>set</b>(direction_1d
- dir, T value)</font></td>
- <td>Sets the coordinate in the given direction to the value.</td>
- </tr><tr>
- <td style="vertical-align: top;"><font face="Courier New">interval_data& <span style="font-weight: bold;">low</span>(T value)</font></td>
+ <tr>
+ <td width="586"><font face="Courier New">void <b>set</b>(direction_1d
+dir, T value)</font></td>
+ <td>Sets the coordinate in the given direction to the value.</td>
+ </tr>
+ <tr>
+ <td style="vertical-align: top;"><font face="Courier New">interval_data&
+ <span style="font-weight: bold;">low</span>(T value)</font></td>
<td style="vertical-align: top;">Sets the low value.</td>
</tr>
<tr>
- <td style="vertical-align: top;"><font face="Courier New">interval_data& <span style="font-weight: bold;">high</span>(T value)</font></td>
+ <td style="vertical-align: top;"><font face="Courier New">interval_data&
+ <span style="font-weight: bold;">high</span>(T value)</font></td>
<td style="vertical-align: top;">Sets the high value.</td>
</tr>
-
- </tbody></table>
- </td></tr><tr>
-<td style="background-color: rgb(238, 238, 238);" nowrap="1" valign="top">
- </td>
-<td style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;" valign="top" width="100%">
-
-
-<table class="docinfo" id="table3" frame="void" rules="none">
- <colgroup>
- <col class="docinfo-name" /><col class="docinfo-content" />
- </colgroup>
- <tbody valign="top">
- <tr>
- <th class="docinfo-name">Copyright:</th>
- <td>Copyright © Intel Corporation 2008-2010.</td>
- </tr>
- <tr class="field">
- <th class="docinfo-name">License:</th>
- <td class="field-body">Distributed under the Boost Software License,
- Version 1.0. (See accompanying file <tt class="literal">
- <span class="pre">LICENSE_1_0.txt</span></tt> or copy at
- <a class="reference" target="_top" href="http://www.boost.org/LICENSE_1_0.txt">
- http://www.boost.org/LICENSE_1_0.txt>)</td>
- </tr>
-</tbody></table>
-
-</td></tr></tbody></table></body></html>
\ No newline at end of file
+ </tbody>
+ </table>
+ </td>
+ </tr>
+ <tr>
+ <td style="background-color: rgb(238, 238, 238);" nowrap="1"
+ valign="top"> </td>
+ <td
+ style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;"
+ valign="top" width="100%">
+ <table class="docinfo" id="table3" frame="void" rules="none">
+ <colgroup> <col class="docinfo-name" /><col
+ class="docinfo-content" /> </colgroup> <tbody valign="top">
+ <tr>
+ <th class="docinfo-name">Copyright:</th>
+ <td>Copyright © Intel Corporation 2008-2010.</td>
+ </tr>
+ <tr class="field">
+ <th class="docinfo-name">License:</th>
+ <td class="field-body">Distributed under the Boost Software
+License, Version 1.0. (See accompanying file <tt class="literal"> <span
+ class="pre">LICENSE_1_0.txt</span></tt> or copy at <a
+ class="reference" target="_top"
+ href="http://www.boost.org/LICENSE_1_0.txt">
+http://www.boost.org/LICENSE_1_0.txt>)</td>
+ </tr>
+ </tbody>
+ </table>
+ </td>
+ </tr>
+ </tbody>
+</table>
+</body>
+</html>
Modified: branches/release/libs/polygon/doc/gtl_isotropy.htm
==============================================================================
--- branches/release/libs/polygon/doc/gtl_isotropy.htm (original)
+++ branches/release/libs/polygon/doc/gtl_isotropy.htm 2013-04-15 18:27:46 EDT (Mon, 15 Apr 2013)
@@ -1,152 +1,174 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:(null)1="http://www.w3.org/TR/REC-html40" lang="en"><head>
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"
+ xmlns:v="urn:schemas-microsoft-com:vml"
+ xmlns:o="urn:schemas-microsoft-com:office:office"
+ xmlns:(null)1="http://www.w3.org/TR/REC-html40" lang="en">
+<head>
<!--
Copyright 2009-2010 Intel Corporation
license banner
---><title>Boost Polygon Library: Isotropy</title>
-
-
-
- <meta http-equiv="content-type" content="text/html;charset=ISO-8859-1" /><!-- <link type="text/css" rel="stylesheet" href="adobe_source.css"> --></head><body><table style="margin: 0pt; padding: 0pt; width: 100%;" border="0" cellpadding="0" cellspacing="0"><tbody><tr>
-<td style="background-color: rgb(238, 238, 238);" nowrap="1" valign="top">
- <div style="padding: 5px;" align="center">
- <img src="images/boost.png" border="0" height="86" width="277" /><a title="www.boost.org home page" href="http://www.boost.org/" tabindex="2" style="border: medium none ;">
- </a>
- </div>
- <div style="margin: 5px;">
- <h3 class="navbar">Contents</h3>
- <ul>
- <li>Boost.Polygon Main Page</li>
- <li>Design Overview</li>
- <li>Isotropy</li>
- <li>Coordinate Concept</li>
- <li>Interval Concept</li>
- <li>Point Concept</li>
+-->
+ <title>Boost Polygon Library: Isotropy</title>
+ <meta http-equiv="content-type" content="text/html;charset=ISO-8859-1" />
+<!-- <link type="text/css" rel="stylesheet" href="adobe_source.css"> -->
+</head>
+<body>
+<table style="margin: 0pt; padding: 0pt; width: 100%;" border="0"
+ cellpadding="0" cellspacing="0">
+ <tbody>
+ <tr>
+ <td style="background-color: rgb(238, 238, 238);" nowrap="1"
+ valign="top">
+ <div style="padding: 5px;" align="center"> <img
+ src="images/boost.png" border="0" height="86" width="277" /><a
+ title="www.boost.org home page" href="http://www.boost.org/"
+ tabindex="2" style="border: medium none ;"> </a> </div>
+ <div style="margin: 5px;">
+ <h3 class="navbar">Contents</h3>
+ <ul>
+ <li>Boost.Polygon Main Page</li>
+ <li>Design Overview</li>
+ <li>Isotropy</li>
+ <li>Coordinate Concept</li>
+ <li>Interval Concept</li>
+ <li>Point Concept</li>
<li>Segment Concept</li>
-
- <li>Rectangle Concept</li>
- <li>Polygon 90 Concept</li>
- <li>Polygon 90 With Holes Concept</li>
- <li>Polygon 45 Concept</li>
- <li>Polygon 45 With Holes Concept</li>
- <li>Polygon Concept</li>
- <li>Polygon With Holes Concept</li>
- <li>Polygon 90 Set Concept</li>
- <li>Polygon 45 Set Concept</li>
- <li>Polygon Set Concept</li>
- <li>Connectivity Extraction 90</li>
- <li>Connectivity Extraction 45</li>
- <li>Connectivity Extraction</li>
- <li>Property Merge 90</li>
- <li>Property Merge 45</li>
- <li>Property Merge</li>
+ <li>Rectangle Concept</li>
+ <li>Polygon 90 Concept</li>
+ <li><a href="gtl_polygon_90_with_holes_concept.htm">Polygon 90
+With Holes Concept</a></li>
+ <li>Polygon 45 Concept</li>
+ <li><a href="gtl_polygon_45_with_holes_concept.htm">Polygon 45
+With Holes Concept</a></li>
+ <li>Polygon Concept</li>
+ <li><a href="gtl_polygon_with_holes_concept.htm">Polygon With
+Holes Concept</a></li>
+ <li><a href="gtl_polygon_90_set_concept.htm">Polygon 90 Set
+Concept</a></li>
+ <li><a href="gtl_polygon_45_set_concept.htm">Polygon 45 Set
+Concept</a></li>
+ <li>Polygon Set Concept</li>
+ <li><a href="gtl_connectivity_extraction_90.htm">Connectivity
+Extraction 90</a></li>
+ <li><a href="gtl_connectivity_extraction_45.htm">Connectivity
+Extraction 45</a></li>
+ <li><a href="gtl_connectivity_extraction.htm">Connectivity
+Extraction</a></li>
+ <li>Property Merge 90</li>
+ <li>Property Merge 45</li>
+ <li>Property Merge</li>
<li><a href="voronoi_main.htm">Voronoi Main Page<br />
-</a></li>
+ </a></li>
<li>Voronoi Benchmark<br />
</li>
<li>Voronoi Builder</li>
- <li><a href="voronoi_diagram.htm">Voronoi Diagram<br />
-</a></li>
- <li>Voronoi Predicates</li>
- <li>Voronoi Robust FPT<br />
- </li>
-
-
- </ul>
- <h3 class="navbar">Other Resources</h3>
- <ul>
- <li>GTL Boostcon 2009 Paper</li>
- <li><a href="GTL_boostcon_draft03.pdf">GTL Boostcon 2009
- Presentation</a></li>
- <li>Performance Analysis</li>
- <li>Layout Versus Schematic Tutorial</li>
- <li>Minkowski Sum Tutorial</li>
+ <li>Voronoi Diagram</li>
+ </ul>
+ <h3 class="navbar">Other Resources</h3>
+ <ul>
+ <li>GTL Boostcon 2009 Paper</li>
+ <li><a href="GTL_boostcon_draft03.pdf">GTL Boostcon 2009
+Presentation</a></li>
+ <li>Performance Analysis</li>
+ <li>Layout Versus Schematic Tutorial</li>
+ <li>Minkowski Sum Tutorial</li>
<li>Voronoi Basic Tutorial</li>
- <li>Voronoi Advanced Tutorial</li>
-</ul>
- </div>
- <h3 class="navbar">Polygon Sponsor</h3>
- <div style="padding: 5px;" align="center">
- <img src="images/intlogo.gif" border="0" height="51" width="127" /><a title="www.adobe.com home page" href="http://www.adobe.com/" tabindex="2" style="border: medium none ;">
- </a>
- </div>
-</td>
-<td style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;" valign="top" width="100%">
-
-<!-- End Header -->
-
-<br />
-<p>
-</p><h1>Isotropy</h1>
-
-<p>
-</p><p align="left">What is isotropy?</p>
-<p:colorscheme colors="#ffffff,#000000,#808080,#000000,#bbe0e3,#333399,#009999,#99cc00">
-</p:colorscheme><div class="O" style="text-align: center;" v:shape="_x0000_s1026">
- <p style="text-align: left;">
- <span style="">Isotropy - Function: <i>adjective</i> Etymology: International
- Scientific Vocabulary<br />
- <b>:</b> exhibiting properties (as velocity of light transmission) with the
- same values when measured along axes in all directions <an <i>isotropic</i>
- crystal></span></p></div>
-<p align="left">In computational geometry things are often symmetric and
-invariant to direction and orientation. This invariance to direction is
-called isotropy. In such situations it is convenient to parameterize
-direction or orientation and write code that is invariant to the direction or
-orientation in which it is applied. To do this effectively we provide an
-internally consistent set of isotropic data types to represent program
-data that describes orientations and directions. These data types are:</p>
- <ul>
- <li>direction_1d - has one of the following 2 states: LOW, HIGH </li>
- <li>orientation_2d - has one of the following 2 states: HORIZONTAL,
- VERTICAL</li>
- <li>direction_2d - has one of the following 4 states: WEST, EAST, SOUTH,
- NORTH</li>
- <li>orientation_3d - has one of the following 3 states: HORIZONTAL,
- VERTICAL, PROXIMAL</li>
- <li>direction_3d - has one of the following 6 states: WEST, EAST, SOUTH,
- NORTH, DOWN, UP</li>
- </ul>
-
-<p align="left">The isotropic types create a system and interact with each other
-in various ways, such as casting. Together they create a language for
-describing isotropic situations programmatically. For instance, to get the
-positive direction_2d from an orientation_2d you would call a member function of
+ <li><a href="voronoi_advanced_tutorial.htm">Voronoi Advanced
+Tutorial</a></li>
+ </ul>
+ </div>
+ <h3 class="navbar">Polygon Sponsor</h3>
+ <div style="padding: 5px;" align="center"> <img
+ src="images/intlogo.gif" border="0" height="51" width="127" /><a
+ title="www.adobe.com home page" href="http://www.adobe.com/"
+ tabindex="2" style="border: medium none ;"> </a> </div>
+ </td>
+ <td
+ style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;"
+ valign="top" width="100%">
+<!-- End Header --><br />
+ <p>
+ </p>
+ <h1>Isotropy</h1>
+ <p> </p>
+ <p align="left">What is isotropy?</p>
+ <p:colorscheme
+ colors="#ffffff,#000000,#808080,#000000,#bbe0e3,#333399,#009999,#99cc00">
+ </p:colorscheme>
+ <div class="O" style="text-align: center;" v:shape="_x0000_s1026">
+ <p style="text-align: left;"> <span style="">Isotropy -
+Function: <i>adjective</i> Etymology: International Scientific
+Vocabulary<br />
+ <b>:</b> exhibiting properties (as velocity of light
+transmission) with the same values when measured along axes in all
+directions <an <i>isotropic</i> crystal></span></p>
+ </div>
+ <p align="left">In computational geometry things are often
+symmetric and invariant to direction and orientation. This
+invariance to direction is called isotropy. In such situations it
+is convenient to parameterize direction or orientation and write code
+that is invariant to the direction or orientation in which it is
+applied. To do this effectively we provide an internally
+consistent set of isotropic data types to represent program data that
+describes orientations and directions. These data types are:</p>
+ <ul>
+ <li>direction_1d - has one of the following 2 states: LOW, HIGH
+ </li>
+ <li>orientation_2d - has one of the following 2 states:
+HORIZONTAL, VERTICAL</li>
+ <li>direction_2d - has one of the following 4 states: WEST,
+EAST, SOUTH, NORTH</li>
+ <li>orientation_3d - has one of the following 3 states:
+HORIZONTAL, VERTICAL, PROXIMAL</li>
+ <li>direction_3d - has one of the following 6 states: WEST,
+EAST, SOUTH, NORTH, DOWN, UP</li>
+ </ul>
+ <p align="left">The isotropic types create a system and interact
+with each other in various ways, such as casting. Together they
+create a language for describing isotropic situations
+programmatically. For instance, to get the positive direction_2d
+from an orientation_2d you would call a member function of
orientation_2d and pass a direction_1d:</p>
-<p align="left"><font face="Courier New">orientation_2d orient = HORIZONTAL;<br />
+ <p align="left"><font face="Courier New">orientation_2d orient =
+HORIZONTAL;<br />
direction_2d dir = orient.get_direction(direction_1d(HIGH));<br />
assert(dir == EAST);</font></p>
-<p align="left">The motivation for providing isotropic data types is to
-encourage programming at a higher level of abstraction where program behavior is
-controlled by program data passed into function calls rather than flow control
-syntax. Isotropic programming style is particularly applicable to working
-with points, intervals and rectangles. Often times the implementation of
-such logic is identical when implemented for the x or y coordinates, except that
-the names of functions and data members are changed in a mechanical way leading
-to code duplication and bloat that results in copy-paste programming errors and
-maintenance problems where changes made to a given code block relating to x
-coordiantes are not duplicated to the code block that refers to y.
-Isotropy therefore represents an opportunity to refactor and improve the quality
-of low level geometry code especially in regard to inter-relating coordinates,
-points, intervals and rectangles.</p>
-<h2>direction_1d</h2>
-
-<p>
-</p><p align="left">The direction_1d data type has two possible states. These
-are the positive and negative directions on a continuum such as the number line.
-These states can be described by one of several direction_1d_enum values:
-We make clockwise and counterclockwise winding orientation of polygons a
-direction 1d value instead of providing a separate winding_orientation data
-type. This is because winding orientation can be thought of as positive
-and negative directions in a 1d (although cyclic) space. We assign
-counterclockwise to be the positive direction of travel in the 1d cyclic space
-to conform with the mathematical convention frequently described as the "right
-hand rule" which assigns positive normal value to counterclockwise and negative
-normal value to clockwise as well as the common convention that counterclockwise
-polygon winding corresponds to positive polygonal regions where as clockwise
-polygon winding corresponds to hole (negative) polygonal regions.</p>
-<p align="left"><font face="Courier New">enum direction_1d_enum {LOW = 0, HIGH =
-1,<br />
+ <p align="left">The motivation for providing isotropic data types
+is to encourage programming at a higher level of abstraction where
+program behavior is controlled by program data passed into function
+calls rather than flow control syntax. Isotropic programming
+style is particularly applicable to working with points, intervals and
+rectangles. Often times the implementation of such logic is
+identical when implemented for the x or y coordinates, except that the
+names of functions and data members are changed in a mechanical way
+leading to code duplication and bloat that results in copy-paste
+programming errors and maintenance problems where changes made to a
+given code block relating to x coordiantes are not duplicated to the
+code block that refers to y. Isotropy therefore represents an
+opportunity to refactor and improve the quality of low level geometry
+code especially in regard to inter-relating coordinates, points,
+intervals and rectangles.</p>
+ <h2>direction_1d</h2>
+ <p> </p>
+ <p align="left">The direction_1d data type has two possible
+states. These are the positive and negative directions on a
+continuum such as the number line. These states can be
+described by one of several direction_1d_enum values: We make
+clockwise and counterclockwise winding orientation of polygons a
+direction 1d value instead of providing a separate winding_orientation
+data type. This is because winding orientation can be thought of
+as positive and negative directions in a 1d (although cyclic)
+space. We assign counterclockwise to be the positive direction of
+travel in the 1d cyclic space to conform with the mathematical
+convention frequently described as the "right hand rule" which assigns
+positive normal value to counterclockwise and negative normal value to
+clockwise as well as the common convention that counterclockwise
+polygon winding corresponds to positive polygonal regions where as
+clockwise polygon winding corresponds to hole (negative) polygonal
+regions.</p>
+ <p align="left"><font face="Courier New">enum direction_1d_enum
+{LOW = 0, HIGH = 1,<br />
+
LEFT = 0, RIGHT = 1,<br />
CLOCKWISE = 0, COUNTERCLOCKWISE = 1,<br />
@@ -154,383 +176,390 @@
REVERSE = 0, FORWARD = 1,<br />
NEGATIVE = 0, POSITIVE = 1 };</font></p>
-<h2>Member Functions</h2>
-<table id="table1" border="1" width="100%">
- <tbody><tr>
- <td width="586"><font face="Courier New"><b>direction_1d</b>(direction_1d_enum
- val = LOW)</font></td>
- <td>Constructor defaults to LOW. </td>
- </tr>
- <tr>
- <td width="586"><b><font face="Courier New">direction_1d</font></b><font face="Courier New">(const
- direction_1d& that)</font></td>
- <td>Copy construct.</td>
- </tr>
- <tr>
- <td width="586"><b><font face="Courier New">direction_1d</font></b><font face="Courier New">(const
- direction_2d& that)</font></td>
- <td>Down cast direction_2d, extracting out whether positive or negative</td>
- </tr>
- <tr>
- <td width="586"><b><font face="Courier New">direction_1d</font></b><font face="Courier New">(const
- direction_3d& that)</font></td>
- <td>Down cast direction_3d, extracting out whether positive or negative</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">direction_1d& <b>operator=</b>(const direction_1d dir)</font></td>
- <td>Assignment</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">direction_1d& <b>operator==</b>(const direction_1d dir)
-const</font></td>
- <td>Equivalence</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">direction_1d& <b>operator!=</b>(const direction_1d dir)
-const</font></td>
- <td>Inequivalence</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">unsigned int <b>to_int</b>() const</font></td>
- <td>Convert to the integer enum value of current state to use as index.
- Auto-cast to int is disallowed for type safety reasons.</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">direction_1d& <b>backward</b>()</font></td>
- <td>Inverts direction.</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">int <b>get_sign</b>() const</font></td>
- <td>Returns positive 1 if positive direction and negative one if
- negative direction.</td>
- </tr>
- </tbody></table>
-<h2>orientation_2d</h2>
-
-<p>
-</p><p align="left">The orientation_2d data type has two possible states.
-These are the horizontal and vertical axis of a 2d Cartesian coordinate system.
-These states can be described by one of the two orientation_2d_enum values:</p>
-<p align="left"><font face="Courier New">enum orientation_2d_enum { HORIZONTAL =
-0, VERTICAL = 1 };</font></p>
-<h2>Member Functions</h2>
-<table id="table2" border="1" width="100%">
- <tbody><tr>
- <td width="586"><b><font face="Courier New">orientation_2</font></b><font face="Courier New"><b>d</b>(orientation_2d_enum
- val = HORIZONTAL)</font></td>
- <td>Constructor defaults to HORIZONTAL. </td>
- </tr>
- <tr>
- <td width="586"><b><font face="Courier New">orientation_2</font></b><font face="Courier New"><b>d</b>(const
- orientation_2d& that)</font></td>
- <td>Copy construct.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">explicit </font><b>
- <font face="Courier New">orientation_2</font></b><font face="Courier New"><b>d</b>(const
- direction_2d& that)</font></td>
- <td>Down cast direction_2d, extracting out whether horizontal or
- vertical direction type</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">orientation_2d& <b>operator=</b>(const orientation_2d
-o)</font></td>
- <td>Assignment</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">orientation_2d& <b>operator==</b>(const orientation_2d
-o) const</font></td>
- <td>Equivalence</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">orientation_2d& <b>operator!=</b>(const orientation_2d
-o) const</font></td>
- <td>Inequivalence</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">unsigned int <b>to_int</b>() const</font></td>
- <td>Convert to the integer enum value of current state to use as index.
- Auto-cast to int is disallowed for type safety reasons</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">orientation_2d& <b>turn_90</b>()</font></td>
- <td>Change to orthogonal orientation</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">int <b>get_perpendicular</b>() const</font></td>
- <td>Returns orthogonal orientation</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">int <b>get_direction</b>(direction_1d dir) const</font></td>
- <td>Returns the positive or negative direction_2d depending on the value
- of dir</td>
- </tr>
- </tbody></table>
-<h2>direction_2d</h2>
-
-<p>
-</p><p align="left">The direction_2d data type has four possible states. These
-are the cardinal directions of the 2D Cartesian coordinate system.
-These states can be described by one of several direction_2d_enum values:</p>
-<p align="left"><font face="Courier New">enum direction_2d_enum { WEST = 0, EAST
-= 1, SOUTH = 2, NORTH = 3 };</font></p>
-<h2>Member Functions</h2>
-<table id="table3" border="1" width="100%">
- <tbody><tr>
- <td width="586"><font face="Courier New"><b>direction_2d</b>(direction_2d_enum
- val = WEST)</font></td>
- <td>Constructor defaults to WEST. </td>
- </tr>
- <tr>
- <td width="586"><b><font face="Courier New">direction_2d</font></b><font face="Courier New">(const
- direction_2d& that)</font></td>
- <td>Copy construct.</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">direction_1d& <b>operator=</b>(const direction_2d dir)</font></td>
- <td>Assignment</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">direction_1d& <b>operator==</b>(const direction_2d dir)
-const</font></td>
- <td>Equivalence</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">direction_1d& <b>operator!=</b>(const direction_2d dir)
-const</font></td>
- <td>Inequivalence</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">unsigned int <b>to_int</b>() const</font></td>
- <td>Convert to the integer enum value of current state to use as index.
- Auto-cast to int is disallowed for type safety reasons.</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">direction_2d& <b>backward</b>()</font></td>
- <td>Inverts direction.</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">direction_2d& <b>turn</b>(direction_1d dir)</font></td>
- <td>Changes to direction_2d to the left if dir is LOW, to the right if
- dir is HIGH</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">direction_2d& <b>left</b>()</font></td>
- <td>Changes to the direction_2d to the left</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">direction_2d& <b>right</b>()</font></td>
- <td>Changes to the direction_2d to the right</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">int <b>is_positive</b>() const</font></td>
- <td>Returns true if EAST or NORTH</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">int <b>is_negative</b>() const</font></td>
- <td>Returns true if WEST or SOUTH</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">int <b>get_sign</b>() const</font></td>
- <td>Returns positive 1 if positive direction and negative one if
- negative direction.</td>
- </tr>
- </tbody></table>
-<h2>orientation_3d</h2>
-
-<p>
-</p><p align="left">The orientation_3d data type has three possible states.
-These are the horizontal, vertical and proximal (x, y, z) axis of a 3d Cartesian
-coordinate system. These states can be described by one of the
-orientation_2d_enum values or by the orientation_3d_enum value:</p>
-<p align="left"><font face="Courier New">enum orientation_3d_enum { PROXIMAL = 2
-};</font></p>
-<h2>Member Functions</h2>
-<table id="table6" border="1" width="100%">
- <tbody><tr>
- <td width="586"><b><font face="Courier New">orientation_3</font></b><font face="Courier New"><b>d</b>(orientation_2d_enum
- val = HORIZONTAL)</font></td>
- <td>Constructor defaults to HORIZONTAL. </td>
- </tr>
- <tr>
- <td width="586"><b><font face="Courier New">orientation_3</font></b><font face="Courier New"><b>d</b>(const
- orientation_3d& that)</font></td>
- <td>Copy construct.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">explicit </font><b>
- <font face="Courier New">orientation_3</font></b><font face="Courier New"><b>d</b>(const
- direction_2d& that)</font></td>
- <td>Extract out the orientation of the direction</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">explicit </font><b>
- <font face="Courier New">orientation_3</font></b><font face="Courier New"><b>d</b>(const
- direction_3d& that)</font></td>
- <td>Extract out the orientation of the direction</td>
- </tr>
- <tr>
- <td width="586"><b><font face="Courier New">orientation_3</font></b><font face="Courier New"><b>d</b>(const
- orientation_2d& that)</font></td>
- <td>Up cast orientation_2d to orientation_3d.</td>
- </tr>
- <tr>
- <td width="586"><b><font face="Courier New">orientation_3</font></b><font face="Courier New"><b>d</b>(const
- orientation_3d_enum& that)</font></td>
- <td>Construct from constant value</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">orientation_3d& <b>operator=</b>(const orientation_3d
-o)</font></td>
- <td>Assignment</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">orientation_3d& <b>operator==</b>(const orientation_3d
-o) const</font></td>
- <td>Equivalence</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">orientation_3d& <b>operator!=</b>(const orientation_3d
-o) const</font></td>
- <td>Inequivalence</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">unsigned int <b>to_int</b>() const</font></td>
- <td>Convert to the integer enum value of current state to use as index.
- Auto-cast to int is disallowed for type safety reasons</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">int <b>get_direction</b>(direction_1d dir) const</font></td>
- <td>Returns the positive or negative direction_2d depending on the value
- of dir</td>
- </tr>
- </tbody></table>
-<h2>direction_3d</h2>
-
-<p>
-</p><p align="left">The direction_3d data type has six possible states. These
-are the cardinal directions of the 3D Cartesian coordinate system.
-These states can be described by one of the direction_2d_enum values or the
-direction_3d_enum values:</p>
-<p align="left"><font face="Courier New">enum direction_3d_enum { DOWN = 4, UP =
-5 };</font></p>
-<h2>Member Functions</h2>
-<table id="table5" border="1" width="100%">
- <tbody><tr>
- <td width="586"><font face="Courier New"><b>direction_3d</b>(direction_2d_enum
- val = WEST)</font></td>
- <td>Constructor defaults to LOW. </td>
- </tr>
- <tr>
- <td width="586"><b><font face="Courier New">direction_3d</font></b><font face="Courier New">(direction_3d_enum that)</font></td>
- <td>Construct from constant value</td>
- </tr>
- <tr>
- <td width="586"><b><font face="Courier New">direction_3d</font></b><font face="Courier New">(const
- direction_3d& that)</font></td>
- <td>Copy construct</td>
- </tr>
- <tr>
- <td width="586"><b><font face="Courier New">direction_3d</font></b><font face="Courier New">(direction_2d that)</font></td>
- <td>Up cast direction_2d to direction_3d</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">direction_3d& <b>operator=</b>(const direction_3d dir)</font></td>
- <td>Assignment</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">direction_3d& <b>operator==</b>(const direction_3d dir)
-const</font></td>
- <td>Equivalence</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">direction_2d& <b>operator!=</b>(const direction_3d dir)
-const</font></td>
- <td>Inequivalence</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">unsigned int <b>to_int</b>() const</font></td>
- <td>Convert to the integer enum value of current state to use as index.
- Auto-cast to int is disallowed for type safety reasons.</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">direction_1d& <b>backward</b>()</font></td>
- <td>Inverts direction.</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">int <b>is_positive</b>() const</font></td>
- <td>Returns true if direction is EAST, NORTH or UP.</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">int <b>is_negative</b>() const</font></td>
- <td>Returns true if direction is WEST, SOUTH or DOWN</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">int <b>get_sign</b>() const</font></td>
- <td>Returns positive 1 if positive direction and negative one if
- negative direction.</td>
- </tr>
- </tbody></table>
- </td></tr><tr>
-<td style="background-color: rgb(238, 238, 238);" nowrap="1" valign="top">
- </td>
-<td style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;" valign="top" width="100%">
-
-
-<table class="docinfo" id="table7" frame="void" rules="none">
- <colgroup>
- <col class="docinfo-name" /><col class="docinfo-content" />
- </colgroup>
- <tbody valign="top">
- <tr>
- <th class="docinfo-name">Copyright:</th>
- <td>Copyright © Intel Corporation 2008-2010.</td>
- </tr>
- <tr class="field">
- <th class="docinfo-name">License:</th>
- <td class="field-body">Distributed under the Boost Software License,
- Version 1.0. (See accompanying file <tt class="literal">
- <span class="pre">LICENSE_1_0.txt</span></tt> or copy at
- <a class="reference" target="_top" href="http://www.boost.org/LICENSE_1_0.txt">
- http://www.boost.org/LICENSE_1_0.txt>)</td>
- </tr>
-</tbody></table>
-
-</td></tr></tbody></table></body></html>
\ No newline at end of file
+ <h2>Member Functions</h2>
+ <table id="table1" border="1" width="100%">
+ <tbody>
+ <tr>
+ <td width="586"><font face="Courier New"><b>direction_1d</b>(direction_1d_enum
+val = LOW)</font></td>
+ <td>Constructor defaults to LOW. </td>
+ </tr>
+ <tr>
+ <td width="586"><b><font face="Courier New">direction_1d</font></b><font
+ face="Courier New">(const direction_1d& that)</font></td>
+ <td>Copy construct.</td>
+ </tr>
+ <tr>
+ <td width="586"><b><font face="Courier New">direction_1d</font></b><font
+ face="Courier New">(const direction_2d& that)</font></td>
+ <td>Down cast direction_2d, extracting out whether positive
+or negative</td>
+ </tr>
+ <tr>
+ <td width="586"><b><font face="Courier New">direction_1d</font></b><font
+ face="Courier New">(const direction_3d& that)</font></td>
+ <td>Down cast direction_3d, extracting out whether positive
+or negative</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">direction_1d& <b>operator=</b>(const
+direction_1d dir)</font></td>
+ <td>Assignment</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">direction_1d& <b>operator==</b>(const
+direction_1d dir) const</font></td>
+ <td>Equivalence</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">direction_1d& <b>operator!=</b>(const
+direction_1d dir) const</font></td>
+ <td>Inequivalence</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">unsigned int <b>to_int</b>()
+const</font></td>
+ <td>Convert to the integer enum value of current state to
+use as index. Auto-cast to int is disallowed for type safety
+reasons.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">direction_1d& <b>backward</b>()</font></td>
+ <td>Inverts direction.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">int <b>get_sign</b>()
+const</font></td>
+ <td>Returns positive 1 if positive direction and negative
+one if negative direction.</td>
+ </tr>
+ </tbody>
+ </table>
+ <h2>orientation_2d</h2>
+ <p> </p>
+ <p align="left">The orientation_2d data type has two possible
+states. These are the horizontal and vertical axis of a 2d
+Cartesian coordinate system. These states can be described
+by one of the two orientation_2d_enum values:</p>
+ <p align="left"><font face="Courier New">enum orientation_2d_enum
+{ HORIZONTAL = 0, VERTICAL = 1 };</font></p>
+ <h2>Member Functions</h2>
+ <table id="table2" border="1" width="100%">
+ <tbody>
+ <tr>
+ <td width="586"><b><font face="Courier New">orientation_2</font></b><font
+ face="Courier New"><b>d</b>(orientation_2d_enum val = HORIZONTAL)</font></td>
+ <td>Constructor defaults to HORIZONTAL. </td>
+ </tr>
+ <tr>
+ <td width="586"><b><font face="Courier New">orientation_2</font></b><font
+ face="Courier New"><b>d</b>(const orientation_2d& that)</font></td>
+ <td>Copy construct.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">explicit </font><b>
+ <font face="Courier New">orientation_2</font></b><font
+ face="Courier New"><b>d</b>(const direction_2d& that)</font></td>
+ <td>Down cast direction_2d, extracting out whether
+horizontal or vertical direction type</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">orientation_2d&
+ <b>operator=</b>(const orientation_2d o)</font></td>
+ <td>Assignment</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">orientation_2d&
+ <b>operator==</b>(const orientation_2d o) const</font></td>
+ <td>Equivalence</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">orientation_2d&
+ <b>operator!=</b>(const orientation_2d o) const</font></td>
+ <td>Inequivalence</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">unsigned int <b>to_int</b>()
+const</font></td>
+ <td>Convert to the integer enum value of current state to
+use as index. Auto-cast to int is disallowed for type safety
+reasons</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">orientation_2d&
+ <b>turn_90</b>()</font></td>
+ <td>Change to orthogonal orientation</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">int <b>get_perpendicular</b>()
+const</font></td>
+ <td>Returns orthogonal orientation</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">int <b>get_direction</b>(direction_1d
+dir) const</font></td>
+ <td>Returns the positive or negative direction_2d depending
+on the value of dir</td>
+ </tr>
+ </tbody>
+ </table>
+ <h2>direction_2d</h2>
+ <p> </p>
+ <p align="left">The direction_2d data type has four possible
+states. These are the cardinal directions of the 2D Cartesian
+coordinate system. These states can be described by one of
+several direction_2d_enum values:</p>
+ <p align="left"><font face="Courier New">enum direction_2d_enum {
+WEST = 0, EAST = 1, SOUTH = 2, NORTH = 3 };</font></p>
+ <h2>Member Functions</h2>
+ <table id="table3" border="1" width="100%">
+ <tbody>
+ <tr>
+ <td width="586"><font face="Courier New"><b>direction_2d</b>(direction_2d_enum
+val = WEST)</font></td>
+ <td>Constructor defaults to WEST. </td>
+ </tr>
+ <tr>
+ <td width="586"><b><font face="Courier New">direction_2d</font></b><font
+ face="Courier New">(const direction_2d& that)</font></td>
+ <td>Copy construct.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">direction_1d& <b>operator=</b>(const
+direction_2d dir)</font></td>
+ <td>Assignment</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">direction_1d& <b>operator==</b>(const
+direction_2d dir) const</font></td>
+ <td>Equivalence</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">direction_1d& <b>operator!=</b>(const
+direction_2d dir) const</font></td>
+ <td>Inequivalence</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">unsigned int <b>to_int</b>()
+const</font></td>
+ <td>Convert to the integer enum value of current state to
+use as index. Auto-cast to int is disallowed for type safety
+reasons.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">direction_2d& <b>backward</b>()</font></td>
+ <td>Inverts direction.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">direction_2d& <b>turn</b>(direction_1d
+dir)</font></td>
+ <td>Changes to direction_2d to the left if dir is LOW, to
+the right if dir is HIGH</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">direction_2d& <b>left</b>()</font></td>
+ <td>Changes to the direction_2d to the left</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">direction_2d& <b>right</b>()</font></td>
+ <td>Changes to the direction_2d to the right</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">int <b>is_positive</b>()
+const</font></td>
+ <td>Returns true if EAST or NORTH</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">int <b>is_negative</b>()
+const</font></td>
+ <td>Returns true if WEST or SOUTH</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">int <b>get_sign</b>()
+const</font></td>
+ <td>Returns positive 1 if positive direction and negative
+one if negative direction.</td>
+ </tr>
+ </tbody>
+ </table>
+ <h2>orientation_3d</h2>
+ <p> </p>
+ <p align="left">The orientation_3d data type has three possible
+states. These are the horizontal, vertical and proximal (x, y, z)
+axis of a 3d Cartesian coordinate system. These states can
+be described by one of the orientation_2d_enum values or by the
+orientation_3d_enum value:</p>
+ <p align="left"><font face="Courier New">enum orientation_3d_enum
+{ PROXIMAL = 2 };</font></p>
+ <h2>Member Functions</h2>
+ <table id="table6" border="1" width="100%">
+ <tbody>
+ <tr>
+ <td width="586"><b><font face="Courier New">orientation_3</font></b><font
+ face="Courier New"><b>d</b>(orientation_2d_enum val = HORIZONTAL)</font></td>
+ <td>Constructor defaults to HORIZONTAL. </td>
+ </tr>
+ <tr>
+ <td width="586"><b><font face="Courier New">orientation_3</font></b><font
+ face="Courier New"><b>d</b>(const orientation_3d& that)</font></td>
+ <td>Copy construct.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">explicit </font><b>
+ <font face="Courier New">orientation_3</font></b><font
+ face="Courier New"><b>d</b>(const direction_2d& that)</font></td>
+ <td>Extract out the orientation of the direction</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">explicit </font><b>
+ <font face="Courier New">orientation_3</font></b><font
+ face="Courier New"><b>d</b>(const direction_3d& that)</font></td>
+ <td>Extract out the orientation of the direction</td>
+ </tr>
+ <tr>
+ <td width="586"><b><font face="Courier New">orientation_3</font></b><font
+ face="Courier New"><b>d</b>(const orientation_2d& that)</font></td>
+ <td>Up cast orientation_2d to orientation_3d.</td>
+ </tr>
+ <tr>
+ <td width="586"><b><font face="Courier New">orientation_3</font></b><font
+ face="Courier New"><b>d</b>(const orientation_3d_enum& that)</font></td>
+ <td>Construct from constant value</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">orientation_3d&
+ <b>operator=</b>(const orientation_3d o)</font></td>
+ <td>Assignment</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">orientation_3d&
+ <b>operator==</b>(const orientation_3d o) const</font></td>
+ <td>Equivalence</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">orientation_3d&
+ <b>operator!=</b>(const orientation_3d o) const</font></td>
+ <td>Inequivalence</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">unsigned int <b>to_int</b>()
+const</font></td>
+ <td>Convert to the integer enum value of current state to
+use as index. Auto-cast to int is disallowed for type safety
+reasons</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">int <b>get_direction</b>(direction_1d
+dir) const</font></td>
+ <td>Returns the positive or negative direction_2d depending
+on the value of dir</td>
+ </tr>
+ </tbody>
+ </table>
+ <h2>direction_3d</h2>
+ <p> </p>
+ <p align="left">The direction_3d data type has six possible
+states. These are the cardinal directions of the 3D Cartesian
+coordinate system. These states can be described by one of
+the direction_2d_enum values or the direction_3d_enum values:</p>
+ <p align="left"><font face="Courier New">enum direction_3d_enum {
+DOWN = 4, UP = 5 };</font></p>
+ <h2>Member Functions</h2>
+ <table id="table5" border="1" width="100%">
+ <tbody>
+ <tr>
+ <td width="586"><font face="Courier New"><b>direction_3d</b>(direction_2d_enum
+val = WEST)</font></td>
+ <td>Constructor defaults to LOW. </td>
+ </tr>
+ <tr>
+ <td width="586"><b><font face="Courier New">direction_3d</font></b><font
+ face="Courier New">(direction_3d_enum that)</font></td>
+ <td>Construct from constant value</td>
+ </tr>
+ <tr>
+ <td width="586"><b><font face="Courier New">direction_3d</font></b><font
+ face="Courier New">(const direction_3d& that)</font></td>
+ <td>Copy construct</td>
+ </tr>
+ <tr>
+ <td width="586"><b><font face="Courier New">direction_3d</font></b><font
+ face="Courier New">(direction_2d that)</font></td>
+ <td>Up cast direction_2d to direction_3d</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">direction_3d& <b>operator=</b>(const
+direction_3d dir)</font></td>
+ <td>Assignment</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">direction_3d& <b>operator==</b>(const
+direction_3d dir) const</font></td>
+ <td>Equivalence</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">direction_2d& <b>operator!=</b>(const
+direction_3d dir) const</font></td>
+ <td>Inequivalence</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">unsigned int <b>to_int</b>()
+const</font></td>
+ <td>Convert to the integer enum value of current state to
+use as index. Auto-cast to int is disallowed for type safety
+reasons.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">direction_1d& <b>backward</b>()</font></td>
+ <td>Inverts direction.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">int <b>is_positive</b>()
+const</font></td>
+ <td>Returns true if direction is EAST, NORTH or UP.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">int <b>is_negative</b>()
+const</font></td>
+ <td>Returns true if direction is WEST, SOUTH or DOWN</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">int <b>get_sign</b>()
+const</font></td>
+ <td>Returns positive 1 if positive direction and negative
+one if negative direction.</td>
+ </tr>
+ </tbody>
+ </table>
+ </td>
+ </tr>
+ <tr>
+ <td style="background-color: rgb(238, 238, 238);" nowrap="1"
+ valign="top"> </td>
+ <td
+ style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;"
+ valign="top" width="100%">
+ <table class="docinfo" id="table7" frame="void" rules="none">
+ <colgroup> <col class="docinfo-name" /><col
+ class="docinfo-content" /> </colgroup> <tbody valign="top">
+ <tr>
+ <th class="docinfo-name">Copyright:</th>
+ <td>Copyright © Intel Corporation 2008-2010.</td>
+ </tr>
+ <tr class="field">
+ <th class="docinfo-name">License:</th>
+ <td class="field-body">Distributed under the Boost Software
+License, Version 1.0. (See accompanying file <tt class="literal"> <span
+ class="pre">LICENSE_1_0.txt</span></tt> or copy at <a
+ class="reference" target="_top"
+ href="http://www.boost.org/LICENSE_1_0.txt">
+http://www.boost.org/LICENSE_1_0.txt>)</td>
+ </tr>
+ </tbody>
+ </table>
+ </td>
+ </tr>
+ </tbody>
+</table>
+</body>
+</html>
Modified: branches/release/libs/polygon/doc/gtl_point_concept.htm
==============================================================================
--- branches/release/libs/polygon/doc/gtl_point_concept.htm (original)
+++ branches/release/libs/polygon/doc/gtl_point_concept.htm 2013-04-15 18:27:46 EDT (Mon, 15 Apr 2013)
@@ -1,409 +1,535 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:(null)1="http://www.w3.org/TR/REC-html40" lang="en"><head><!--
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"
+ xmlns:v="urn:schemas-microsoft-com:vml"
+ xmlns:o="urn:schemas-microsoft-com:office:office"
+ xmlns:(null)1="http://www.w3.org/TR/REC-html40" lang="en">
+<head>
+<!--
Copyright 2009-2010 Intel Corporation
license banner
---><title>Boost Polygon Library: Point Concept</title>
-
-
-
-
-
-
-
- <meta http-equiv="content-type" content="text/html;charset=ISO-8859-1" /><!-- <link type="text/css" rel="stylesheet" href="adobe_source.css"> --></head><body><table style="margin: 0pt; padding: 0pt; width: 100%;" border="0" cellpadding="0" cellspacing="0"><tbody><tr>
-<td style="background-color: rgb(238, 238, 238);" nowrap="1" valign="top">
- <div style="padding: 5px;" align="center">
- <img src="images/boost.png" border="0" height="86" width="277" /><a title="www.boost.org home page" href="http://www.boost.org/" tabindex="2" style="border: medium none ;">
- </a>
- </div>
- <div style="margin: 5px;">
- <h3 class="navbar">Contents</h3>
- <ul>
- <li>Boost.Polygon Main Page</li>
- <li>Design Overview</li>
- <li>Isotropy</li>
- <li>Coordinate Concept</li>
- <li>Interval Concept</li>
- <li>Point Concept</li>
+-->
+ <title>Boost Polygon Library: Point Concept</title>
+ <meta http-equiv="content-type" content="text/html;charset=ISO-8859-1" />
+<!-- <link type="text/css" rel="stylesheet" href="adobe_source.css"> -->
+</head>
+<body>
+<table style="margin: 0pt; padding: 0pt; width: 100%;" border="0"
+ cellpadding="0" cellspacing="0">
+ <tbody>
+ <tr>
+ <td style="background-color: rgb(238, 238, 238);" nowrap="1"
+ valign="top">
+ <div style="padding: 5px;" align="center"> <img
+ src="images/boost.png" border="0" height="86" width="277" /><a
+ title="www.boost.org home page" href="http://www.boost.org/"
+ tabindex="2" style="border: medium none ;"> </a> </div>
+ <div style="margin: 5px;">
+ <h3 class="navbar">Contents</h3>
+ <ul>
+ <li>Boost.Polygon Main Page</li>
+ <li>Design Overview</li>
+ <li>Isotropy</li>
+ <li>Coordinate Concept</li>
+ <li>Interval Concept</li>
+ <li>Point Concept</li>
<li>Segment Concept</li>
-
- <li>Rectangle Concept</li>
- <li>Polygon 90 Concept</li>
- <li>Polygon 90 With Holes Concept</li>
- <li>Polygon 45 Concept</li>
- <li>Polygon 45 With Holes Concept</li>
- <li>Polygon Concept</li>
- <li>Polygon With Holes Concept</li>
- <li>Polygon 90 Set Concept</li>
- <li>Polygon 45 Set Concept</li>
- <li>Polygon Set Concept</li>
- <li>Connectivity Extraction 90</li>
- <li>Connectivity Extraction 45</li>
- <li>Connectivity Extraction</li>
- <li>Property Merge 90</li>
- <li>Property Merge 45</li>
- <li>Property Merge</li>
+ <li>Rectangle Concept</li>
+ <li>Polygon 90 Concept</li>
+ <li><a href="gtl_polygon_90_with_holes_concept.htm">Polygon 90
+With Holes Concept</a></li>
+ <li>Polygon 45 Concept</li>
+ <li><a href="gtl_polygon_45_with_holes_concept.htm">Polygon 45
+With Holes Concept</a></li>
+ <li>Polygon Concept</li>
+ <li><a href="gtl_polygon_with_holes_concept.htm">Polygon With
+Holes Concept</a></li>
+ <li><a href="gtl_polygon_90_set_concept.htm">Polygon 90 Set
+Concept</a></li>
+ <li><a href="gtl_polygon_45_set_concept.htm">Polygon 45 Set
+Concept</a></li>
+ <li>Polygon Set Concept</li>
+ <li><a href="gtl_connectivity_extraction_90.htm">Connectivity
+Extraction 90</a></li>
+ <li><a href="gtl_connectivity_extraction_45.htm">Connectivity
+Extraction 45</a></li>
+ <li><a href="gtl_connectivity_extraction.htm">Connectivity
+Extraction</a></li>
+ <li>Property Merge 90</li>
+ <li>Property Merge 45</li>
+ <li>Property Merge</li>
<li><a href="voronoi_main.htm">Voronoi Main Page<br />
-</a></li>
+ </a></li>
<li>Voronoi Benchmark<br />
</li>
<li>Voronoi Builder</li>
- <li><a href="voronoi_diagram.htm">Voronoi Diagram<br />
-</a></li>
- <li>Voronoi Predicates</li>
- <li>Voronoi Robust FPT<br />
- </li>
-
-
- </ul>
- <h3 class="navbar">Other Resources</h3>
- <ul>
- <li>GTL Boostcon 2009 Paper</li>
- <li><a href="GTL_boostcon_draft03.pdf">GTL Boostcon 2009
- Presentation</a></li>
- <li>Performance Analysis</li>
- <li>Layout Versus Schematic Tutorial</li>
- <li>Minkowski Sum Tutorial</li>
+ <li>Voronoi Diagram</li>
+ </ul>
+ <h3 class="navbar">Other Resources</h3>
+ <ul>
+ <li>GTL Boostcon 2009 Paper</li>
+ <li><a href="GTL_boostcon_draft03.pdf">GTL Boostcon 2009
+Presentation</a></li>
+ <li>Performance Analysis</li>
+ <li>Layout Versus Schematic Tutorial</li>
+ <li>Minkowski Sum Tutorial</li>
<li>Voronoi Basic Tutorial</li>
- <li>Voronoi Advanced Tutorial</li>
-
- </ul>
- </div>
- <h3 class="navbar">Polygon Sponsor</h3>
- <div style="padding: 5px;" align="center">
- <img src="images/intlogo.gif" border="0" height="51" width="127" /><a title="www.adobe.com home page" href="http://www.adobe.com/" tabindex="2" style="border: medium none ;">
- </a>
- </div>
-</td>
-<td style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;" valign="top" width="100%">
-
-<!-- End Header -->
-
-<br />
-<p>
-</p><h1>Point Concept</h1>
-
-<p>
-</p><p>
-The point concept tag is <font face="Courier New">
-point_concept</font></p><p>
-To register a user defined type as a model of point concept, specialize the
-geometry concept meta-function for that type. In the example below <span style="font-family: Courier New,Courier,monospace;">CPoint</span> is registered as a model of
-point concept.</p><p>
-<font face="Courier New">template <><br />
-struct geometry_concept<CPoint> { typedef point_concept type; };</font></p><p>
-The semantic of a point is that it has an x and y
-coordinate. A std::pair<int, int>, boost::tuple<int, int> or boost::array<int, 2>
-could all be made models of point by simply providing indirect access to their
-elements through traits, however, these objects cannot be made a model of both
-point and interval in the same compilation unit, for obvious reason that
-duplicate specialization of the geometry_concept struct is illegal, but also
-because it would make overloading generic function by concept ambiguous if a
-type modeled more than one concept.</p><p>
-Below is shown the default point traits.
-Specialization of these traits is required for types that don't conform to the
-default behavior.</p>
- <p>
-template <typename T><br />
+ <li><a href="voronoi_advanced_tutorial.htm">Voronoi Advanced
+Tutorial</a></li>
+ </ul>
+ </div>
+ <h3 class="navbar">Polygon Sponsor</h3>
+ <div style="padding: 5px;" align="center"> <img
+ src="images/intlogo.gif" border="0" height="51" width="127" /><a
+ title="www.adobe.com home page" href="http://www.adobe.com/"
+ tabindex="2" style="border: medium none ;"> </a> </div>
+ </td>
+ <td
+ style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;"
+ valign="top" width="100%">
+<!-- End Header --><br />
+ <p>
+ </p>
+ <h1>Point Concept</h1>
+ <p> </p>
+ <p> The point concept tag is <font face="Courier New">
+point_concept</font></p>
+ <p> To register a user defined type as a model of point concept,
+specialize the geometry concept meta-function for that type. In
+the example below <span
+ style="font-family: Courier New,Courier,monospace;">CPoint</span> is
+registered as a model of point concept.</p>
+ <p> <font face="Courier New">template <><br />
+struct geometry_concept<CPoint> { typedef point_concept type; };</font></p>
+ <p> The semantic of a point is that it has an x and y
+coordinate. A std::pair<int, int>, boost::tuple<int,
+int> or boost::array<int, 2> could all be made models of point
+by simply providing indirect access to their elements through traits,
+however, these objects cannot be made a model of both point and
+interval in the same compilation unit, for obvious reason that
+duplicate specialization of the geometry_concept struct is illegal, but
+also because it would make overloading generic function by concept
+ambiguous if a type modeled more than one concept.</p>
+ <p> Below is shown the default point traits. Specialization
+of these traits is required for types that don't conform to the default
+behavior.</p>
+ <p style="font-family: Courier New,Courier,monospace;"> template
+<typename T><br />
struct point_traits {<br />
- typedef typename T::coordinate_type coordinate_type;<br />
-<br />
- static coordinate_type get(const T& point,
+ typedef typename T::coordinate_type
+coordinate_type;<br />
+ <br />
+ static coordinate_type get(const T& point,
orientation_2d orient) {<br />
- return point.get(orient);
-<br />
+ return
+point.get(orient);
+ <br />
}<br />
};<br />
-<br />
+ <br />
template <typename T><br />
struct point_mutable_traits {<br />
- static void set(T& point, orientation_2d orient,
-typename point_traits<T>::coordinate_type value) {<br />
- point.set(orient, value);
-<br />
+ typedef typename T::coordinate_type
+coordinate_type;<br />
+ <br />
+ static void set(T& point, orientation_2d
+orient, typename point_traits<T>::coordinate_type value) {<br />
+
+point.set(orient, value);
+ <br />
}<br />
- static T construct(typename point_traits<T>::coordinate_type
-x_value, typename point_traits<T>::coordinate_type y_value) {<br />
- return T(x_value, y_value);
-<br />
+ static T construct(typename
+point_traits<T>::coordinate_type x_value,<br />
+
+typename point_traits<T>::coordinate_type y_value) {<br />
+ return
+T(x_value, y_value);
+ <br />
}<br />
};</p>
-<p>
-Example code custom_point.cpp demonstrates
-how to map a
- user defined point class to the library point_concept</p><h2>Functions</h2>
-<table id="table1" border="1" width="100%">
- <tbody><tr>
- <td width="586"><font face="Courier New">template <typename PointType><br />
- coordinate_type <b>get</b>(const PointType& point,<br />
+ <p> Example code custom_point.cpp
+demonstrates how to map a user defined point class to the library
+point_concept</p>
+ <h2>Functions</h2>
+ <table id="table1" border="1" width="100%">
+ <tbody>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename PointType><br />
+coordinate_type <b>get</b>(const PointType& point,<br />
+
orientation_2d)</font></td>
- <td>Expects a model of point. Returns
- the x or y coordinate of the point, depending on the orientation_2d
- value.<br />
-
+ <td>Expects a model of point. Returns the x or y coordinate
+of the point, depending on the orientation_2d value.<br />
</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename PointType><br />
- void <b>set</b>(PointType& point, orientation_2d,<br />
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename PointType><br />
+void <b>set</b>(PointType& point, orientation_2d,<br />
coordinate_type)</font></td>
- <td>Expects a model of point. Sets the x or y coordinate of the point to the coordinate, depending on
- the orientation_2d value. </td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename PointType><br />PointType <b>construct</b>(coordinate_type x,<br />
+ <td>Expects a model of point. Sets the x or y coordinate of
+the point to the coordinate, depending on the orientation_2d
+value. </td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename PointType><br />
+PointType <b>construct</b>(coordinate_type x,<br />
coordinate_type y)</font></td>
- <td>Construct an object that is a model of point given x and y
- coordinate values.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename PointType1, typename PointType2><br />
- PointType1& <b>assign</b>(PointType1& left,<br />
+ <td>Construct an object that is a model of point given x
+and y coordinate values.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename PointType1, typename PointType2><br />
+PointType1& <b>assign</b>(PointType1& left,<br />
const PointType2& right)</font></td>
- <td>Copies data from right object that models point into left object
- that models point.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename PointType1, typename PointType2><br />
- bool <b>equivalence</b>(const </font><font face="Courier New">PointType1</font><font face="Courier New">& point1,<br />
- const </font><font face="Courier New">PointType2</font><font face="Courier New">& point2)</font></td>
- <td>Given two objects that model point, compares and returns true if
- their x and y values are respectively equal to each other.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename PointType><br />
- coordinate_type <b>x</b>(const </font><font face="Courier New">PointType</font><font face="Courier New">& point)</font></td>
- <td>Returns the x coordinate of an object that models point.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename </font><font face="Courier New">PointType</font><font face="Courier New">><br />
- coordinate_type <b>y</b>(const </font><font face="Courier New">PointType</font><font face="Courier New">& point)</font></td>
- <td>Returns the y coordinate of an object that models point.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename </font><font face="Courier New">PointType</font><font face="Courier New">><br />
- void <b>x</b>(p</font><font face="Courier New">PointType</font><font face="Courier New">& point, coordinate_type )</font></td>
- <td>Sets the x coordinate of the object that models point to the
- coordinate value. </td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename </font><font face="Courier New">PointType</font><font face="Courier New">><br />
- void <b>y</b>(</font><font face="Courier New">PointType</font><font face="Courier New">& point, coordinate_type )</font></td>
- <td>Sets the y coordinate of the object that models point to the
- coordinate value. </td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename </font><font face="Courier New">PointType</font><font face="Courier New">><br />
- point_type& <b>scale_up</b>(</font><font face="Courier New">PointType</font><font face="Courier New">& point, <br />
+ <td>Copies data from right object that models point into
+left object that models point.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename PointType1, typename PointType2><br />
+bool <b>equivalence</b>(const </font><font face="Courier New">PointType1</font><font
+ face="Courier New">& point1,<br />
+
+const </font><font face="Courier New">PointType2</font><font
+ face="Courier New">& point2)</font></td>
+ <td>Given two objects that model point, compares and
+returns true if their x and y values are respectively equal to each
+other.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename PointType><br />
+coordinate_type <b>x</b>(const </font><font face="Courier New">PointType</font><font
+ face="Courier New">& point)</font></td>
+ <td>Returns the x coordinate of an object that models point.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename </font><font face="Courier New">PointType</font><font
+ face="Courier New">><br />
+coordinate_type <b>y</b>(const </font><font face="Courier New">PointType</font><font
+ face="Courier New">& point)</font></td>
+ <td>Returns the y coordinate of an object that models point.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename </font><font face="Courier New">PointType</font><font
+ face="Courier New">><br />
+void <b>x</b>(p</font><font face="Courier New">PointType</font><font
+ face="Courier New">& point, coordinate_type )</font></td>
+ <td>Sets the x coordinate of the object that models point
+to the coordinate value. </td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename </font><font face="Courier New">PointType</font><font
+ face="Courier New">><br />
+void <b>y</b>(</font><font face="Courier New">PointType</font><font
+ face="Courier New">& point, coordinate_type )</font></td>
+ <td>Sets the y coordinate of the object that models point
+to the coordinate value. </td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename </font><font face="Courier New">PointType</font><font
+ face="Courier New">><br />
+point_type& <b>scale_up</b>(</font><font face="Courier New">PointType</font><font
+ face="Courier New">& point, <br />
+
unsigned_area_type factor)</font></td>
- <td>Multiplies x and y coordinate of an object that models point by
- unsigned factor.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename </font><font face="Courier New">PointType</font><font face="Courier New">><br />
- point_type& <b>scale_down</b>(</font><font face="Courier New">PointType</font><font face="Courier New">& point, <br />
+ <td>Multiplies x and y coordinate of an object that models
+point by unsigned factor.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename </font><font face="Courier New">PointType</font><font
+ face="Courier New">><br />
+point_type& <b>scale_down</b>(</font><font face="Courier New">PointType</font><font
+ face="Courier New">& point, <br />
+
unsigned_area_type factor)</font></td>
- <td>Divides x and y coordinate of an object that models point by
- unsigned factor.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename </font><font face="Courier New">PointType</font><font face="Courier New">,
- typename scaling_type><br />
- point_type& <b>scale</b>(</font><font face="Courier New">PointType</font><font face="Courier New">& point,<br />
-
- const scaling_type& factor) </font></td>
- <td>Calls the scale member function of scaling type on the x and y value
- of an object that models point and sets the point to the scaled values.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename </font><font face="Courier New">PointType</font><font face="Courier New">,
- typename transform_type><br />
- point_type& <b>transform</b>(</font><font face="Courier New">PointType</font><font face="Courier New">& point,<br />
-
- const transform_type& transform) </font></td>
- <td>Calls the transform member function of transform type on the x and y
- value of an object that models point and sets the point to the
- transformed values.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename </font><font face="Courier New">PointType</font><font face="Courier New">><br />
- point_type& <b>move</b>(</font><font face="Courier New">PointType</font><font face="Courier New">& point, orientation_2d,<br />
-
- coordinate_difference displacement)</font></td>
- <td>Adds displacement value to the coordinate of an object that models
- point indicated by the orientation_2d.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename </font><font face="Courier New">PointType</font><font face="Courier New">1, typename PointType2><br />
- </font><font face="Courier New">PointType</font><font face="Courier New">1</font><font face="Courier New">& <b>convolve</b>(</font><font face="Courier New">PointType</font><font face="Courier New">1</font><font face="Courier New">& a,<br />
- const </font><font face="Courier New">PointType2</font><font face="Courier New">& b)</font></td>
- <td>Adds x coordinate of b to x coordinate of a and adds y coordinate of
- b to y coordinate of a.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename </font><font face="Courier New">PointType</font><font face="Courier New">1</font><font face="Courier New">, typename </font><font face="Courier New">PointType</font><span style="font-family: Courier New;">2</span><font face="Courier New">><br />
- </font><font face="Courier New">PointType</font><font face="Courier New">1</font><font face="Courier New">,</font><font face="Courier New">& <b>deconvolve</b>(</font><font face="Courier New">PointType</font><font face="Courier New">1</font><font face="Courier New">& a,<br />
+ <td>Divides x and y coordinate of an object that models
+point by unsigned factor.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename </font><font face="Courier New">PointType</font><font
+ face="Courier New">, typename scaling_type><br />
+point_type& <b>scale</b>(</font><font face="Courier New">PointType</font><font
+ face="Courier New">& point,<br />
+
+const scaling_type& factor) </font></td>
+ <td>Calls the scale member function of scaling type on the
+x and y value of an object that models point and sets the point to the
+scaled values.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename </font><font face="Courier New">PointType</font><font
+ face="Courier New">, typename transform_type><br />
+point_type& <b>transform</b>(</font><font face="Courier New">PointType</font><font
+ face="Courier New">& point,<br />
+
+const transform_type& transform) </font></td>
+ <td>Calls the transform member function of transform type
+on the x and y value of an object that models point and sets the point
+to the transformed values.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename </font><font face="Courier New">PointType</font><font
+ face="Courier New">><br />
+point_type& <b>move</b>(</font><font face="Courier New">PointType</font><font
+ face="Courier New">& point, orientation_2d,<br />
+
+coordinate_difference displacement)</font></td>
+ <td>Adds displacement value to the coordinate of an object
+that models point indicated by the orientation_2d.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename </font><font face="Courier New">PointType</font><font
+ face="Courier New">1, typename PointType2><br />
+ </font><font face="Courier New">PointType</font><font
+ face="Courier New">1</font><font face="Courier New">& <b>convolve</b>(</font><font
+ face="Courier New">PointType</font><font face="Courier New">1</font><font
+ face="Courier New">& a,<br />
+
+const </font><font face="Courier New">PointType2</font><font
+ face="Courier New">& b)</font></td>
+ <td>Adds x coordinate of b to x coordinate of a and adds y
+coordinate of b to y coordinate of a.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename </font><font face="Courier New">PointType</font><font
+ face="Courier New">1</font><font face="Courier New">, typename </font><font
+ face="Courier New">PointType</font><span
+ style="font-family: Courier New;">2</span><font face="Courier New">><br />
+ </font><font face="Courier New">PointType</font><font
+ face="Courier New">1</font><font face="Courier New">,</font><font
+ face="Courier New">& <b>deconvolve</b>(</font><font
+ face="Courier New">PointType</font><font face="Courier New">1</font><font
+ face="Courier New">& a,<br />
-const </font><font face="Courier New">PointType</font><span style="font-family: Courier New;">2</span><font face="Courier New">></font><font face="Courier New">& b)</font></td>
- <td>Subtracts x coordinate of b from x coordinate of a and subtracts y
- coordinate of b from y coordinate of a. </td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename </font><font face="Courier New">PointType</font><font face="Courier New">1</font><font face="Courier New">, typename </font><font face="Courier New">PointType</font><span style="font-family: Courier New;">2</span><font face="Courier New">><br />distance_type <b>euclidean_distance</b>(<br />
- const </font><font face="Courier New">PointType</font><font face="Courier New">1</font><font face="Courier New">&, const </font><font face="Courier New">PointType</font><span style="font-family: Courier New;">2</span><font face="Courier New">&)</font></td>
- <td>Returns the distance from an object that models point to a second
- object that models point.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <</font><font face="Courier New">typename </font><font face="Courier New">PointType</font><font face="Courier New">1</font><font face="Courier New">, typename </font><font face="Courier New">PointType</font><span style="font-family: Courier New;">2</span><font face="Courier New">><br />
- coordinate_difference <b>euclidean_distance</b>(<br />
- const </font><font face="Courier New">PointType</font><font face="Courier New">1</font><font face="Courier New">&, </font><font face="Courier New">const PointType</font><span style="font-family: Courier New;">2&,</span><font face="Courier New"> orientation_2d)</font></td>
- <td>Returns the distance from an object that models point to a
- coordinate in the given orientation_2d.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <</font><font face="Courier New">typename </font><font face="Courier New">PointType</font><font face="Courier New">1</font><font face="Courier New">, typename </font><font face="Courier New">PointType</font><span style="font-family: Courier New;">2</span><font face="Courier New">><br />
- coordinate_difference <b>manhattan_distance</b>(<br />
- </font><font face="Courier New">const </font><font face="Courier New">PointType</font><font face="Courier New">1</font><font face="Courier New">&, </font><font face="Courier New">const PointType</font><span style="font-family: Courier New;">2&</span><font face="Courier New">)</font></td>
- <td>Returns the distance in x plus the distance in y from an object that
- models point to a second object that models point.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <</font><font face="Courier New">typename </font><font face="Courier New">PointType</font><font face="Courier New">1</font><font face="Courier New">, typename </font><font face="Courier New">PointType</font><span style="font-family: Courier New;">2</span><font face="Courier New">><br />
- coordinate_difference <b>distance_squared</b>(<br />
- </font><font face="Courier New">const </font><font face="Courier New">PointType</font><font face="Courier New">1</font><font face="Courier New">&, </font><font face="Courier New">const PointType</font><span style="font-family: Courier New;">2&</span><font face="Courier New">)</font></td>
- <td>Returns the square of the distance in x plus the square of the
- distance in y from an object that models point to a second object that
- models point.</td>
- </tr>
-</tbody></table>
-<h1>Point Data</h1>
-
-<p>
-</p><p>The library provides a model of point concept declared
-<font face="Courier New">
-template<typename T> point_data </font>where T is the coordinate type.</p>
-<p>This data type is used internally when a point is needed and is available to
-the library user who finds it convenient to use a library point data type
-instead of providing their own. The data type is implemented to be
-convenient to use with the library traits.</p>
-<p>Example code point_usage.cpp demonstrates using the
- library provided point data type and functions</p>
-<h2>Members</h2>
-<table id="table2" border="1" width="100%">
- <tbody>
- <tr>
- <td width="586"><b><font face="Courier New">coordinate_type</font></b></td>
- <td>T</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New"><b>point_data</b>()</font></td>
- <td>Default constructs the two coordinate
- values of the point.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New"><b>point_data</b>(T x, T y)</font></td>
- <td>Constructs an interval with two
- coordinates.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New"><b>point_data</b>(const point_data&
- that)</font></td>
- <td>Copy construct</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">point_data& <b>operator=</b>(const
- point_data& that)</font></td>
- <td>Assignment operator.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename PointType><br />
+const </font><font face="Courier New">PointType</font><span
+ style="font-family: Courier New;">2</span><font face="Courier New">></font><font
+ face="Courier New">& b)</font></td>
+ <td>Subtracts x coordinate of b from x coordinate of a and
+subtracts y coordinate of b from y coordinate of a. </td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename </font><font face="Courier New">PointType</font><font
+ face="Courier New">1</font><font face="Courier New">, typename </font><font
+ face="Courier New">PointType</font><span
+ style="font-family: Courier New;">2</span><font face="Courier New">><br />
+distance_type <b>euclidean_distance</b>(<br />
+ const </font><font face="Courier New">PointType</font><font
+ face="Courier New">1</font><font face="Courier New">&, const </font><font
+ face="Courier New">PointType</font><span
+ style="font-family: Courier New;">2</span><font face="Courier New">&)</font></td>
+ <td>Returns the distance from an object that models point
+to a second object that models point.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template <</font><font
+ face="Courier New">typename </font><font face="Courier New">PointType</font><font
+ face="Courier New">1</font><font face="Courier New">, typename </font><font
+ face="Courier New">PointType</font><span
+ style="font-family: Courier New;">2</span><font face="Courier New">><br />
+coordinate_difference <b>euclidean_distance</b>(<br />
+ const </font><font face="Courier New">PointType</font><font
+ face="Courier New">1</font><font face="Courier New">&, </font><font
+ face="Courier New">const PointType</font><span
+ style="font-family: Courier New;">2&,</span><font
+ face="Courier New"> orientation_2d)</font></td>
+ <td>Returns the distance from an object that models point
+to a coordinate in the given orientation_2d.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template <</font><font
+ face="Courier New">typename </font><font face="Courier New">PointType</font><font
+ face="Courier New">1</font><font face="Courier New">, typename </font><font
+ face="Courier New">PointType</font><span
+ style="font-family: Courier New;">2</span><font face="Courier New">><br />
+coordinate_difference <b>manhattan_distance</b>(<br />
+ </font><font face="Courier New">const </font><font
+ face="Courier New">PointType</font><font face="Courier New">1</font><font
+ face="Courier New">&, </font><font face="Courier New">const
+PointType</font><span style="font-family: Courier New;">2&</span><font
+ face="Courier New">)</font></td>
+ <td>Returns the distance in x plus the distance in y from
+an object that models point to a second object that models point.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template <</font><font
+ face="Courier New">typename </font><font face="Courier New">PointType</font><font
+ face="Courier New">1</font><font face="Courier New">, typename </font><font
+ face="Courier New">PointType</font><span
+ style="font-family: Courier New;">2</span><font face="Courier New">><br />
+coordinate_difference <b>distance_squared</b>(<br />
+ </font><font face="Courier New">const </font><font
+ face="Courier New">PointType</font><font face="Courier New">1</font><font
+ face="Courier New">&, </font><font face="Courier New">const
+PointType</font><span style="font-family: Courier New;">2&</span><font
+ face="Courier New">)</font></td>
+ <td>Returns the square of the distance in x plus the square
+of the distance in y from an object that models point to a second
+object that models point.</td>
+ </tr>
+ </tbody>
+ </table>
+ <h1>Point Data</h1>
+ <p> </p>
+ <p>The library provides a model of point concept declared
+ <font face="Courier New">template<typename T> point_data </font>where
+T is the coordinate type.</p>
+ <p>This data type is used internally when a point is needed and
+is available to the library user who finds it convenient to use a
+library point data type instead of providing their own. The data
+type is implemented to be convenient to use with the library traits.</p>
+ <p>Example code point_usage.cpp
+demonstrates using the library provided point data type and functions</p>
+ <h2>Members</h2>
+ <table id="table2" border="1" width="100%">
+ <tbody>
+ <tr>
+ <td width="586"><b><font face="Courier New">coordinate_type</font></b></td>
+ <td>T</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New"><b>point_data</b>()</font></td>
+ <td>Default constructs the two coordinate values of the
+point.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New"><b>point_data</b>(T
+x, T y)</font></td>
+ <td>Constructs an interval with two coordinates.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New"><b>point_data</b>(const
+point_data& that)</font></td>
+ <td>Copy construct</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">point_data& <b>operator=</b>(const
+point_data& that)</font></td>
+ <td>Assignment operator.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename PointType><br />
point_data& <b>operator=</b>(const PointType& that) const</font></td>
- <td>Assign from an object that is a model of point.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">bool<b>
- operator==</b>(const </font><font face="Courier New">point_data</font><font face="Courier New">& that) const</font></td>
- <td>Equality operator overload.<br />
-</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">bool<b>
- operator!=</b>(const </font><font face="Courier New">point_data</font><font face="Courier New">& that) const</font></td>
- <td>Inequality operator overload.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New"><b> </b>bool<b>
- operator<</b>(const </font><font face="Courier New">point_data</font><font face="Courier New">& that) const</font></td>
- <td>Compares y coordinates then x coordinates to break ties.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New"><b> </b>bool<b>
- operator<=</b>(const </font><font face="Courier New">point_data</font><font face="Courier New">& that) const</font></td>
- <td>Compares y coordinates then x coordinates to break ties.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New"><b> </b>bool<b>
- operator></b>(const </font><font face="Courier New">point_data</font><font face="Courier New">& that) const</font></td>
- <td>Compares low coordinates then high coordinates to break ties.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">bool<b>
- operator>=</b>(const </font><font face="Courier New">point_data</font><font face="Courier New">& that) const</font></td>
- <td>Compares low coordinates then high coordinates to break ties.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">T <b>get</b>(orientation_2d
- orient) const</font></td>
- <td>Get the coordinate in the given orientation.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">T <b>x</b>() const</font></td>
- <td>Get the coordinate in the horizontal orientation.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">T <b>y</b>() const</font></td>
- <td>Get the coordinate in the vertical orientation.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">void <b>set</b>(orientation_2d
- orient, T value)</font></td>
- <td>Sets the coordinate in the given orientation to the value.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">void <b>x</b>(T value)</font></td>
- <td>Sets the coordinate in the horizontal orientation to the value.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">void <b>y</b>(T value)</font></td>
- <td>Sets the coordinate in the vertical orientation to the value.</td>
- </tr>
- </tbody></table>
- </td></tr><tr>
-<td style="background-color: rgb(238, 238, 238);" nowrap="1" valign="top">
- </td>
-<td style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;" valign="top" width="100%">
-
-
-<table class="docinfo" id="table3" frame="void" rules="none">
- <colgroup>
- <col class="docinfo-name" /><col class="docinfo-content" />
- </colgroup>
- <tbody valign="top">
- <tr>
- <th class="docinfo-name">Copyright:</th>
- <td>Copyright © Intel Corporation 2008-2010.</td>
- </tr>
- <tr class="field">
- <th class="docinfo-name">License:</th>
- <td class="field-body">Distributed under the Boost Software License,
- Version 1.0. (See accompanying file <tt class="literal">
- <span class="pre">LICENSE_1_0.txt</span></tt> or copy at
- <a class="reference" target="_top" href="http://www.boost.org/LICENSE_1_0.txt">
- http://www.boost.org/LICENSE_1_0.txt>)</td>
- </tr>
-</tbody></table>
-
-</td></tr></tbody></table></body></html>
\ No newline at end of file
+ <td>Assign from an object that is a model of point.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">bool<b> operator==</b>(const
+ </font><font face="Courier New">point_data</font><font
+ face="Courier New">& that) const</font></td>
+ <td>Equality operator overload.<br />
+ </td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">bool<b> operator!=</b>(const
+ </font><font face="Courier New">point_data</font><font
+ face="Courier New">& that) const</font></td>
+ <td>Inequality operator overload.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New"><b> </b>bool<b>
+operator<</b>(const </font><font face="Courier New">point_data</font><font
+ face="Courier New">& that) const</font></td>
+ <td>Compares y coordinates then x coordinates to break ties.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New"><b> </b>bool<b>
+operator<=</b>(const </font><font face="Courier New">point_data</font><font
+ face="Courier New">& that) const</font></td>
+ <td>Compares y coordinates then x coordinates to break ties.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New"><b> </b>bool<b>
+operator></b>(const </font><font face="Courier New">point_data</font><font
+ face="Courier New">& that) const</font></td>
+ <td>Compares low coordinates then high coordinates to break
+ties.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">bool<b>
+operator>=</b>(const </font><font face="Courier New">point_data</font><font
+ face="Courier New">& that) const</font></td>
+ <td>Compares low coordinates then high coordinates to break
+ties.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">T <b>get</b>(orientation_2d
+orient) const</font></td>
+ <td>Get the coordinate in the given orientation.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">T <b>x</b>() const</font></td>
+ <td>Get the coordinate in the horizontal orientation.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">T <b>y</b>() const</font></td>
+ <td>Get the coordinate in the vertical orientation.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">void <b>set</b>(orientation_2d
+orient, T value)</font></td>
+ <td>Sets the coordinate in the given orientation to the
+value.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">void <b>x</b>(T
+value)</font></td>
+ <td>Sets the coordinate in the horizontal orientation to
+the value.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">void <b>y</b>(T
+value)</font></td>
+ <td>Sets the coordinate in the vertical orientation to the
+value.</td>
+ </tr>
+ </tbody>
+ </table>
+ </td>
+ </tr>
+ <tr>
+ <td style="background-color: rgb(238, 238, 238);" nowrap="1"
+ valign="top"> </td>
+ <td
+ style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;"
+ valign="top" width="100%">
+ <table class="docinfo" id="table3" frame="void" rules="none">
+ <colgroup> <col class="docinfo-name" /><col
+ class="docinfo-content" /> </colgroup> <tbody valign="top">
+ <tr>
+ <th class="docinfo-name">Copyright:</th>
+ <td>Copyright © Intel Corporation 2008-2010.</td>
+ </tr>
+ <tr class="field">
+ <th class="docinfo-name">License:</th>
+ <td class="field-body">Distributed under the Boost Software
+License, Version 1.0. (See accompanying file <tt class="literal"> <span
+ class="pre">LICENSE_1_0.txt</span></tt> or copy at <a
+ class="reference" target="_top"
+ href="http://www.boost.org/LICENSE_1_0.txt">
+http://www.boost.org/LICENSE_1_0.txt>)</td>
+ </tr>
+ </tbody>
+ </table>
+ </td>
+ </tr>
+ </tbody>
+</table>
+</body>
+</html>
Modified: branches/release/libs/polygon/doc/gtl_polygon_45_concept.htm
==============================================================================
--- branches/release/libs/polygon/doc/gtl_polygon_45_concept.htm (original)
+++ branches/release/libs/polygon/doc/gtl_polygon_45_concept.htm 2013-04-15 18:27:46 EDT (Mon, 15 Apr 2013)
@@ -1,376 +1,432 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:(null)1="http://www.w3.org/TR/REC-html40" lang="en"><head>
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"
+ xmlns:v="urn:schemas-microsoft-com:vml"
+ xmlns:o="urn:schemas-microsoft-com:office:office"
+ xmlns:(null)1="http://www.w3.org/TR/REC-html40" lang="en">
+<head>
<!--
Copyright 2009-2010 Intel Corporation
license banner
---><title>Boost Polygon Library: Polygon 45 Concept</title>
-
-
-
- <meta http-equiv="content-type" content="text/html;charset=ISO-8859-1" /><!-- <link type="text/css" rel="stylesheet" href="adobe_source.css"> --></head><body><table style="margin: 0pt; padding: 0pt; width: 100%;" border="0" cellpadding="0" cellspacing="0"><tbody><tr>
-<td style="background-color: rgb(238, 238, 238);" nowrap="1" valign="top">
- <div style="padding: 5px;" align="center">
- <img src="images/boost.png" border="0" height="86" width="277" /><a title="www.boost.org home page" href="http://www.boost.org/" tabindex="2" style="border: medium none ;">
- </a>
- </div>
- <div style="margin: 5px;">
- <h3 class="navbar">Contents</h3>
- <ul>
- <li>Boost.Polygon Main Page</li>
- <li>Design Overview</li>
- <li>Isotropy</li>
- <li>Coordinate Concept</li>
- <li>Interval Concept</li>
- <li>Point Concept</li>
+-->
+ <title>Boost Polygon Library: Polygon 45 Concept</title>
+ <meta http-equiv="content-type" content="text/html;charset=ISO-8859-1" />
+<!-- <link type="text/css" rel="stylesheet" href="adobe_source.css"> -->
+</head>
+<body>
+<table style="margin: 0pt; padding: 0pt; width: 100%;" border="0"
+ cellpadding="0" cellspacing="0">
+ <tbody>
+ <tr>
+ <td style="background-color: rgb(238, 238, 238);" nowrap="1"
+ valign="top">
+ <div style="padding: 5px;" align="center"> <img
+ src="images/boost.png" border="0" height="86" width="277" /><a
+ title="www.boost.org home page" href="http://www.boost.org/"
+ tabindex="2" style="border: medium none ;"> </a> </div>
+ <div style="margin: 5px;">
+ <h3 class="navbar">Contents</h3>
+ <ul>
+ <li>Boost.Polygon Main Page</li>
+ <li>Design Overview</li>
+ <li>Isotropy</li>
+ <li>Coordinate Concept</li>
+ <li>Interval Concept</li>
+ <li>Point Concept</li>
<li>Segment Concept</li>
-
- <li>Rectangle Concept</li>
- <li>Polygon 90 Concept</li>
- <li>Polygon 90 With Holes Concept</li>
- <li>Polygon 45 Concept</li>
- <li>Polygon 45 With Holes Concept</li>
- <li>Polygon Concept</li>
- <li>Polygon With Holes Concept</li>
- <li>Polygon 90 Set Concept</li>
- <li>Polygon 45 Set Concept</li>
- <li>Polygon Set Concept</li>
- <li>Connectivity Extraction 90</li>
- <li>Connectivity Extraction 45</li>
- <li>Connectivity Extraction</li>
- <li>Property Merge 90</li>
- <li>Property Merge 45</li>
- <li>Property Merge</li>
+ <li>Rectangle Concept</li>
+ <li>Polygon 90 Concept</li>
+ <li><a href="gtl_polygon_90_with_holes_concept.htm">Polygon 90
+With Holes Concept</a></li>
+ <li>Polygon 45 Concept</li>
+ <li><a href="gtl_polygon_45_with_holes_concept.htm">Polygon 45
+With Holes Concept</a></li>
+ <li>Polygon Concept</li>
+ <li><a href="gtl_polygon_with_holes_concept.htm">Polygon With
+Holes Concept</a></li>
+ <li><a href="gtl_polygon_90_set_concept.htm">Polygon 90 Set
+Concept</a></li>
+ <li><a href="gtl_polygon_45_set_concept.htm">Polygon 45 Set
+Concept</a></li>
+ <li>Polygon Set Concept</li>
+ <li><a href="gtl_connectivity_extraction_90.htm">Connectivity
+Extraction 90</a></li>
+ <li><a href="gtl_connectivity_extraction_45.htm">Connectivity
+Extraction 45</a></li>
+ <li><a href="gtl_connectivity_extraction.htm">Connectivity
+Extraction</a></li>
+ <li>Property Merge 90</li>
+ <li>Property Merge 45</li>
+ <li>Property Merge</li>
<li><a href="voronoi_main.htm">Voronoi Main Page<br />
-</a></li>
+ </a></li>
<li>Voronoi Benchmark<br />
</li>
<li>Voronoi Builder</li>
- <li><a href="voronoi_diagram.htm">Voronoi Diagram<br />
-</a></li>
- <li>Voronoi Predicates</li>
- <li>Voronoi Robust FPT<br />
- </li>
-
-
- </ul>
- <h3 class="navbar">Other Resources</h3>
- <ul>
+ <li>Voronoi Diagram</li>
+ </ul>
+ <h3 class="navbar">Other Resources</h3>
+ <ul>
<li>GTL Boostcon 2009 Paper</li>
- <li><a href="GTL_boostcon_draft03.pdf">GTL Boostcon 2009
- Presentation</a></li>
+ <li><a href="GTL_boostcon_draft03.pdf">GTL Boostcon 2009
+Presentation</a></li>
<li>Performance Analysis</li>
<li>Layout Versus Schematic Tutorial</li>
<li>Minkowski Sum Tutorial</li>
<li>Voronoi Basic Tutorial</li>
- <li>Voronoi Advanced Tutorial</li>
-</ul>
- </div>
- <h3 class="navbar">Polygon Sponsor</h3>
- <div style="padding: 5px;" align="center">
- <img src="images/intlogo.gif" border="0" height="51" width="127" /><a title="www.adobe.com home page" href="http://www.adobe.com/" tabindex="2" style="border: medium none ;">
- </a>
- </div>
-</td>
-<td style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;" valign="top" width="100%">
-
-<!-- End Header -->
-
-<br />
-<p>
-</p><h1>Polygon 45 Concept</h1>
-
-<p>
-</p><p>The polygon_45 concept tag is <font face="Courier New">
+ <li><a href="voronoi_advanced_tutorial.htm">Voronoi Advanced
+Tutorial</a></li>
+ </ul>
+ </div>
+ <h3 class="navbar">Polygon Sponsor</h3>
+ <div style="padding: 5px;" align="center"> <img
+ src="images/intlogo.gif" border="0" height="51" width="127" /><a
+ title="www.adobe.com home page" href="http://www.adobe.com/"
+ tabindex="2" style="border: medium none ;"> </a> </div>
+ </td>
+ <td
+ style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;"
+ valign="top" width="100%">
+<!-- End Header --><br />
+ <p>
+ </p>
+ <h1>Polygon 45 Concept</h1>
+ <p> </p>
+ <p>The polygon_45 concept tag is <font face="Courier New">
polygon_45_concept</font></p>
-<p>
-To register a user defined type as a model of
-<font face="Times New Roman">polygon_45 </font>concept, specialize the
-geometry concept meta-function for that type. In the example below CPolygon45 is registered as a model of
-polygon_45 concept.</p><p>
-<font face="Courier New">template <><br />
-struct geometry_concept<CPolygon45> { typedef polygon_45_concept type; };</font></p><p>
-<font face="Times New Roman">The semantic of a polygon_45 is that it can provide
-iterators over the points that represent its vertices, angles formed as these
-vertices must be multiple of 45-degree relative to the coordinate axis. It
-is acceptable to have the last edge explict with the first and last point equal
-to each other or implied by this segement that would connect the first and last
-point. A mutable polygon_45 must also be able to set its geometry based on
-an interator range over such points. A std::vector<point_data<int> >
-or std::list<point_data<int> >
-could be made models of polygon_45_concept by simply providing access to their
-iterators through traits. Library functions that create polygon objects
-require that those objects provide a default constructor.</font></p><p>
-<font face="Times New Roman">Below is shown the default polygon traits.
-Specialization of these traits is required for types that don't conform to the
-default behavior. Note that these traits are also used by several other
-polygon concepts through SFINAE enable template parameter. The SFINAE enable
-parameter also allows the library to provide default specialization that work
-for any object that models the 90 degree polygon concepts.</font></p><p>
-<font face="Courier New">template <typename T, typename enable = gtl_yes><br />
+ <p> To register a user defined type as a model of <font
+ face="Times New Roman">polygon_45 </font>concept, specialize the
+geometry concept meta-function for that type. In the example
+below CPolygon45 is registered as a model of polygon_45 concept.</p>
+ <p> <font face="Courier New">template <><br />
+struct geometry_concept<CPolygon45> { typedef polygon_45_concept
+type; };</font></p>
+ <p> <font face="Times New Roman">The semantic of a polygon_45 is
+that it can provide iterators over the points that represent its
+vertices, angles formed as these vertices must be multiple of 45-degree
+relative to the coordinate axis. It is acceptable to have the
+last edge explict with the first and last point equal to each other or
+implied by this segement that would connect the first and last
+point. A mutable polygon_45 must also be able to set its geometry
+based on an interator range over such points. A
+std::vector<point_data<int> > or
+std::list<point_data<int> > could be made models of
+polygon_45_concept by simply providing access to their iterators
+through traits. Library functions that create polygon objects
+require that those objects provide a default constructor.</font></p>
+ <p> <font face="Times New Roman">Below is shown the default
+polygon traits. Specialization of these traits is required for
+types that don't conform to the default behavior. Note that these
+traits are also used by several other polygon concepts through SFINAE
+enable template parameter. The SFINAE enable parameter also
+allows the library to provide default specialization that work for any
+object that models the 90 degree polygon concepts.</font></p>
+ <p><font face="Courier New">template <typename T, typename
+enable = gtl_yes><br />
struct polygon_traits {};<br />
-<br />
+ <br />
template <typename T><br />
struct polygon_traits<T, <br />
typename gtl_or_4<<br />
- typename gtl_same_type<typename geometry_concept<T>::type,
-polygon_concept>::type,<br />
- typename gtl_same_type<typename geometry_concept<T>::type,
-polygon_45_concept>::type,<br />
- typename gtl_same_type<typename geometry_concept<T>::type,
-polygon_with_holes_concept>::type,<br />
- typename gtl_same_type<typename geometry_concept<T>::type,
-polygon_45_with_holes_concept>::type<br />
+ typename gtl_same_type<typename
+geometry_concept<T>::type, polygon_concept>::type,<br />
+ typename gtl_same_type<typename
+geometry_concept<T>::type, polygon_45_concept>::type,<br />
+ typename gtl_same_type<typename
+geometry_concept<T>::type, polygon_with_holes_concept>::type,<br />
+ typename gtl_same_type<typename
+geometry_concept<T>::type, polygon_45_with_holes_concept>::type<br />
>::type> {<br />
- typedef typename T::coordinate_type coordinate_type;<br />
- typedef typename T::iterator_type iterator_type;<br />
+ typedef typename T::coordinate_type
+coordinate_type;<br />
+ typedef typename T::iterator_type
+iterator_type;<br />
typedef typename T::point_type point_type;<br />
- static inline iterator_type begin_points(const T& t) {<br />
+ static inline iterator_type begin_points(const
+T& t) {<br />
return t.begin();<br />
}<br />
- static inline iterator_type end_points(const T& t) {<br />
+ static inline iterator_type end_points(const
+T& t) {<br />
return t.end();<br />
}<br />
- static inline unsigned int size(const T& t) {<br />
+ static inline unsigned int size(const T&
+t) {<br />
return t.size();<br />
}<br />
- static inline winding_direction winding(const T& t) {<br />
- return unknown_winding;<br />
+ static inline winding_direction winding(const
+T& t) {<br />
+ return
+unknown_winding;<br />
}<br />
};</font></p>
-<p><font face="Courier New">template <typename T, typename enable = void><br />
+ <p><font face="Courier New">template <typename T, typename
+enable = void><br />
struct polygon_mutable_traits {<br />
template <typename iT><br />
- static inline T& set_points(T& t, iT input_begin, iT
-input_end) {<br />
- t.set(input_begin,
-input_end);<br />
+ static inline T& set_points(T& t, iT
+input_begin, iT input_end) {<br />
+
+t.set(input_begin, input_end);<br />
return t;<br />
}<br />
};</font></p>
-<p>An object that is a model of <font face="Courier New">
-polygon_45_concept</font> can be viewed as a model of any of its
-refinements if it is determined at runtime to conform to the restriction of
-those concepts. This concept casting is accomplished through the
-<font face="Courier New">view_as<>()</font> function.</p>
-<p><font face="Courier New">view_as<rectangle_concept>(polygon_45_object)</font><br />
-<font face="Courier New">view_as<polygon_90_concept>(polygon_45_object)</font></p>
-<p>The return value of <font face="Courier New">view_as<>()</font> can be
-passed into any interface that expects an object of the conceptual type
-specified in its template parameter.</p>
-<h2>Functions</h2>
-<table id="table1" border="1" width="100%">
- <tbody><tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- point_iterator_type <b>begin_points</b>(const T& polygon)</font></td>
- <td><font face="Times New Roman">Expects a model of polygon_45.
- Returns the begin iterator over the range of points that correspond to
- vertices of the polygon.</font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- point_iterator_type <b>end_points</b>(const T& polygon)</font></td>
- <td><font face="Times New Roman">Expects a model of polygon_45.
- Returns the end iterator over the range of points that correspond to
- vertices of the polygon.</font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T, typename
- iterator><br />
- void <b>set_points</b>(T& polygon, iterator b, iterator e)</font></td>
- <td><font face="Times New Roman">Expects a model of polygon_45.
- Sets the polygon to the point data range [b,e) that corresponds to
- vertices of a polygon. Non-45 edges between successive input
- points is disallowed.</font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- unsigned int <b>size</b>(const T& polygon)</font></td>
- <td><font face="Times New Roman">Returns the number of edges in the
- polygon.</font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- T1& <b>assign</b>(T1& left, const T2& right)</font></td>
- <td>Copies data from right object that models polygon_45 into left object
- that models polygon_45.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T,
- typename point_type><br />
- bool <b>contains</b>(const T&, const point_type& point, <br />
-
- bool consider_touch=true)</font></td>
- <td>Given an object that models polygon_45 and an object that models
- point, returns true
- if the polygon contains the point. If the consider_touch
- flag is true will return true if the point lies along the boundary of
- the polygon. Linear wrt. vertices.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">// get the center coordinate<br />
- template <typename T, typename point_type><br />
- void <b>center</b>(point_type& p, const T& polygon)</font></td>
- <td>Sets object that models point to the center point of the bounding
- box of an object that models polygon_45. Linear wrt. vertices.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T,
- typename rectangle_type><br />
- bool <b>extents</b>(rectangle_type& bbox, const T& polygon)</font></td>
- <td>Sets object that models rectangle to the bounding box of an object
- that models polygon_45 and returns true. Returns false and leaves
- bbox unchanged if polygon is empty. Linear wrt. vertices.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- area_type <b>area</b>(const T& polygon)</font></td>
- <td>Returns the area of an object
- that models polygon_45. Linear wrt. vertices.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- direction_1d <b>winding</b>(const T& polygon)</font></td>
- <td>Returns the winding direction of an object
- that models polygon_45, LOW == CLOCKWISE, HIGH = COUNTERCLOCKWISE.
- Complexity depends upon winding trait.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- coordinate_distance <b>perimeter</b>(const T& polygon)</font></td>
- <td>Returns the perimeter length of an object
- that models polygon_45. Linear wrt. vertices.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T,
- typename transform_type><br />
- T& <b>transform</b>(T& polygon, const transform_type&)</font></td>
- <td>Applies transform() on the vertices of polygon and sets the polygon to that described by the result of
- transforming its vertices. Linear wrt. vertices.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- T& <b>scale_up</b>(T& polygon, unsigned_area_type factor)</font></td>
- <td>Scales up coordinate of an object that models
- polygon_45 by unsigned factor. Linear wrt. vertices.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- T& <b>scale_down</b>(T& polygon, unsigned_area_type factor)</font></td>
- <td>Scales down coordinates of an object that models
- polygon_45 by unsigned factor. Linear wrt. vertices.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T, scaling_type><br />
- T& <b>scale</b>(T& rectangle, double scaling) </font></td>
- <td>Scales coordinates of an object that models polygon_45 by floating
- point factor. Linear wrt. vertices.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- T& <b>move</b>(T& polygon, orientation_2d,<br />
- coordinate_difference displacement)</font></td>
- <td>Adds displacement value to coordinate indicated by orientation_2d of
- vertices of an object that models polygon_45. Linear wrt.
- vertices.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename polygon_type, typename point_type><br />
- polygon_type& <b>convolve</b>(polygon_type& polygon,<br />
+ <p>An object that is a model of <font face="Courier New">
+polygon_45_concept</font> can be viewed as a model of any of its
+refinements if it is determined at runtime to conform to the
+restriction of those concepts. This concept casting is
+accomplished through the
+ <font face="Courier New">view_as<>()</font> function.</p>
+ <p><font face="Courier New">view_as<rectangle_concept>(polygon_45_object)</font><br />
+ <font face="Courier New">view_as<polygon_90_concept>(polygon_45_object)</font></p>
+ <p>The return value of <font face="Courier New">view_as<>()</font>
+can be passed into any interface that expects an object of the
+conceptual type specified in its template parameter.</p>
+ <h2>Functions</h2>
+ <table id="table1" border="1" width="100%">
+ <tbody>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+point_iterator_type <b>begin_points</b>(const T& polygon)</font></td>
+ <td><font face="Times New Roman">Expects a model of
+polygon_45. Returns the begin iterator over the range of points
+that correspond to vertices of the polygon.</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+point_iterator_type <b>end_points</b>(const T& polygon)</font></td>
+ <td><font face="Times New Roman">Expects a model of
+polygon_45. Returns the end iterator over the range of points
+that correspond to vertices of the polygon.</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename iterator><br />
+void <b>set_points</b>(T& polygon, iterator b, iterator e)</font></td>
+ <td><font face="Times New Roman">Expects a model of
+polygon_45. Sets the polygon to the point data range [b,e)
+that corresponds to vertices of a polygon. Non-45 edges between
+successive input points is disallowed.</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+unsigned int <b>size</b>(const T& polygon)</font></td>
+ <td><font face="Times New Roman">Returns the number of
+edges in the polygon.</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+T1& <b>assign</b>(T1& left, const T2& right)</font></td>
+ <td>Copies data from right object that models polygon_45
+into left object that models polygon_45.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename point_type><br />
+bool <b>contains</b>(const T&, const point_type& point, <br />
+
+bool consider_touch=true)</font></td>
+ <td>Given an object that models polygon_45 and an object
+that models point, returns true if the polygon contains the
+point. If the consider_touch flag is true will return true if the
+point lies along the boundary of the polygon. Linear wrt.
+vertices.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">// get the center
+coordinate<br />
+template <typename T, typename point_type><br />
+void <b>center</b>(point_type& p, const T& polygon)</font></td>
+ <td>Sets object that models point to the center point of
+the bounding box of an object that models polygon_45. Linear wrt.
+vertices.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename rectangle_type><br />
+bool <b>extents</b>(rectangle_type& bbox, const T& polygon)</font></td>
+ <td>Sets object that models rectangle to the bounding box
+of an object that models polygon_45 and returns true. Returns
+false and leaves bbox unchanged if polygon is empty. Linear wrt.
+vertices.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+area_type <b>area</b>(const T& polygon)</font></td>
+ <td>Returns the area of an object that models
+polygon_45. Linear wrt. vertices.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+direction_1d <b>winding</b>(const T& polygon)</font></td>
+ <td>Returns the winding direction of an object that models
+polygon_45, LOW == CLOCKWISE, HIGH = COUNTERCLOCKWISE. Complexity
+depends upon winding trait.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+coordinate_distance <b>perimeter</b>(const T& polygon)</font></td>
+ <td>Returns the perimeter length of an object that models
+polygon_45. Linear wrt. vertices.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename transform_type><br />
+T& <b>transform</b>(T& polygon, const transform_type&)</font></td>
+ <td>Applies transform() on the vertices of polygon and sets
+the polygon to that described by the result of transforming its
+vertices. Linear wrt. vertices.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+T& <b>scale_up</b>(T& polygon, unsigned_area_type factor)</font></td>
+ <td>Scales up coordinate of an object that models
+polygon_45 by unsigned factor. Linear wrt. vertices.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+T& <b>scale_down</b>(T& polygon, unsigned_area_type factor)</font></td>
+ <td>Scales down coordinates of an object that models
+polygon_45 by unsigned factor. Linear wrt. vertices.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, scaling_type><br />
+T& <b>scale</b>(T& rectangle, double scaling) </font></td>
+ <td>Scales coordinates of an object that models polygon_45
+by floating point factor. Linear wrt. vertices.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+T& <b>move</b>(T& polygon, orientation_2d,<br />
+ coordinate_difference
+displacement)</font></td>
+ <td>Adds displacement value to coordinate indicated by
+orientation_2d of vertices of an object that models polygon_45.
+Linear wrt. vertices.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename polygon_type, typename point_type><br />
+polygon_type& <b>convolve</b>(polygon_type& polygon,<br />
+
const point_type& point)</font></td>
- <td>Convolves coordinate values of point with vertices of an
- object that models polygon_45. Linear wrt. vertices.</td>
- </tr>
- </tbody></table>
- <h1>Polygon 45 Data</h1>
-
-<p>
-</p><p>The library provides a model of polygon 45 concept declared
-<font face="Courier New">
-template<typename T> polygon_45_data </font>where T is the coordinate type.</p>
-<p>This data type is used internally when a 45-degree polygon is needed and is
-available to the library user who finds it convenient to use a library polygon
-data type instead of providing their own. The data type is implemented to
-be convenient to use with the library traits.</p>
-<h2>Members</h2>
-<table id="table2" border="1" width="100%">
- <tbody><tr>
- <td width="586"><b><font face="Courier New">geometry_type</font></b></td>
- <td><font face="Times New Roman">polygon_45_concept</font></td>
- </tr>
- <tr>
- <td width="586"><b><font face="Courier New">coordinate_type</font></b></td>
- <td><font face="Times New Roman">T</font></td>
- </tr>
- <tr>
- <td width="586"><b><font face="Courier New">iterator_type</font></b></td>
- <td>Iterator over vertices point_data<T> vertices of polygon</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New"><b>polygon_45_data</b>()</font></td>
- <td><font face="Times New Roman">Default constructs the </font>polygon.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New"><b>polygon_45_data</b>(const
- polygon_45_data& that)</font></td>
- <td><font face="Times New Roman">Copy construct</font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">polygon_45_data& <b>operator=</b>(const
- polygon_45_data& that)</font></td>
- <td>Assignment operator.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T2><b>
- <br /> </b>polygon_45_data& <b>operator=</b>(const T2& that) const</font></td>
- <td>Assign from an object that is a model of polygon 45.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">iterator_type <b>begin</b>()
- const</font></td>
- <td>Get the begin iterator over vertices of the polygon.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">iterator_type <b>end</b>()
- const</font></td>
- <td>Get the end iterator over vertices of the polygon.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">std::size_t <b>size</b>() const</font></td>
- <td>Get the number of elements in the sequence stored to the polygon,
- usually equal to the number of edges of the polygon.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename iT><b>
- <br /> </b>void <b>set</b>(iT begin_points, iT end_points)</font></td>
- <td>Sets the polygon to the iterator range of points. No check is
- performed to ensure the points describe corners that are multiples of 45
- degrees relative to the coordinate axis.</td>
- </tr>
-</tbody></table>
- </td></tr><tr>
-<td style="background-color: rgb(238, 238, 238);" nowrap="1" valign="top">
- </td>
-<td style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;" valign="top" width="100%">
-
-
-<table class="docinfo" id="table3" frame="void" rules="none">
- <colgroup>
- <col class="docinfo-name" /><col class="docinfo-content" />
- </colgroup>
- <tbody valign="top">
- <tr>
- <th class="docinfo-name">Copyright:</th>
- <td>Copyright © Intel Corporation 2008-2010.</td>
- </tr>
- <tr class="field">
- <th class="docinfo-name">License:</th>
- <td class="field-body">Distributed under the Boost Software License,
- Version 1.0. (See accompanying file <tt class="literal">
- <span class="pre">LICENSE_1_0.txt</span></tt> or copy at
- <a class="reference" target="_top" href="http://www.boost.org/LICENSE_1_0.txt">
- http://www.boost.org/LICENSE_1_0.txt>)</td>
- </tr>
-</tbody></table>
-
-</td></tr></tbody></table></body></html>
\ No newline at end of file
+ <td>Convolves coordinate values of point with vertices of
+an object that models polygon_45. Linear wrt. vertices.</td>
+ </tr>
+ </tbody>
+ </table>
+ <h1>Polygon 45 Data</h1>
+ <p> </p>
+ <p>The library provides a model of polygon 45 concept declared
+ <font face="Courier New">template<typename T>
+polygon_45_data </font>where T is the coordinate type.</p>
+ <p>This data type is used internally when a 45-degree polygon is
+needed and is available to the library user who finds it convenient to
+use a library polygon data type instead of providing their own.
+The data type is implemented to be convenient to use with the library
+traits.</p>
+ <h2>Members</h2>
+ <table id="table2" border="1" width="100%">
+ <tbody>
+ <tr>
+ <td width="586"><b><font face="Courier New">geometry_type</font></b></td>
+ <td><font face="Times New Roman">polygon_45_concept</font></td>
+ </tr>
+ <tr>
+ <td width="586"><b><font face="Courier New">coordinate_type</font></b></td>
+ <td><font face="Times New Roman">T</font></td>
+ </tr>
+ <tr>
+ <td width="586"><b><font face="Courier New">iterator_type</font></b></td>
+ <td>Iterator over vertices point_data<T> vertices of
+polygon</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New"><b>polygon_45_data</b>()</font></td>
+ <td><font face="Times New Roman">Default constructs the </font>polygon.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New"><b>polygon_45_data</b>(const
+polygon_45_data& that)</font></td>
+ <td><font face="Times New Roman">Copy construct</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">polygon_45_data&
+ <b>operator=</b>(const polygon_45_data& that)</font></td>
+ <td>Assignment operator.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T2><b> <br />
+ </b>polygon_45_data& <b>operator=</b>(const T2&
+that) const</font></td>
+ <td>Assign from an object that is a model of polygon 45.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">iterator_type <b>begin</b>()
+const</font></td>
+ <td>Get the begin iterator over vertices of the polygon.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">iterator_type <b>end</b>()
+const</font></td>
+ <td>Get the end iterator over vertices of the polygon.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">std::size_t <b>size</b>()
+const</font></td>
+ <td>Get the number of elements in the sequence stored to
+the polygon, usually equal to the number of edges of the polygon.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename iT><b> <br />
+ </b>void <b>set</b>(iT begin_points, iT end_points)</font></td>
+ <td>Sets the polygon to the iterator range of points.
+No check is performed to ensure the points describe corners that are
+multiples of 45 degrees relative to the coordinate axis.</td>
+ </tr>
+ </tbody>
+ </table>
+ </td>
+ </tr>
+ <tr>
+ <td style="background-color: rgb(238, 238, 238);" nowrap="1"
+ valign="top"> </td>
+ <td
+ style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;"
+ valign="top" width="100%">
+ <table class="docinfo" id="table3" frame="void" rules="none">
+ <colgroup> <col class="docinfo-name" /><col
+ class="docinfo-content" /> </colgroup> <tbody valign="top">
+ <tr>
+ <th class="docinfo-name">Copyright:</th>
+ <td>Copyright © Intel Corporation 2008-2010.</td>
+ </tr>
+ <tr class="field">
+ <th class="docinfo-name">License:</th>
+ <td class="field-body">Distributed under the Boost Software
+License, Version 1.0. (See accompanying file <tt class="literal"> <span
+ class="pre">LICENSE_1_0.txt</span></tt> or copy at <a
+ class="reference" target="_top"
+ href="http://www.boost.org/LICENSE_1_0.txt">
+http://www.boost.org/LICENSE_1_0.txt>)</td>
+ </tr>
+ </tbody>
+ </table>
+ </td>
+ </tr>
+ </tbody>
+</table>
+</body>
+</html>
Modified: branches/release/libs/polygon/doc/gtl_polygon_45_set_concept.htm
==============================================================================
--- branches/release/libs/polygon/doc/gtl_polygon_45_set_concept.htm (original)
+++ branches/release/libs/polygon/doc/gtl_polygon_45_set_concept.htm 2013-04-15 18:27:46 EDT (Mon, 15 Apr 2013)
@@ -1,758 +1,842 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:(null)1="http://www.w3.org/TR/REC-html40" lang="en"><head>
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"
+ xmlns:v="urn:schemas-microsoft-com:vml"
+ xmlns:o="urn:schemas-microsoft-com:office:office"
+ xmlns:(null)1="http://www.w3.org/TR/REC-html40" lang="en">
+<head>
<!--
Copyright 2009-2010 Intel Corporation
license banner
---><title>Boost Polygon Library: Polygon 45 Set Concept</title>
-
-
-
- <meta http-equiv="content-type" content="text/html;charset=ISO-8859-1" /><!-- <link type="text/css" rel="stylesheet" href="adobe_source.css"> --></head><body><table style="margin: 0pt; padding: 0pt; width: 100%;" border="0" cellpadding="0" cellspacing="0"><tbody><tr>
-<td style="background-color: rgb(238, 238, 238);" nowrap="1" valign="top">
- <div style="padding: 5px;" align="center">
- <img src="images/boost.png" border="0" height="86" width="277" /><a title="www.boost.org home page" href="http://www.boost.org/" tabindex="2" style="border: medium none ;">
- </a>
- </div>
- <div style="margin: 5px;">
- <h3 class="navbar">Contents</h3>
- <ul>
- <li>Boost.Polygon Main Page</li>
- <li>Design Overview</li>
- <li>Isotropy</li>
- <li>Coordinate Concept</li>
- <li>Interval Concept</li>
- <li>Point Concept</li>
+-->
+ <title>Boost Polygon Library: Polygon 45 Set Concept</title>
+ <meta http-equiv="content-type" content="text/html;charset=ISO-8859-1" />
+<!-- <link type="text/css" rel="stylesheet" href="adobe_source.css"> -->
+</head>
+<body>
+<table style="margin: 0pt; padding: 0pt; width: 100%;" border="0"
+ cellpadding="0" cellspacing="0">
+ <tbody>
+ <tr>
+ <td style="background-color: rgb(238, 238, 238);" nowrap="1"
+ valign="top">
+ <div style="padding: 5px;" align="center"> <img
+ src="images/boost.png" border="0" height="86" width="277" /><a
+ title="www.boost.org home page" href="http://www.boost.org/"
+ tabindex="2" style="border: medium none ;"> </a> </div>
+ <div style="margin: 5px;">
+ <h3 class="navbar">Contents</h3>
+ <ul>
+ <li>Boost.Polygon Main Page</li>
+ <li>Design Overview</li>
+ <li>Isotropy</li>
+ <li>Coordinate Concept</li>
+ <li>Interval Concept</li>
+ <li>Point Concept</li>
<li>Segment Concept</li>
-
- <li>Rectangle Concept</li>
- <li>Polygon 90 Concept</li>
- <li>Polygon 90 With Holes Concept</li>
- <li>Polygon 45 Concept</li>
- <li>Polygon 45 With Holes Concept</li>
- <li>Polygon Concept</li>
- <li>Polygon With Holes Concept</li>
- <li>Polygon 90 Set Concept</li>
- <li>Polygon 45 Set Concept</li>
- <li>Polygon Set Concept</li>
- <li>Connectivity Extraction 90</li>
- <li>Connectivity Extraction 45</li>
- <li>Connectivity Extraction</li>
- <li>Property Merge 90</li>
- <li>Property Merge 45</li>
- <li>Property Merge</li>
+ <li>Rectangle Concept</li>
+ <li>Polygon 90 Concept</li>
+ <li><a href="gtl_polygon_90_with_holes_concept.htm">Polygon 90
+With Holes Concept</a></li>
+ <li>Polygon 45 Concept</li>
+ <li><a href="gtl_polygon_45_with_holes_concept.htm">Polygon 45
+With Holes Concept</a></li>
+ <li>Polygon Concept</li>
+ <li><a href="gtl_polygon_with_holes_concept.htm">Polygon With
+Holes Concept</a></li>
+ <li><a href="gtl_polygon_90_set_concept.htm">Polygon 90 Set
+Concept</a></li>
+ <li>Polygon 45 Set Concept</li>
+ <li>Polygon Set Concept</li>
+ <li><a href="gtl_connectivity_extraction_90.htm">Connectivity
+Extraction 90</a></li>
+ <li><a href="gtl_connectivity_extraction_45.htm">Connectivity
+Extraction 45</a></li>
+ <li><a href="gtl_connectivity_extraction.htm">Connectivity
+Extraction</a></li>
+ <li>Property Merge 90</li>
+ <li>Property Merge 45</li>
+ <li>Property Merge</li>
<li><a href="voronoi_main.htm">Voronoi Main Page<br />
-</a></li>
+ </a></li>
<li>Voronoi Benchmark<br />
</li>
<li>Voronoi Builder</li>
- <li><a href="voronoi_diagram.htm">Voronoi Diagram<br />
-</a></li>
- <li>Voronoi Predicates</li>
- <li>Voronoi Robust FPT<br />
- </li>
-
-
- </ul>
- <h3 class="navbar">Other Resources</h3>
- <ul>
+ <li>Voronoi Diagram</li>
+ </ul>
+ <h3 class="navbar">Other Resources</h3>
+ <ul>
<li>GTL Boostcon 2009 Paper</li>
- <li><a href="GTL_boostcon_draft03.pdf">GTL Boostcon 2009
- Presentation</a></li>
+ <li><a href="GTL_boostcon_draft03.pdf">GTL Boostcon 2009
+Presentation</a></li>
<li>Performance Analysis</li>
<li>Layout Versus Schematic Tutorial</li>
<li>Minkowski Sum Tutorial</li>
<li>Voronoi Basic Tutorial</li>
- <li>Voronoi Advanced Tutorial</li>
-</ul>
- </div>
- <h3 class="navbar">Polygon Sponsor</h3>
- <div style="padding: 5px;" align="center">
- <img src="images/intlogo.gif" border="0" height="51" width="127" /><a title="www.adobe.com home page" href="http://www.adobe.com/" tabindex="2" style="border: medium none ;">
- </a>
- </div>
-</td>
-<td style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;" valign="top" width="100%">
-
-<!-- End Header -->
-
-<br />
-<p>
-</p><h1>Polygon 45 Set Concept</h1>
-
-<p>
-</p><p>The polygon_45_set concept tag is <font face="Courier New">
+ <li><a href="voronoi_advanced_tutorial.htm">Voronoi Advanced
+Tutorial</a></li>
+ </ul>
+ </div>
+ <h3 class="navbar">Polygon Sponsor</h3>
+ <div style="padding: 5px;" align="center"> <img
+ src="images/intlogo.gif" border="0" height="51" width="127" /><a
+ title="www.adobe.com home page" href="http://www.adobe.com/"
+ tabindex="2" style="border: medium none ;"> </a> </div>
+ </td>
+ <td
+ style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;"
+ valign="top" width="100%">
+<!-- End Header --><br />
+ <p>
+ </p>
+ <h1>Polygon 45 Set Concept</h1>
+ <p> </p>
+ <p>The polygon_45_set concept tag is <font face="Courier New">
polygon_45_set_concept</font></p>
-<p>
-<font face="Times New Roman">The semantic of a polygon_45_set is zero or more
-geometry regions which have angles at the vertices that are multiples of
-45-degrees relative to the coordinate axis. A Polygon 45 Set Concept makes
-no sense in floating point, but currently does not provide a static assert to
-prevent it from being used with floating point coordinates. The result of
-such use is undefined. When the intersection of two 45 degree edges
-results in a vertex that is off the integer grid that case is handled by
-inserting a unit length edge between the two 45 degree edges near the off grid
-intersection point. In the case that data represented contains no
-45-degree angles and is Manhattan a runtime check will default to the Manhattan
-algorithm. The results of which are identical to what the 45-degree
-algorithm would do, but obtained more efficiently.</font></p><p>
-<font face="Times New Roman">The motivation for providing the polygon_45_set is
-to extend the special case of Manhattan geometry capability of the library to
-encompass the slightly less common, but still important special case of geometry
-that is described by angles that are multiples of 45-degress with respect to the
-coordinate axis. This simplifies the implementation of geometry algorithms
-and affords many opportunities for optimization. 45-degree algorithms can
-be 50X faster than arbitrary angle algorithms and are required to provide a
-complete feature set that meets the performance requirements of application
-domains in which Manhattan and 45-degree geometry are a common special case.</font></p><p>Users are recommended to use std::vector and std::list of user defined polygons
-or library provided polygon_45_set_data<coordinate_type> objects. Lists
-and vectors of models of polygon_45_concept or polygon_45_with_holes_concept are automatically models of polygon_45_set_concept.</p>
-<p>An object that is a model of <font face="Courier New">
-polygon_45_set_concept</font> can be viewed as a model of <font face="Courier New">
-polygon_90_set_concept</font> if it is determined at runtime to conform to the
-restriction that all edges are axis-parallel. This concept casting is
-accomplished through the <font face="Courier New">view_as<>()</font> function.</p>
-<p><font face="Courier New">view_as<polygon_90_set_concept>(polygon_set_object)</font></p>
-<p>The return value of <font face="Courier New">view_as<>()</font> can be passed
-into any interface that expects an object of the conceptual type specified in
-its template parameter. Polygon sets cannot be viewed as single polygons
-or rectangles since it generally cannot be known whether a polygon set contains
-only a single polygon without converting to polygons.</p>
-<h2>Operators</h2>
-<p>The return type of some operators is the <font face="Courier New">polygon_45_set_view</font>
-operator template type. This type is itself a model of the polygon 90 set
-concept, but furthermore can be used as an argument to the <font face="Courier New">polygon_45_set_data</font>
-constructor and assignment operator. The operator template exists to
-eliminate temp copies of intermediate results when Boolean operators are chained
+ <p> <font face="Times New Roman">The semantic of a
+polygon_45_set is zero or more geometry regions which have angles at
+the vertices that are multiples of 45-degrees relative to the
+coordinate axis. A Polygon 45 Set Concept makes no sense in
+floating point, but currently does not provide a static assert to
+prevent it from being used with floating point coordinates. The
+result of such use is undefined. When the intersection of two 45
+degree edges results in a vertex that is off the integer grid that case
+is handled by inserting a unit length edge between the two 45 degree
+edges near the off grid intersection point. In the case that data
+represented contains no 45-degree angles and is Manhattan a runtime
+check will default to the Manhattan algorithm. The results of
+which are identical to what the 45-degree algorithm would do, but
+obtained more efficiently.</font></p>
+ <p> <font face="Times New Roman">The motivation for providing
+the polygon_45_set is to extend the special case of Manhattan geometry
+capability of the library to encompass the slightly less common, but
+still important special case of geometry that is described by angles
+that are multiples of 45-degress with respect to the coordinate
+axis. This simplifies the implementation of geometry algorithms
+and affords many opportunities for optimization. 45-degree
+algorithms can be 50X faster than arbitrary angle algorithms and are
+required to provide a complete feature set that meets the performance
+requirements of application domains in which Manhattan and 45-degree
+geometry are a common special case.</font></p>
+ <p>Users are recommended to use std::vector and std::list of user
+defined polygons or library provided
+polygon_45_set_data<coordinate_type> objects. Lists and
+vectors of models of polygon_45_concept or
+polygon_45_with_holes_concept are automatically models of
+polygon_45_set_concept.</p>
+ <p>An object that is a model of <font face="Courier New">
+polygon_45_set_concept</font> can be viewed as a model of <font
+ face="Courier New">
+polygon_90_set_concept</font> if it is determined at runtime to conform
+to the restriction that all edges are axis-parallel. This concept
+casting is accomplished through the <font face="Courier New">view_as<>()</font>
+function.</p>
+ <p><font face="Courier New">view_as<polygon_90_set_concept>(polygon_set_object)</font></p>
+ <p>The return value of <font face="Courier New">view_as<>()</font>
+can be passed into any interface that expects an object of the
+conceptual type specified in its template parameter. Polygon sets
+cannot be viewed as single polygons or rectangles since it generally
+cannot be known whether a polygon set contains only a single polygon
+without converting to polygons.</p>
+ <h2>Operators</h2>
+ <p>The return type of some operators is the <font
+ face="Courier New">polygon_45_set_view</font> operator template
+type. This type is itself a model of the polygon 90 set concept,
+but furthermore can be used as an argument to the <font
+ face="Courier New">polygon_45_set_data</font> constructor and
+assignment operator. The operator template exists to eliminate
+temp copies of intermediate results when Boolean operators are chained
together.</p>
-<p>Operators are declared inside the namespace <font face="Courier New">boost::polygon::operators</font>.</p>
-<table id="table5" border="1" width="100%">
- <tbody><tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- polygon_45_set_view <b>operator</b>|(const T1& l, const T2& r)</font></td>
- <td>Boolean OR operation (polygon set union). Accepts two objects
- that model polygon_45_set or one of its refinements. Returns an
- operator template that performs the operation on demand when chained or
- or nested in a library function call such as assign(). O( n log n)
- runtime complexity and O(n) memory wrt vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- polygon_45_set_view <b>operator</b>+(const T1& l, const T2& r)</font></td>
- <td>Same as operator|. The plus sign is also used for OR
- operations in Boolean logic expressions. O( n log n) runtime
- complexity and O(n) memory wrt vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- polygon_45_set_view <b>operator</b>&(const T1& l, const T2& r)</font></td>
- <td>Boolean AND operation (polygon set intersection). Accepts two
- objects that model polygon_45_set or one of its refinements. O( n
- log n) runtime complexity and O(n) memory wrt vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- polygon_45_set_view <b>operator</b>*(const T1& l, const T2& r)</font></td>
- <td>Same as operator&. The multiplication symbol is also used for
- AND operations in Boolean logic expressions. O( n log n) runtime
- complexity and O(n) memory wrt vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- polygon_45_set_view <b>operator</b>^(const T1& l, const T2& r)</font></td>
- <td>Boolean XOR operation (polygon set disjoint-union). Accepts
- two objects that model polygon_45_set or one of its refinements.
- O( n log n) runtime complexity and O(n) memory wrt vertices +
- intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- polygon_45_set_view <b>operator</b>-(const T1& l, const T2& r)</font></td>
- <td>Boolean SUBTRACT operation (polygon set difference). Accepts
- two objects that model polygon_45_set or one of its refinements.
- O( n log n) runtime complexity and O(n) memory wrt vertices +
- intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- T1& <b>operator</b>|=(const T1& l, const T2& r)</font></td>
- <td>Same as operator|, but with self assignment, left operand must model
- polygon_45_set and not one of it's refinements. O( n log n)
- runtime complexity and O(n) memory wrt vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- T1& <b>operator</b>+=(T1& l, const T2& r)</font></td>
- <td>Same as operator+, but with self assignment, left operand must model
- polygon_45_set and not one of it's refinements. O( n log n)
- runtime complexity and O(n) memory wrt vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- T1& <b>operator</b>&=(const T1& l, const T2& r)</font></td>
- <td>Same as operator&, but with self assignment, left operand must model
- polygon_45_set and not one of it's refinements. O( n log n)
- runtime complexity and O(n) memory wrt vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- T1& <b>operator</b>*=(T1& l, const T2& r)</font></td>
- <td>Same as operator*, but with self assignment, left operand must model
- polygon_45_set and not one of it's refinements. O( n log n)
- runtime complexity and O(n) memory wrt vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- T1& <b>operator</b>^=(const T1& l, const T2& r)</font></td>
- <td>Same as operator^, but with self assignment, left operand must model
- polygon_45_set and not one of it's refinements. O( n log n)
- runtime complexity and O(n) memory wrt vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- T1& <b>operator</b>-=(T1& l, const T2& r)</font></td>
- <td>Same as operator-, but with self assignment, left operand must model
- polygon_45_set and not one of it's refinements. O( n log n)
- runtime complexity and O(n) memory wrt vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1><br />
- T1 <b>operator</b>+(const T1&, coordinate_type bloating)</font></td>
- <td>Performs resize operation, inflating by bloating ammount. If
- negative the result is a shrink instead of bloat. Note: returns
- result by value. O( n log n) runtime complexity and O(n) memory
- wrt vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- T1 <b>operator</b>-(const T1&, coordinate_type shrinking)</font></td>
- <td>Performs resize operation, deflating by bloating ammount. If
- negative the result is a bloat instead of shrink. Note: returns
- result by value. O( n log n) runtime complexity and O(n) memory
- wrt vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- T1& <b>operator</b>+=(const T1&, coordinate_type bloating)</font></td>
- <td>Performs resize operation, inflating by bloating ammount. If
- negative the result is a shrink instead of bloat. Returns
- reference to modified argument. O( n log n) runtime complexity and
- O(n) memory wrt vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- T1& <b>operator</b>-=(const T1&, coordinate_type shrinking)</font></td>
- <td>Performs resize operation, deflating by bloating ammount. If
- negative the result is a bloat instead of shrink. Returns
- reference to modified argument. O( n log n) runtime complexity and
- O(n) memory wrt vertices + intersections.</td>
- </tr>
- </tbody></table>
-<h2>Functions</h2>
-<table id="table3" border="1" width="100%">
- <tbody><tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- T1& <b>assign</b>(T1& lvalue, const T2& rvalue)</font></td>
- <td>Eliminates overlaps in geometry and copies from an object that
- models polygon_45_set or any of its refinements into an object that
- models polygon_45_set. O( n log n) runtime complexity and O(n)
- memory wrt vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- bool <b>equivalence</b>(const T1& lvalue, const T2& rvalue) </font></td>
- <td>Returns true if an object that models polygon_45_set or one of its
- refinements covers the exact same geometric regions as another object
- that models polygon_45_set or one of its refinements. For example:
- two of polygon_45 objects. O( n log n) runtime complexity and O(n)
- memory wrt vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename
- output_container_type, typename T><br />
- void <b>get_trapezoids</b>(output_container_type& output, <br />
-
- const T& polygon_set)</font></td>
- <td>Output container is expected to be a standard container.
- Slices geometry of an object that models polygon_45_set or one of its
- refinements into non overlapping trapezoids along a vertical slicing
- orientation and appends them to the
- output, which must have a value type that models polygon_45,
- polygon_45_with_holes, polygon or polygon_with_holes. O( n
- log n) runtime complexity and O(n) memory wrt vertices.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename
- output_container_type, typename T><br />
- void <b>get_trapezoids</b>(output_container_type& output, <br />
-
- const T& polygon_set,<br />
+ <p>Operators are declared inside the namespace <font
+ face="Courier New">boost::polygon::operators</font>.</p>
+ <table id="table5" border="1" width="100%">
+ <tbody>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+polygon_45_set_view <b>operator</b>|(const T1& l, const T2& r)</font></td>
+ <td>Boolean OR operation (polygon set union). Accepts
+two objects that model polygon_45_set or one of its refinements.
+Returns an operator template that performs the operation on demand when
+chained or or nested in a library function call such as assign().
+O( n log n) runtime complexity and O(n) memory wrt vertices +
+intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+polygon_45_set_view <b>operator</b>+(const T1& l, const T2& r)</font></td>
+ <td>Same as operator|. The plus sign is also used for
+OR operations in Boolean logic expressions. O( n log n) runtime
+complexity and O(n) memory wrt vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+polygon_45_set_view <b>operator</b>&(const T1& l, const
+T2& r)</font></td>
+ <td>Boolean AND operation (polygon set intersection).
+Accepts two objects that model polygon_45_set or one of its
+refinements. O( n log n) runtime complexity and O(n) memory wrt
+vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+polygon_45_set_view <b>operator</b>*(const T1& l, const T2& r)</font></td>
+ <td>Same as operator&. The multiplication symbol
+is also used for AND operations in Boolean logic expressions. O(
+n log n) runtime complexity and O(n) memory wrt vertices +
+intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+polygon_45_set_view <b>operator</b>^(const T1& l, const T2& r)</font></td>
+ <td>Boolean XOR operation (polygon set
+disjoint-union). Accepts two objects that model polygon_45_set or
+one of its refinements. O( n log n) runtime complexity and O(n)
+memory wrt vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+polygon_45_set_view <b>operator</b>-(const T1& l, const T2& r)</font></td>
+ <td>Boolean SUBTRACT operation (polygon set
+difference). Accepts two objects that model polygon_45_set or one
+of its refinements. O( n log n) runtime complexity and O(n)
+memory wrt vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+T1& <b>operator</b>|=(const T1& l, const T2& r)</font></td>
+ <td>Same as operator|, but with self assignment, left
+operand must model polygon_45_set and not one of it's
+refinements. O( n log n) runtime complexity and O(n) memory wrt
+vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+T1& <b>operator</b>+=(T1& l, const T2& r)</font></td>
+ <td>Same as operator+, but with self assignment, left
+operand must model polygon_45_set and not one of it's
+refinements. O( n log n) runtime complexity and O(n) memory wrt
+vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+T1& <b>operator</b>&=(const T1& l, const T2& r)</font></td>
+ <td>Same as operator&, but with self assignment, left
+operand must model polygon_45_set and not one of it's
+refinements. O( n log n) runtime complexity and O(n) memory wrt
+vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+T1& <b>operator</b>*=(T1& l, const T2& r)</font></td>
+ <td>Same as operator*, but with self assignment, left
+operand must model polygon_45_set and not one of it's
+refinements. O( n log n) runtime complexity and O(n) memory wrt
+vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+T1& <b>operator</b>^=(const T1& l, const T2& r)</font></td>
+ <td>Same as operator^, but with self assignment, left
+operand must model polygon_45_set and not one of it's
+refinements. O( n log n) runtime complexity and O(n) memory wrt
+vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+T1& <b>operator</b>-=(T1& l, const T2& r)</font></td>
+ <td>Same as operator-, but with self assignment, left
+operand must model polygon_45_set and not one of it's
+refinements. O( n log n) runtime complexity and O(n) memory wrt
+vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1><br />
+T1 <b>operator</b>+(const T1&, coordinate_type bloating)</font></td>
+ <td>Performs resize operation, inflating by bloating
+ammount. If negative the result is a shrink instead of
+bloat. Note: returns result by value. O( n log n) runtime
+complexity and O(n) memory wrt vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+T1 <b>operator</b>-(const T1&, coordinate_type shrinking)</font></td>
+ <td>Performs resize operation, deflating by bloating
+ammount. If negative the result is a bloat instead of
+shrink. Note: returns result by value. O( n log n) runtime
+complexity and O(n) memory wrt vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+T1& <b>operator</b>+=(const T1&, coordinate_type bloating)</font></td>
+ <td>Performs resize operation, inflating by bloating
+ammount. If negative the result is a shrink instead of
+bloat. Returns reference to modified argument. O( n log n)
+runtime complexity and O(n) memory wrt vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+T1& <b>operator</b>-=(const T1&, coordinate_type shrinking)</font></td>
+ <td>Performs resize operation, deflating by bloating
+ammount. If negative the result is a bloat instead of
+shrink. Returns reference to modified argument. O( n log n)
+runtime complexity and O(n) memory wrt vertices + intersections.</td>
+ </tr>
+ </tbody>
+ </table>
+ <h2>Functions</h2>
+ <table id="table3" border="1" width="100%">
+ <tbody>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+T1& <b>assign</b>(T1& lvalue, const T2& rvalue)</font></td>
+ <td>Eliminates overlaps in geometry and copies from an
+object that models polygon_45_set or any of its refinements into an
+object that models polygon_45_set. O( n log n) runtime complexity
+and O(n) memory wrt vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+bool <b>equivalence</b>(const T1& lvalue, const T2& rvalue) </font></td>
+ <td>Returns true if an object that models polygon_45_set or
+one of its refinements covers the exact same geometric regions as
+another object that models polygon_45_set or one of its
+refinements. For example: two of polygon_45 objects. O( n
+log n) runtime complexity and O(n) memory wrt vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename output_container_type, typename T><br />
+void <b>get_trapezoids</b>(output_container_type& output, <br />
+
+const T& polygon_set)</font></td>
+ <td>Output container is expected to be a standard
+container. Slices geometry of an object that models
+polygon_45_set or one of its refinements into non overlapping
+trapezoids along a vertical slicing orientation and appends them to the
+output, which must have a value type that models polygon_45,
+polygon_45_with_holes, polygon or polygon_with_holes. O( n
+log n) runtime complexity and O(n) memory wrt vertices.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename output_container_type, typename T><br />
+void <b>get_trapezoids</b>(output_container_type& output, <br />
+
+const T& polygon_set,<br />
orientation_2d orient)</font></td>
- <td>Output container is expected to be a standard container.
- Slices geometry of an object that models polygon_45_set or one of its
- refinements into non overlapping trapezoids along a the specified slicing
- orientation and appends them to the
- output, which must have a value type that models polygon_45,
- polygon_45_with_holes, polygon or polygon_with_holes. O( n
- log n) runtime complexity and O(n) memory wrt vertices.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename
- polygon_set_type><br />
- void <b>clear</b>(polygon_set_type& polygon_set)</font></td>
- <td>Makes the object empty of geometry.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename
- polygon_set_type><br />
- bool <b>empty</b>(const polygon_set_type& polygon_set)</font></td>
- <td>Checks whether the object is empty of geometry. Polygons that
- are completely covered by holes will result in empty returning true.
- O( n log n) runtime complexity and O(n) memory wrt vertices.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T, typename
- rectangle_type><br />
- bool <b>extents</b>(rectangle_type& extents_rectangle, <br />
- const
- T& polygon_set)</font></td>
- <td>Computes bounding box of an object that models polygon_45_set and
- stores it in an object that models rectangle. If the polygon set
- is empty returns false. If there are holes outside of shells they
- do not contribute to the extents of the polygon set. O( n
- log n) runtime complexity and O(n) memory wrt vertices.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- area_type <b>area</b>(const T& polygon_set)</font></td>
- <td>Computes the area covered by geometry in an object that models
- polygon_45_set. O( n log n) runtime complexity and O(n)
- memory wrt vertices.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- T1& <b>interact</b>(T1& a, const T2& b)</font></td>
- <td>Given an object that models polygon_45_set and an object that models
- polygon_45_set or one of its refinements, modifies a to retain only
- regions that overlap or touch regions in b. O( n log n)
- runtime complexity and O(n) memory wrt vertices plus intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- T& <b>self_intersect</b>(T& polygon_set)</font></td>
- <td>Given an object that models polygon_45_set that has self overlapping
- regions, modifies the argument to contain only the regions of overlap.
- O( n log n) runtime complexity and O(n) memory wrt vertices +
- intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- T& <b>self_xor</b>(T& polygon_set)</font></td>
- <td>Given an object that models polygon_45_set that has self overlapping
- regions, modifies the argument to contain only the regions that do not
- overlap. O( n log n) runtime complexity and O(n) memory wrt
- vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- T& <b>bloat</b>(T& polygon_set, unsigned_area_type bloating)</font></td>
- <td>Same as getting all the polygons, bloating them and putting them
- back. O( n log n) runtime complexity and O(n) memory wrt vertices
- + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- T& <b>shrink</b>(T& polygon_set, unsigned_area_type shrinking)</font></td>
- <td>Same as getting all the polygons, shrinking them and overwriting
- the polygon set with the resulting regions. O( n log n) runtime
- complexity and O(n) memory wrt vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T, typename
- coord_type><br />
- T& <b>resize</b>(T& polygon_set, coord_type resizing,<br />
-
- RoundingOption rounding = CLOSEST, <br /> CornerOption corner = INTERSECTION)</font></td>
- <td>Same as bloat if resizing is positive, same as shrink if resizing is
- negative. RoundingOption is an enum that controls snapping of
- non-integer results of resizing 45 degree edges. CornerOption is
- an enum that controls how corner filling is performed.
- polygon_45_set_data.hpp defines these enums. O( n log n) runtime
- complexity and O(n) memory wrt vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
+ <td>Output container is expected to be a standard
+container. Slices geometry of an object that models
+polygon_45_set or one of its refinements into non overlapping
+trapezoids along a the specified slicing orientation and appends them
+to the output, which must have a value type that models polygon_45,
+polygon_45_with_holes, polygon or polygon_with_holes. O( n
+log n) runtime complexity and O(n) memory wrt vertices.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename polygon_set_type><br />
+void <b>clear</b>(polygon_set_type& polygon_set)</font></td>
+ <td>Makes the object empty of geometry.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename polygon_set_type><br />
+bool <b>empty</b>(const polygon_set_type& polygon_set)</font></td>
+ <td>Checks whether the object is empty of geometry.
+Polygons that are completely covered by holes will result in empty
+returning true. O( n log n) runtime complexity and O(n)
+memory wrt vertices.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename rectangle_type><br />
+bool <b>extents</b>(rectangle_type& extents_rectangle, <br />
+
+const T& polygon_set)</font></td>
+ <td>Computes bounding box of an object that models
+polygon_45_set and stores it in an object that models rectangle.
+If the polygon set is empty returns false. If there are holes
+outside of shells they do not contribute to the extents of the polygon
+set. O( n log n) runtime complexity and O(n) memory wrt
+vertices.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+area_type <b>area</b>(const T& polygon_set)</font></td>
+ <td>Computes the area covered by geometry in an object that
+models polygon_45_set. O( n log n) runtime complexity and
+O(n) memory wrt vertices.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+T1& <b>interact</b>(T1& a, const T2& b)</font></td>
+ <td>Given an object that models polygon_45_set and an
+object that models polygon_45_set or one of its refinements, modifies a
+to retain only regions that overlap or touch regions in b.
+O( n log n) runtime complexity and O(n) memory wrt vertices plus
+intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+T& <b>self_intersect</b>(T& polygon_set)</font></td>
+ <td>Given an object that models polygon_45_set that has
+self overlapping regions, modifies the argument to contain only the
+regions of overlap. O( n log n) runtime complexity and O(n)
+memory wrt vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+T& <b>self_xor</b>(T& polygon_set)</font></td>
+ <td>Given an object that models polygon_45_set that has
+self overlapping regions, modifies the argument to contain only the
+regions that do not overlap. O( n log n) runtime complexity and
+O(n) memory wrt vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+T& <b>bloat</b>(T& polygon_set, unsigned_area_type bloating)</font></td>
+ <td>Same as getting all the polygons, bloating them and
+putting them back. O( n log n) runtime complexity and O(n) memory
+wrt vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+T& <b>shrink</b>(T& polygon_set, unsigned_area_type shrinking)</font></td>
+ <td>Same as getting all the polygons, shrinking them and
+overwriting the polygon set with the resulting regions. O( n log
+n) runtime complexity and O(n) memory wrt vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename coord_type><br />
+T& <b>resize</b>(T& polygon_set, coord_type resizing,<br />
+ RoundingOption
+rounding = CLOSEST, <br />
+ CornerOption
+corner = INTERSECTION)</font></td>
+ <td>Same as bloat if resizing is positive, same as shrink
+if resizing is negative. RoundingOption is an enum that controls
+snapping of non-integer results of resizing 45 degree edges.
+CornerOption is an enum that controls how corner filling is
+performed. polygon_45_set_data.hpp defines these enums. O(
+n log n) runtime complexity and O(n) memory wrt vertices +
+intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
T& <b>grow_and</b>(T& polygon_set, unsigned_area_type bloating)</font></td>
- <td>Same as bloating non-overlapping regions and then applying self
- intersect to retain only the overlaps introduced by the bloat. O(
- n log n) runtime complexity and O(n) memory wrt vertices +
- intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
+ <td>Same as bloating non-overlapping regions and then
+applying self intersect to retain only the overlaps introduced by the
+bloat. O( n log n) runtime complexity and O(n) memory wrt
+vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
T& <b>scale_up</b>(T& polygon_set, unsigned_area_type factor)</font></td>
- <td>Scales geometry up by unsigned factor. O( n log n) runtime
- complexity and O(n) memory wrt vertices.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
+ <td>Scales geometry up by unsigned factor. O( n log
+n) runtime complexity and O(n) memory wrt vertices.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
T& <b>scale_down</b>(T& polygon_set, unsigned_area_type factor)</font></td>
- <td>Scales geometry down by unsigned factor. Snaps 45 degree edges
- back to 45 degrees after division truncation leads to small changes in
- angle. O( n log n) runtime complexity and O(n) memory wrt
- vertices.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T, typename scaling_type><br />
+ <td>Scales geometry down by unsigned factor. Snaps 45
+degree edges back to 45 degrees after division truncation leads to
+small changes in angle. O( n log n) runtime complexity and O(n)
+memory wrt vertices.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename scaling_type><br />
T& <b>scale</b>(polygon_set_type& polygon_set, double scaling)</font></td>
- <td>Scales geometry by multiplying by floating point factor.
- Snaps 45 degree edges back to 45 degrees after truncation of fractional
- results of multiply leads to small changes in angle. O( n log n)
- runtime complexity and O(n) memory wrt vertices.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T, typename transformation_type><br />
+ <td>Scales geometry by multiplying by floating point
+factor. Snaps 45 degree edges back to 45 degrees after
+truncation of fractional results of multiply leads to small changes in
+angle. O( n log n) runtime complexity and O(n) memory wrt
+vertices.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename transformation_type><br />
T& <b>transform</b>(T& polygon_set,<br />
- const
-transformation_type& transformation)</font></td>
- <td>Applies transformation.transform() on all vertices. O( n log
- n) runtime complexity and O(n) memory wrt vertices.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
+
+const transformation_type& transformation)</font></td>
+ <td>Applies transformation.transform() on all
+vertices. O( n log n) runtime complexity and O(n) memory wrt
+vertices.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
T& <b>keep</b>(T& polygon_set, <br />
unsigned_area_type min_area,<br />
unsigned_area_type max_area,<br />
unsigned_area_type min_width,<br />
unsigned_area_type max_width,<br />
- unsigned_area_type min_height,<br />
- unsigned_area_type max_height)</font></td>
- <td>Retains only regions that satisfy the min/max criteria in the
- argument list. Note: useful for visualization to cull too small
- polygons. O( n log n) runtime complexity and O(n) memory wrt
- vertices.</td>
- </tr>
- </tbody></table>
- <h1>Polygon 45 Set Data Object</h1>
-
-<p>
-</p><p>The polygon 45 set data type encapsulates the internal data format that
-serves as the input to the sweep-line algorithm that implements polygon-clipping
-Boolean operations. It also internally keeps track of whether that data
-has been sorted or scanned and maintains the invariant that when its flags
-indicate that the data is sorted or scanned the data has not been changed to
-violate that assumption. Using the Polygon 45 Set Data type directly can
-be more efficient than using lists and vectors of polygons in the functions
-above because of the invariants it can enforce which provide the opportunity to
-maintain the data is sorted form rather than going all the way out to polygons
-then resorting those vertices for a subsequent operation.</p>
-<p>The declaration of Polygon 45 Set Data is the following:</p>
-<p><font face="Courier New">template <typename T><br />
+ unsigned_area_type
+min_height,<br />
+ unsigned_area_type
+max_height)</font></td>
+ <td>Retains only regions that satisfy the min/max criteria
+in the argument list. Note: useful for visualization to cull too
+small polygons. O( n log n) runtime complexity and O(n) memory
+wrt vertices.</td>
+ </tr>
+ </tbody>
+ </table>
+ <h1>Polygon 45 Set Data Object</h1>
+ <p> </p>
+ <p>The polygon 45 set data type encapsulates the internal data
+format that serves as the input to the sweep-line algorithm that
+implements polygon-clipping Boolean operations. It also
+internally keeps track of whether that data has been sorted or scanned
+and maintains the invariant that when its flags indicate that the data
+is sorted or scanned the data has not been changed to violate that
+assumption. Using the Polygon 45 Set Data type directly can be
+more efficient than using lists and vectors of polygons in the
+functions above because of the invariants it can enforce which provide
+the opportunity to maintain the data is sorted form rather than going
+all the way out to polygons then resorting those vertices for a
+subsequent operation.</p>
+ <p>The declaration of Polygon 45 Set Data is the following:</p>
+ <p><font face="Courier New">template <typename T><br />
class polygon_45_set_data;</font></p>
-<p>The class is parameterized on the coordinate data type. Algorithms that
-benefit from knowledge of the invariants enforced by the class are implemented
-as member functions to provide them access to information about those
-invariants. </p>
-<h2>Member Functions</h2>
-<table id="table4" border="1" width="100%">
- <tbody><tr>
- <td width="586"><font face="Courier New"><b>polygon_45_set_data</b>()</font></td>
- <td>Default constructor. </td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename iT><br />
- <b>polygon_45_set_data</b>(iT input_begin, iT
- input_end)</font></td>
- <td>Construct from an iterator range of
- insertable objects.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">
- <b>polygon_45_set_data</b>(const polygon_45_set_data& that)</font></td>
- <td>Copy construct.</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">template <typename l, typename r, typename op><br />
-<b>polygon_45_set_data</b>(const polygon_45_set_view<l,r,op>&
-t)</font></td>
- <td>Copy construct from a Boolean operator template.</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">polygon_45_set_data& <br /><b>operator=</b>(const polygon_45_set_data& that)</font></td>
- <td>Assignment from another polygon set, may change scanning
- orientation.</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">template <typename l, typename r, typename op><br />
-polygon_45_set_data& <br /><b>operator=</b>(const polygon_45_set_view<l, r,
+ <p>The class is parameterized on the coordinate data type.
+Algorithms that benefit from knowledge of the invariants enforced by
+the class are implemented as member functions to provide them access to
+information about those invariants. </p>
+ <h2>Member Functions</h2>
+ <table id="table4" border="1" width="100%">
+ <tbody>
+ <tr>
+ <td width="586"><font face="Courier New"><b>polygon_45_set_data</b>()</font></td>
+ <td>Default constructor. </td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename iT><br />
+ <b>polygon_45_set_data</b>(iT input_begin, iT input_end)</font></td>
+ <td>Construct from an iterator range of insertable objects.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New"> <b>polygon_45_set_data</b>(const
+polygon_45_set_data& that)</font></td>
+ <td>Copy construct.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename l, typename r, typename op><br />
+ <b>polygon_45_set_data</b>(const
+polygon_45_set_view<l,r,op>& t)</font></td>
+ <td>Copy construct from a Boolean operator template.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">polygon_45_set_data&
+ <br />
+ <b>operator=</b>(const polygon_45_set_data& that)</font></td>
+ <td>Assignment from another polygon set, may change
+scanning orientation.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename l, typename r, typename op><br />
+polygon_45_set_data& <br />
+ <b>operator=</b>(const polygon_45_set_view<l, r,
op>& that)</font></td>
- <td>Assignment from a Boolean operator template.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename geometry_object><br />
-polygon_45_set_data& <b>operator=</b>(const geometry_object& geo)</font></td>
- <td>Assignment from an insertable object.</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">
+ <td>Assignment from a Boolean operator template.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename geometry_object><br />
+polygon_45_set_data& <b>operator=</b>(const geometry_object&
+geo)</font></td>
+ <td>Assignment from an insertable object.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">
template <typename iT><br />
-void <b>insert</b>(iT input_begin, iT input_end, <br /> bool is_hole = false)</font></td>
- <td>Insert objects of an iterator range. If is_hole is true
- inserts subtractive regions. Linear wrt the number of vertices
- added.</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">
-void <b>insert</b>(const polygon_45_set_data& polygon_set, <br /> bool is_hole
-= false)</font></td>
- <td>Insert a polygon set. Linear wrt the number of vertices added.</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">
+void <b>insert</b>(iT input_begin, iT input_end, <br />
+ bool
+is_hole = false)</font></td>
+ <td>Insert objects of an iterator range. If is_hole
+is true inserts subtractive regions. Linear wrt the number of
+vertices added.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">
+void <b>insert</b>(const polygon_45_set_data& polygon_set, <br />
+ bool
+is_hole = false)</font></td>
+ <td>Insert a polygon set. Linear wrt the number of
+vertices added.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">
template <typename geometry_type><br />
-void <b>insert</b>(const geometry_type& geometry_object, <br /> bool is_hole
-= false)</font></td>
- <td>Insert a geometry object, if is_hole is true then the inserted
- region is subtractive rather than additive. Linear wrt the number
- of vertices added.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">
-template <typename output_container><br />
+void <b>insert</b>(const geometry_type& geometry_object, <br />
+ bool
+is_hole = false)</font></td>
+ <td>Insert a geometry object, if is_hole is true then the
+inserted region is subtractive rather than additive. Linear wrt
+the number of vertices added.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename output_container><br />
void <b>get</b>(output_container& output) const</font></td>
- <td>Expects a standard container of geometry objects. Will scan
- and eliminate overlaps. Converts polygon set geometry to objects
- of that type and appends them to the container. Polygons will be
- output with counterclockwise winding, hole polygons will be output with
- clockwise winding. The last vertex of an output polygon is not the
- duplicate of the first, and the number of points is equal to the number
- of edges. O(n log n) runtime and O(n) memory wrt. vertices +
- intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">
-template <typename output_container><br />
+ <td>Expects a standard container of geometry objects.
+Will scan and eliminate overlaps. Converts polygon set geometry
+to objects of that type and appends them to the container.
+Polygons will be output with counterclockwise winding, hole polygons
+will be output with clockwise winding. The last vertex of an
+output polygon is not the duplicate of the first, and the number of
+points is equal to the number of edges. O(n log n) runtime and
+O(n) memory wrt. vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename output_container><br />
void <b>get_polygons</b>(output_container& output) const</font></td>
- <td>Expects a standard container of polygon objects. Will scan and
- eliminate overlaps. Converts polygon set geometry to polygons and
- appends them to the container. Polygons will have holes fractured
- out to the outer boundary along the positive y direction. O(n log
- n) runtime and O(n) memory wrt. vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">
-template <typename output_container><br />
+ <td>Expects a standard container of polygon objects.
+Will scan and eliminate overlaps. Converts polygon set geometry
+to polygons and appends them to the container. Polygons will have
+holes fractured out to the outer boundary along the positive y
+direction. O(n log n) runtime and O(n) memory wrt. vertices +
+intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename output_container><br />
void <b>get_polygons_with_holes</b>(output_container& o) const</font></td>
- <td>Expects a standard container of polygon with holes objects. Will scan and
- eliminate overlaps. Converts polygon set geometry to polygons and
- appends them to the container. O(n log n) runtime and O(n) memory
- wrt. vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">
-template <typename output_container><br />
+ <td>Expects a standard container of polygon with holes
+objects. Will scan and eliminate overlaps. Converts polygon
+set geometry to polygons and appends them to the container. O(n
+log n) runtime and O(n) memory wrt. vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename output_container><br />
void <b>get_trapezoids</b>(output_container& output) const</font></td>
- <td>Expects a standard container of polygon objects. Will scan
- and eliminate overlaps. Slices polygon set geometry to trapezoids
- vertically and appends them to the container. O(n log n) runtime
- and O(n) memory wrt. vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">
+ <td>Expects a standard container of polygon objects.
+Will scan and eliminate overlaps. Slices polygon set geometry to
+trapezoids vertically and appends them to the container. O(n log
+n) runtime and O(n) memory wrt. vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">
template <typename output_container><br />
-void <b>get_trapezoids</b>(output_container& output, <br /> orientation_2d
-slicing_orientation) const </font>
- </td>
- <td>Expects a standard container of polygon objects. Will scan
- and eliminate overlaps. Slices polygon set geometry to trapezoids
- along the given orientation and appends them to the container. O(n
- log n) runtime and O(n) memory wrt. vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">
+void <b>get_trapezoids</b>(output_container& output, <br />
+ orientation_2d slicing_orientation) const </font> </td>
+ <td>Expects a standard container of polygon objects.
+Will scan and eliminate overlaps. Slices polygon set geometry to
+trapezoids along the given orientation and appends them to the
+container. O(n log n) runtime and O(n) memory wrt. vertices +
+intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">
bool <b>operator==</b>(const polygon_45_set_data& p) const</font></td>
- <td>Once scanned the data representation of geometry within a polygon
- set is in a mathematically canonical form. Comparison between two
- sets is therefore a linear time operation once they are in the scanned
- state. Will scan and eliminate overlaps in both polygon sets. O(n
- log n) runtime and O(n) memory wrt. vertices + intersections the first
- time and linear runtime and constant memory subsequently. </td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">
-bool <b>operator!=</b>(const polygon_45_set_data& p) const</font></td>
- <td>Inverse logic of equivalence operator.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">void <b>clear</b>()</font></td>
- <td>Make the polygon set empty. Note: does not de-allocate memory.
- Use shrink to fit idiom and assign default constructed polygon set to
- de-allocate.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">bool <b>empty</b>() const </font>
- </td>
- <td>Check whether the polygon set contains no geometry. Will scan
- and eliminate overlaps because subtractive regions might make the
- polygon set empty. O(n log n) runtime and O(n) memory wrt.
- vertices + intersections the first time and linear runtime and constant
- memory subsequently. </td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">bool <b>is_manhattan</b>()
- const</font></td>
- <td>Returns in constant time the information about whether the geometry
- contains only Manhattan (axis-parallel rectilinear) edges.
- Constant time.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">void <b>clean</b>() const</font></td>
- <td>Scan and eliminate overlaps. O(n log n) runtime and O(n)
- memory wrt. vertices + intersections the first time and linear runtime
- and constant memory subsequently. </td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">
-template <typename input_iterator_type><br />
-void <b>set</b>(input_iterator_type input_begin, <br /> input_iterator_type input_end) </font>
- </td>
- <td>Overwrite geometry in polygon set with insertable objects in the
- iterator range. </td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">
-template <typename rectangle_type><br />
+ <td>Once scanned the data representation of geometry within
+a polygon set is in a mathematically canonical form. Comparison
+between two sets is therefore a linear time operation once they are in
+the scanned state. Will scan and eliminate overlaps in both polygon
+sets. O(n log n) runtime and O(n) memory wrt. vertices +
+intersections the first time and linear runtime and constant memory
+subsequently. </td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">bool <b>operator!=</b>(const
+polygon_45_set_data& p) const</font></td>
+ <td>Inverse logic of equivalence operator.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">void <b>clear</b>()</font></td>
+ <td>Make the polygon set empty. Note: does not
+de-allocate memory. Use shrink to fit idiom and assign default
+constructed polygon set to de-allocate.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">bool <b>empty</b>()
+const </font> </td>
+ <td>Check whether the polygon set contains no
+geometry. Will scan and eliminate overlaps because subtractive
+regions might make the polygon set empty. O(n log n) runtime and
+O(n) memory wrt. vertices + intersections the first time and linear
+runtime and constant memory subsequently. </td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">bool <b>is_manhattan</b>()
+const</font></td>
+ <td>Returns in constant time the information about whether
+the geometry contains only Manhattan (axis-parallel rectilinear)
+edges. Constant time.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">void <b>clean</b>()
+const</font></td>
+ <td>Scan and eliminate overlaps. O(n log n) runtime
+and O(n) memory wrt. vertices + intersections the first time and linear
+runtime and constant memory subsequently. </td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename input_iterator_type><br />
+void <b>set</b>(input_iterator_type input_begin, <br />
+ input_iterator_type
+input_end) </font> </td>
+ <td>Overwrite geometry in polygon set with insertable
+objects in the iterator range. </td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename rectangle_type><br />
bool <b>extents</b>(rectangle_type& extents_rectangle) const</font></td>
- <td>Given an object that models rectangle, scans and eliminates overlaps
- in the polygon set because subtractive regions may alter its extents
- then computes the bounding box and assigns it to extents_rectangle.
- O(n log n) runtime and O(n) memory wrt. vertices the first time and
- linear runtime and constant memory subsequently. </td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">
-polygon_45_set_data&<br />
-<b>resize</b>(coord_type resizing,<br />
- RoundingOption rounding = CLOSEST, <br /> CornerOption
- corner = INTERSECTION)</font></td>
- <td>Same as bloat if resizing is positive, same as shrink if resizing is
- negative. RoundingOption is an enum that controls snapping of
- non-integer results of resizing 45 degree edges. CornerOption is
- an enum that controls how corner filling is performed.
- polygon_45_set_data.hpp defines these enums. O(n log n) runtime
- and O(n) memory wrt. vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">
-template <typename transformation_type><br />
-polygon_45_set_data& <br /><b>transform</b>(const transformation_type& transformation) </font>
- </td>
- <td>Applies transformation.transform() on vertices stored within the
- polygon set. O(n log n) runtime and O(n) memory wrt. vertices +
- intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">
-polygon_45_set_data& <b>scale_up</b>(unsigned_area_type factor)</font></td>
- <td>Scales vertices stored within the polygon set up by factor.
- Linear wrt vertices.</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">polygon_45_set_data& <b>scale_down</b>(unsigned_area_type
-factor)</font> </td>
- <td>Scales vertices stored within the polygon set down by factor.
- Linear wrt vertices.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">polygon_45_set_data& <b>scale</b>(double factor) </font></td>
- <td>Scales vertices stored within the polygon set by floating point
- factor. Linear wrt vertices.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">polygon_45_set_data& <b>self_xor</b>()</font></td>
- <td>Retain only non-overlapping regions of geometry within polygon set.
- O(n log n) runtime and O(n) memory wrt. vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">polygon_45_set_data& <b>self_intersect</b>()</font></td>
- <td>Retain only overlapping regions of geometry within a polygon set.
- O(n log n) runtime and O(n) memory wrt. vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">bool <b>has_error_data</b>()
- const </font></td>
- <td>Returns true if non-integer intersections resulted in small
- artifacts in the output of a boolean. Constant time.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">std::size_t <b>error_count</b>()
- const</font></td>
- <td>Returns the number of artifacts that may potentially be present in
- the output due to non-integer intersections. Constant time.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">void <b>get_error_data</b>(polygon_45_set_data&
- p) const</font></td>
- <td>Populates the input polygon set with 1x1 unit squares that bound the
- error that may be present in the output due to non-integer
- intersections. Linear wrt. vertices of error data.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">polygon_45_set_data& <b>self_intersect</b>()</font></td>
- <td>Retain only overlapping regions of geometry within a polygon set.
- O(n log n) runtime and O(n) memory wrt. vertices + intersections.</td>
- </tr>
- </tbody></table>
- </td></tr><tr>
-<td style="background-color: rgb(238, 238, 238);" nowrap="1" valign="top">
- </td>
-<td style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;" valign="top" width="100%">
-
-
-<table class="docinfo" id="table6" frame="void" rules="none">
- <colgroup>
- <col class="docinfo-name" /><col class="docinfo-content" />
- </colgroup>
- <tbody valign="top">
- <tr>
- <th class="docinfo-name">Copyright:</th>
- <td>Copyright © Intel Corporation 2008-2010.</td>
- </tr>
- <tr class="field">
- <th class="docinfo-name">License:</th>
- <td class="field-body">Distributed under the Boost Software License,
- Version 1.0. (See accompanying file <tt class="literal">
- <span class="pre">LICENSE_1_0.txt</span></tt> or copy at
- <a class="reference" target="_top" href="http://www.boost.org/LICENSE_1_0.txt">
- http://www.boost.org/LICENSE_1_0.txt>)</td>
- </tr>
-</tbody></table>
-
-</td></tr></tbody></table></body></html>
\ No newline at end of file
+ <td>Given an object that models rectangle, scans and
+eliminates overlaps in the polygon set because subtractive regions may
+alter its extents then computes the bounding box and assigns it to
+extents_rectangle. O(n log n) runtime and O(n) memory wrt.
+vertices the first time and linear runtime and constant memory
+subsequently. </td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">polygon_45_set_data&<br />
+ <b>resize</b>(coord_type resizing,<br />
+ RoundingOption rounding = CLOSEST,
+ <br />
+ CornerOption corner = INTERSECTION)</font></td>
+ <td>Same as bloat if resizing is positive, same as shrink
+if resizing is negative. RoundingOption is an enum that controls
+snapping of non-integer results of resizing 45 degree edges.
+CornerOption is an enum that controls how corner filling is
+performed. polygon_45_set_data.hpp defines these enums. O(n
+log n) runtime and O(n) memory wrt. vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename transformation_type><br />
+polygon_45_set_data& <br />
+ <b>transform</b>(const transformation_type&
+transformation) </font> </td>
+ <td>Applies transformation.transform() on vertices stored
+within the polygon set. O(n log n) runtime and O(n) memory wrt.
+vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">polygon_45_set_data&
+ <b>scale_up</b>(unsigned_area_type factor)</font></td>
+ <td>Scales vertices stored within the polygon set up by
+factor. Linear wrt vertices.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">polygon_45_set_data&
+ <b>scale_down</b>(unsigned_area_type factor)</font> </td>
+ <td>Scales vertices stored within the polygon set down by
+factor. Linear wrt vertices.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">polygon_45_set_data&
+ <b>scale</b>(double factor) </font></td>
+ <td>Scales vertices stored within the polygon set by
+floating point factor. Linear wrt vertices.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">polygon_45_set_data&
+ <b>self_xor</b>()</font></td>
+ <td>Retain only non-overlapping regions of geometry within
+polygon set. O(n log n) runtime and O(n) memory wrt. vertices +
+intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">polygon_45_set_data&
+ <b>self_intersect</b>()</font></td>
+ <td>Retain only overlapping regions of geometry within a
+polygon set. O(n log n) runtime and O(n) memory wrt. vertices +
+intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">bool <b>has_error_data</b>()
+const </font></td>
+ <td>Returns true if non-integer intersections resulted in
+small artifacts in the output of a boolean. Constant time.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">std::size_t <b>error_count</b>()
+const</font></td>
+ <td>Returns the number of artifacts that may potentially be
+present in the output due to non-integer intersections. Constant
+time.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">void <b>get_error_data</b>(polygon_45_set_data&
+p) const</font></td>
+ <td>Populates the input polygon set with 1x1 unit squares
+that bound the error that may be present in the output due to
+non-integer intersections. Linear wrt. vertices of error data.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">polygon_45_set_data&
+ <b>self_intersect</b>()</font></td>
+ <td>Retain only overlapping regions of geometry within a
+polygon set. O(n log n) runtime and O(n) memory wrt. vertices +
+intersections.</td>
+ </tr>
+ </tbody>
+ </table>
+ </td>
+ </tr>
+ <tr>
+ <td style="background-color: rgb(238, 238, 238);" nowrap="1"
+ valign="top"> </td>
+ <td
+ style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;"
+ valign="top" width="100%">
+ <table class="docinfo" id="table6" frame="void" rules="none">
+ <colgroup> <col class="docinfo-name" /><col
+ class="docinfo-content" /> </colgroup> <tbody valign="top">
+ <tr>
+ <th class="docinfo-name">Copyright:</th>
+ <td>Copyright © Intel Corporation 2008-2010.</td>
+ </tr>
+ <tr class="field">
+ <th class="docinfo-name">License:</th>
+ <td class="field-body">Distributed under the Boost Software
+License, Version 1.0. (See accompanying file <tt class="literal"> <span
+ class="pre">LICENSE_1_0.txt</span></tt> or copy at <a
+ class="reference" target="_top"
+ href="http://www.boost.org/LICENSE_1_0.txt">
+http://www.boost.org/LICENSE_1_0.txt>)</td>
+ </tr>
+ </tbody>
+ </table>
+ </td>
+ </tr>
+ </tbody>
+</table>
+</body>
+</html>
Modified: branches/release/libs/polygon/doc/gtl_polygon_45_with_holes_concept.htm
==============================================================================
--- branches/release/libs/polygon/doc/gtl_polygon_45_with_holes_concept.htm (original)
+++ branches/release/libs/polygon/doc/gtl_polygon_45_with_holes_concept.htm 2013-04-15 18:27:46 EDT (Mon, 15 Apr 2013)
@@ -1,415 +1,461 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:(null)1="http://www.w3.org/TR/REC-html40" lang="en"><head>
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"
+ xmlns:v="urn:schemas-microsoft-com:vml"
+ xmlns:o="urn:schemas-microsoft-com:office:office"
+ xmlns:(null)1="http://www.w3.org/TR/REC-html40" lang="en">
+<head>
<!--
Copyright 2009-2010 Intel Corporation
license banner
---><title>Boost Polygon Library: Polygon 45 With Holes Concept</title>
-
-
-
- <meta http-equiv="content-type" content="text/html;charset=ISO-8859-1" /><!-- <link type="text/css" rel="stylesheet" href="adobe_source.css"> --></head><body><table style="margin: 0pt; padding: 0pt; width: 100%;" border="0" cellpadding="0" cellspacing="0"><tbody><tr>
-<td style="background-color: rgb(238, 238, 238);" nowrap="1" valign="top">
- <div style="padding: 5px;" align="center">
- <img src="images/boost.png" border="0" height="86" width="277" /><a title="www.boost.org home page" href="http://www.boost.org/" tabindex="2" style="border: medium none ;">
- </a>
- </div>
- <div style="margin: 5px;">
- <h3 class="navbar">Contents</h3>
- <ul>
- <li>Boost.Polygon Main Page</li>
- <li>Design Overview</li>
- <li>Isotropy</li>
- <li>Coordinate Concept</li>
- <li>Interval Concept</li>
- <li>Point Concept</li>
+-->
+ <title>Boost Polygon Library: Polygon 45 With Holes Concept</title>
+ <meta http-equiv="content-type" content="text/html;charset=ISO-8859-1" />
+<!-- <link type="text/css" rel="stylesheet" href="adobe_source.css"> -->
+</head>
+<body>
+<table style="margin: 0pt; padding: 0pt; width: 100%;" border="0"
+ cellpadding="0" cellspacing="0">
+ <tbody>
+ <tr>
+ <td style="background-color: rgb(238, 238, 238);" nowrap="1"
+ valign="top">
+ <div style="padding: 5px;" align="center"> <img
+ src="images/boost.png" border="0" height="86" width="277" /><a
+ title="www.boost.org home page" href="http://www.boost.org/"
+ tabindex="2" style="border: medium none ;"> </a> </div>
+ <div style="margin: 5px;">
+ <h3 class="navbar">Contents</h3>
+ <ul>
+ <li>Boost.Polygon Main Page</li>
+ <li>Design Overview</li>
+ <li>Isotropy</li>
+ <li>Coordinate Concept</li>
+ <li>Interval Concept</li>
+ <li>Point Concept</li>
<li>Segment Concept</li>
-
- <li>Rectangle Concept</li>
- <li>Polygon 90 Concept</li>
- <li>Polygon 90 With Holes Concept</li>
- <li>Polygon 45 Concept</li>
- <li>Polygon 45 With Holes Concept</li>
- <li>Polygon Concept</li>
- <li>Polygon With Holes Concept</li>
- <li>Polygon 90 Set Concept</li>
- <li>Polygon 45 Set Concept</li>
- <li>Polygon Set Concept</li>
- <li>Connectivity Extraction 90</li>
- <li>Connectivity Extraction 45</li>
- <li>Connectivity Extraction</li>
- <li>Property Merge 90</li>
- <li>Property Merge 45</li>
- <li>Property Merge</li>
+ <li>Rectangle Concept</li>
+ <li>Polygon 90 Concept</li>
+ <li><a href="gtl_polygon_90_with_holes_concept.htm">Polygon 90
+With Holes Concept</a></li>
+ <li>Polygon 45 Concept</li>
+ <li>Polygon 45 With Holes Concept</li>
+ <li>Polygon Concept</li>
+ <li><a href="gtl_polygon_with_holes_concept.htm">Polygon With
+Holes Concept</a></li>
+ <li><a href="gtl_polygon_90_set_concept.htm">Polygon 90 Set
+Concept</a></li>
+ <li><a href="gtl_polygon_45_set_concept.htm">Polygon 45 Set
+Concept</a></li>
+ <li>Polygon Set Concept</li>
+ <li><a href="gtl_connectivity_extraction_90.htm">Connectivity
+Extraction 90</a></li>
+ <li><a href="gtl_connectivity_extraction_45.htm">Connectivity
+Extraction 45</a></li>
+ <li><a href="gtl_connectivity_extraction.htm">Connectivity
+Extraction</a></li>
+ <li>Property Merge 90</li>
+ <li>Property Merge 45</li>
+ <li>Property Merge</li>
<li><a href="voronoi_main.htm">Voronoi Main Page<br />
-</a></li>
+ </a></li>
<li>Voronoi Benchmark<br />
</li>
<li>Voronoi Builder</li>
- <li><a href="voronoi_diagram.htm">Voronoi Diagram<br />
-</a></li>
- <li>Voronoi Predicates</li>
- <li>Voronoi Robust FPT<br />
- </li>
-
-
- </ul>
- <h3 class="navbar">Other Resources</h3>
- <ul>
+ <li>Voronoi Diagram</li>
+ </ul>
+ <h3 class="navbar">Other Resources</h3>
+ <ul>
<li>GTL Boostcon 2009 Paper</li>
- <li><a href="GTL_boostcon_draft03.pdf">GTL Boostcon 2009
- Presentation</a></li>
+ <li><a href="GTL_boostcon_draft03.pdf">GTL Boostcon 2009
+Presentation</a></li>
<li>Performance Analysis</li>
<li>Layout Versus Schematic Tutorial</li>
<li>Minkowski Sum Tutorial</li>
<li>Voronoi Basic Tutorial</li>
- <li>Voronoi Advanced Tutorial</li>
-</ul>
- </div>
- <h3 class="navbar">Polygon Sponsor</h3>
- <div style="padding: 5px;" align="center">
- <img src="images/intlogo.gif" border="0" height="51" width="127" /><a title="www.adobe.com home page" href="http://www.adobe.com/" tabindex="2" style="border: medium none ;">
- </a>
- </div>
-</td>
-<td style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;" valign="top" width="100%">
-
-<!-- End Header -->
-
-<br />
-<p>
-</p><h1>Polygon 45 With Holes Concept</h1>
-
-<p>
-</p><p>The polygon_45_with_holes concept tag is <font face="Courier New">
+ <li><a href="voronoi_advanced_tutorial.htm">Voronoi Advanced
+Tutorial</a></li>
+ </ul>
+ </div>
+ <h3 class="navbar">Polygon Sponsor</h3>
+ <div style="padding: 5px;" align="center"> <img
+ src="images/intlogo.gif" border="0" height="51" width="127" /><a
+ title="www.adobe.com home page" href="http://www.adobe.com/"
+ tabindex="2" style="border: medium none ;"> </a> </div>
+ </td>
+ <td
+ style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;"
+ valign="top" width="100%">
+<!-- End Header --><br />
+ <p>
+ </p>
+ <h1>Polygon 45 With Holes Concept</h1>
+ <p> </p>
+ <p>The polygon_45_with_holes concept tag is <font
+ face="Courier New">
polygon_45_with_holes_concept</font></p>
-<p>
-To register a user defined type as a model of
-<font face="Times New Roman">polygon_45_with_holes </font>concept, specialize
-the geometry concept meta-function for that type. In the example below
-CPolygon45WithHoles is registered as a model of polygon<font face="Times New Roman">_45_with_holes </font> concept.</p><p>
-<font face="Courier New">template <><br />
-struct geometry_concept<CPolygon45WithHoles> { typedef polygon_45_with_holes_concept type; };</font></p><p>
-<font face="Times New Roman">The semantic of a polygon_45_with_holes is a
-polygon_45 that it can provide iterators over holes that are also polygon_45.
-A mutable polygon_45_with_holes must also be able to set its geometry based on
-an interator range over polygon_45 holes. There is no convention of
-winding of holes enforced within the library. </font></p><p>
-<font face="Times New Roman">Below is shown the default polygon with holes
-traits. Specialization of these traits is required for types that don't
-conform to the default behavior.</font></p><p><font face="Courier New">template <typename
-T, typename enable = void><br />
+ <p> To register a user defined type as a model of <font
+ face="Times New Roman">polygon_45_with_holes </font>concept,
+specialize the geometry concept meta-function for that type. In
+the example below CPolygon45WithHoles is registered as a model of
+polygon<font face="Times New Roman">_45_with_holes </font> concept.</p>
+ <p> <font face="Courier New">template <><br />
+struct geometry_concept<CPolygon45WithHoles> { typedef
+polygon_45_with_holes_concept type; };</font></p>
+ <p> <font face="Times New Roman">The semantic of a
+polygon_45_with_holes is a polygon_45 that it can provide iterators
+over holes that are also polygon_45. A mutable
+polygon_45_with_holes must also be able to set its geometry based on an
+interator range over polygon_45 holes. There is no convention of
+winding of holes enforced within the library. </font></p>
+ <p> <font face="Times New Roman">Below is shown the default
+polygon with holes traits. Specialization of these traits is
+required for types that don't conform to the default behavior.</font></p>
+ <p><font face="Courier New">template <typename T, typename
+enable = void><br />
struct polygon_with_holes_traits {<br />
- typedef typename T::iterator_holes_type
+ typedef typename T::iterator_holes_type
iterator_holes_type;<br />
typedef typename T::hole_type hole_type;<br />
- static inline iterator_holes_type begin_holes(const T&
-t) {<br />
- return t.begin_holes();<br />
+ static inline iterator_holes_type
+begin_holes(const T& t) {<br />
+ return
+t.begin_holes();<br />
}<br />
- static inline iterator_holes_type end_holes(const T& t)
-{<br />
- return t.end_holes();<br />
+ static inline iterator_holes_type
+end_holes(const T& t) {<br />
+ return
+t.end_holes();<br />
}<br />
- static inline unsigned int size_holes(const T& t) {<br />
- return t.size_holes();<br />
+ static inline unsigned int size_holes(const
+T& t) {<br />
+ return
+t.size_holes();<br />
}<br />
};</font></p>
-<p><font face="Courier New">template <typename T, typename enable = void><br />
+ <p><font face="Courier New">template <typename T, typename
+enable = void><br />
struct polygon_with_holes_mutable_traits {<br />
template <typename iT><br />
- static inline T& set_holes(T& t, iT inputBegin, iT
-inputEnd) {<br />
- t.set_holes(inputBegin,
-inputEnd);<br />
+ static inline T& set_holes(T& t, iT
+inputBegin, iT inputEnd) {<br />
+
+t.set_holes(inputBegin, inputEnd);<br />
return t;<br />
}<br />
};</font></p>
-<p>An object that is a model of <font face="Courier New">
-polygon_45_with_holes_concept</font> can be viewed as a model of any of its
-refinements if it is determined at runtime to conform to the restriction of
-those concepts. This concept casting is accomplished through the
-<font face="Courier New">view_as<>()</font> function.</p>
-<p><font face="Courier New">view_as<rectangle_concept>(polygon_45_with_holes_object)</font><br />
-<font face="Courier New">view_as<polygon_90_concept>(polygon_45_with_holes_object)</font><br />
-<font face="Courier New">view_as<polygon_90_with_holes_concept>(polygon_45_with_holes_object)</font><br />
-<font face="Courier New">view_as<polygon_45_concept>(polygon_45_with_holes_object)</font></p>
-<p>The return value of <font face="Courier New">view_as<>()</font> can be
-passed into any interface that expects an object of the conceptual type
-specified in its template parameter. </p>
-<h2>Functions</h2>
-<table id="table1" border="1" width="100%">
- <tbody><tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- point_iterator_type <b>begin_points</b>(const T& polygon)</font></td>
- <td><font face="Times New Roman">Expects a model of
- polygon_45_with_holes.
- Returns the begin iterator over the range of points that correspond to
- vertices of the polygon.</font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- point_iterator_type <b>end_points</b>(const T& polygon)</font></td>
- <td><font face="Times New Roman">Expects a model of
- polygon_45_with_holes.
- Returns the end iterator over the range of points that correspond to
- vertices of the polygon.</font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- hole_iterator_type <b>begin_holes</b>(const T& polygon)</font></td>
- <td><font face="Times New Roman">Expects a model of
- polygon_45_with_holes.
- Returns the begin iterator over the range of coordinates that correspond
- to horizontal and vertical edges.</font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- hole_iterator_type <b>end_holes</b>(const T& polygon)</font></td>
- <td><font face="Times New Roman">Expects a model of
- polygon_45_with_holes.
- Returns the end iterator over the range of coordinates that correspond
- to horizontal and vertical edges.</font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T, typename
- iterator><br />
- void <b>set_points</b>(T& polygon, iterator b, iterator e)</font></td>
- <td><font face="Times New Roman">Expects a model of
- polygon_45_with_holes.
- Sets the polygon to the point data range [b,e) that corresponds to
- vertices of a polygon. </font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T, typename
- iterator><br />
- void <b>set_holes</b>(T& polygon, iterator b, iterator e)</font></td>
- <td><font face="Times New Roman">Expects a model of
- polygon_45_with_holes.
- Sets the polygon holes to the hole data range [b,e)</font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- unsigned int <b>size</b>(const T& polygon)</font></td>
- <td><font face="Times New Roman">Returns the number of edges in the
- outer shell of the polygon_45_with_holes. Does not include sizes
- of the holes.</font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- T1& <b>assign</b>(T1& left, const T2& right)</font></td>
- <td>Copies data from right object that models polygon_45_with_holes or
- one of its refinements into left object
- that models polygon_45_with_holes.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T,
- typename point_type><br />
- bool <b>contains</b>(const T&, const point_type& point, <br />
-
- bool consider_touch=true)</font></td>
- <td>Given an object that models polygon_45_with_holes and an object that models
- point, returns true
- if the polygon shell contains the point and one of its holes does not
- contain the point. If the consider_touch
- flag is true will return true if the point lies along the boundary of
- the polygon or one of its holes.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">// get the center coordinate<br />
- template <typename T, typename point_type><br />
- void <b>center</b>(point_type& p, const T& polygon)</font></td>
- <td>Sets object that models point to the center point of the bounding
- box of an object that models polygon_45_with_holes.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T,
- typename rectangle_type><br />
- bool <b>extents</b>(rectangle_type& bbox, const T& polygon)</font></td>
- <td>Sets object that models rectangle to the bounding box of an object
- that models polygon_45_with_holes and returns true. Returns false
- and leaves bbox unchanged if polygon is empty.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- manhattan_area_type <b>area</b>(const T& polygon)</font></td>
- <td>Returns the area of an object
- that models polygon_45_with_holes including subtracting the area of its
- holes from the area of the outer shell polygon.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- direction_1d <b>winding</b>(const T& polygon)</font></td>
- <td>Returns the winding direction of an object
- that models polygon_45_with_holes, LOW == CLOCKWISE, HIGH =
- COUNTERCLOCKWISE.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- coordinate_difference <b>perimeter</b>(const T& polygon)</font></td>
- <td>Returns the perimeter length of an object
- that models polygon_45, including the perimeters of the holes.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T,
- typename transform_type><br />
- T& <b>transform</b>(T& polygon, const transform_type&)</font></td>
- <td>Applies transform() on the vertices of polygon and sets the polygon to that described by the result of
- transforming its vertices. Also applies transform() on the holes
- of the polygon.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- T& <b>scale_up</b>(T& polygon, unsigned_area_type factor)</font></td>
- <td>Scales up outer shell and holes of an object that models
- polygon_45 by unsigned factor.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- T& <b>scale_down</b>(T& polygon, unsigned_area_type factor)</font></td>
- <td>Scales down outer shell and holes of an object that models
- polygon_45 by unsigned factor.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T, scaling_type><br />
- T& <b>scale</b>(T& rectangle, double scaling) </font></td>
- <td>Scales outer shell and holes of an object that models polygon_45 by
- floating point factor.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- T& <b>move</b>(T& polygon, orientation_2d,<br />
- coordinate_difference displacement)</font></td>
- <td>Adds displacement value to coordinate indicated by orientation_2d of
- vertices of an object that models polygon_45 .</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename polygon_type, typename point_type><br />
- polygon_type& <b>convolve</b>(polygon_type& polygon,<br />
+ <p>An object that is a model of <font face="Courier New">
+polygon_45_with_holes_concept</font> can be viewed as a model of any of
+its refinements if it is determined at runtime to conform to the
+restriction of those concepts. This concept casting is
+accomplished through the
+ <font face="Courier New">view_as<>()</font> function.</p>
+ <p><font face="Courier New">view_as<rectangle_concept>(polygon_45_with_holes_object)</font><br />
+ <font face="Courier New">view_as<polygon_90_concept>(polygon_45_with_holes_object)</font><br />
+ <font face="Courier New">view_as<polygon_90_with_holes_concept>(polygon_45_with_holes_object)</font><br />
+ <font face="Courier New">view_as<polygon_45_concept>(polygon_45_with_holes_object)</font></p>
+ <p>The return value of <font face="Courier New">view_as<>()</font>
+can be passed into any interface that expects an object of the
+conceptual type specified in its template parameter. </p>
+ <h2>Functions</h2>
+ <table id="table1" border="1" width="100%">
+ <tbody>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+point_iterator_type <b>begin_points</b>(const T& polygon)</font></td>
+ <td><font face="Times New Roman">Expects a model of
+polygon_45_with_holes. Returns the begin iterator over the range
+of points that correspond to vertices of the polygon.</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+point_iterator_type <b>end_points</b>(const T& polygon)</font></td>
+ <td><font face="Times New Roman">Expects a model of
+polygon_45_with_holes. Returns the end iterator over the range of
+points that correspond to vertices of the polygon.</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+hole_iterator_type <b>begin_holes</b>(const T& polygon)</font></td>
+ <td><font face="Times New Roman">Expects a model of
+polygon_45_with_holes. Returns the begin iterator over the range
+of coordinates that correspond to horizontal and vertical edges.</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+hole_iterator_type <b>end_holes</b>(const T& polygon)</font></td>
+ <td><font face="Times New Roman">Expects a model of
+polygon_45_with_holes. Returns the end iterator over the range of
+coordinates that correspond to horizontal and vertical edges.</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename iterator><br />
+void <b>set_points</b>(T& polygon, iterator b, iterator e)</font></td>
+ <td><font face="Times New Roman">Expects a model of
+polygon_45_with_holes. Sets the polygon to the point data
+range [b,e) that corresponds to vertices of a polygon. </font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename iterator><br />
+void <b>set_holes</b>(T& polygon, iterator b, iterator e)</font></td>
+ <td><font face="Times New Roman">Expects a model of
+polygon_45_with_holes. Sets the polygon holes to the hole
+data range [b,e)</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+unsigned int <b>size</b>(const T& polygon)</font></td>
+ <td><font face="Times New Roman">Returns the number of
+edges in the outer shell of the polygon_45_with_holes. Does not
+include sizes of the holes.</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+T1& <b>assign</b>(T1& left, const T2& right)</font></td>
+ <td>Copies data from right object that models
+polygon_45_with_holes or one of its refinements into left object that
+models polygon_45_with_holes.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename point_type><br />
+bool <b>contains</b>(const T&, const point_type& point, <br />
+
+bool consider_touch=true)</font></td>
+ <td>Given an object that models polygon_45_with_holes and
+an object that models point, returns true if the polygon shell contains
+the point and one of its holes does not contain the point. If the
+consider_touch flag is true will return true if the point lies along
+the boundary of the polygon or one of its holes.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">// get the center
+coordinate<br />
+template <typename T, typename point_type><br />
+void <b>center</b>(point_type& p, const T& polygon)</font></td>
+ <td>Sets object that models point to the center point of
+the bounding box of an object that models polygon_45_with_holes.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename rectangle_type><br />
+bool <b>extents</b>(rectangle_type& bbox, const T& polygon)</font></td>
+ <td>Sets object that models rectangle to the bounding box
+of an object that models polygon_45_with_holes and returns true.
+Returns false and leaves bbox unchanged if polygon is empty.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+manhattan_area_type <b>area</b>(const T& polygon)</font></td>
+ <td>Returns the area of an object that models
+polygon_45_with_holes including subtracting the area of its holes from
+the area of the outer shell polygon.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+direction_1d <b>winding</b>(const T& polygon)</font></td>
+ <td>Returns the winding direction of an object that models
+polygon_45_with_holes, LOW == CLOCKWISE, HIGH = COUNTERCLOCKWISE.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+coordinate_difference <b>perimeter</b>(const T& polygon)</font></td>
+ <td>Returns the perimeter length of an object that models
+polygon_45, including the perimeters of the holes.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename transform_type><br />
+T& <b>transform</b>(T& polygon, const transform_type&)</font></td>
+ <td>Applies transform() on the vertices of polygon and sets
+the polygon to that described by the result of transforming its
+vertices. Also applies transform() on the holes of the polygon.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+T& <b>scale_up</b>(T& polygon, unsigned_area_type factor)</font></td>
+ <td>Scales up outer shell and holes of an object that
+models polygon_45 by unsigned factor.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+T& <b>scale_down</b>(T& polygon, unsigned_area_type factor)</font></td>
+ <td>Scales down outer shell and holes of an object that
+models polygon_45 by unsigned factor.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, scaling_type><br />
+T& <b>scale</b>(T& rectangle, double scaling) </font></td>
+ <td>Scales outer shell and holes of an object that models
+polygon_45 by floating point factor.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+T& <b>move</b>(T& polygon, orientation_2d,<br />
+ coordinate_difference
+displacement)</font></td>
+ <td>Adds displacement value to coordinate indicated by
+orientation_2d of vertices of an object that models polygon_45 .</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename polygon_type, typename point_type><br />
+polygon_type& <b>convolve</b>(polygon_type& polygon,<br />
+
const point_type& point)</font></td>
- <td>Convolves coordinate values of point with the outer shell and holes of an
- object that models polygon_45_with_holes.</td>
- </tr>
- </tbody></table>
- <h1>Polygon 45 With Holes Data</h1>
-
-<p>
-</p><p>The library provides a model of polygon 45 with holes concept declared
-<font face="Courier New">
-template<typename T> polygon_45_with_holes_data </font>where T is the
-coordinate type.</p>
-<p>This data type is used internally when a 45 degree polygon with holes is
-needed and is available to the library user who finds it convenient to use a
-library polygon data type instead of providing their own. The data type is
-implemented to be convenient to use with the library traits.</p>
-<h2>Members</h2>
-<table id="table2" border="1" width="100%">
- <tbody><tr>
- <td width="586"><b><font face="Courier New">geometry_type</font></b></td>
- <td><font face="Times New Roman">polygon_45_with_holes_concept</font></td>
- </tr>
- <tr>
- <td width="586"><b><font face="Courier New">coordinate_type</font></b></td>
- <td><font face="Times New Roman">T</font></td>
- </tr>
- <tr>
- <td width="586"><b><font face="Courier New">iterator_type</font></b></td>
- <td>Iterator over vertices point_data<T> vertices of polygon</td>
- </tr>
- <tr>
- <td width="586"><b><font face="Courier New">iterator_holes_type</font></b></td>
- <td><font face="Times New Roman">Iterator over hole polygons of type
- polygon_45_data<T>.</font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New"><b>polygon_45_with_holes_data</b>()</font></td>
- <td><font face="Times New Roman">Default constructs the </font>polygon.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New"><b>polygon_45_with_holes_data</b>(const
- polygon_45_with_holes_data& that)</font></td>
- <td><font face="Times New Roman">Copy construct</font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">polygon_45_with_holes_data& <b>
- <br />operator=</b>(const polygon_45_with_holes_data& that)</font></td>
- <td>Assignment operator.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T2><b> </b>
- polygon_45_with_holes_data&<b>
- <br /> operator=</b>(const T2& that) const</font></td>
- <td>Assign from an object that is a model of polygon 45 with holes.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">iterator_type <b>begin</b>()
- const</font></td>
- <td>Get the begin iterator over vertices of the polygon.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">iterator_type <b>end</b>()
- const</font></td>
- <td>Get the end iterator over vertices of the polygon.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">iterator_hole_type <b>begin_holes</b>()
- const</font></td>
- <td>Get the begin compact iterator over non-redundant coordinates of the
- polygon.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">iterator_hole_type <b>end_holes</b>()
- const</font></td>
- <td>Get the end compact iterator over non-redundant coordinates of the
- polygon.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">std::size_t <b>size</b>() const</font></td>
- <td>Get the number of elements in the sequence stored to the polygon,
- usually equal to the number of edges of the polygon.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">std::size_t <b>size_holes</b>() const</font></td>
- <td>Get the number of holes in the polygon</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename iT><b>
- <br /> </b>void <b>set</b>(iT begin_points, iT end_points)</font></td>
- <td>Sets the polygon to the iterator range of points. No check is
- performed to ensure the points describe a 45 degree figure.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename iT><b>
- <br /> </b>void <b>set_holes</b>(iT begin_holes, iT end_choless)</font></td>
- <td>Sets the polygon holes the iterator range of hole polygons. These
- polygons in the input range may be either polygon_45_data or
- polygon_45_with_holes_data or any type that provides begin and end
- member functions to iterate over point_data<T>.</td>
- </tr>
-</tbody></table>
- </td></tr><tr>
-<td style="background-color: rgb(238, 238, 238);" nowrap="1" valign="top">
- </td>
-<td style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;" valign="top" width="100%">
-
-
-<table class="docinfo" id="table3" frame="void" rules="none">
- <colgroup>
- <col class="docinfo-name" /><col class="docinfo-content" />
- </colgroup>
- <tbody valign="top">
- <tr>
- <th class="docinfo-name">Copyright:</th>
- <td>Copyright © Intel Corporation 2008-2010.</td>
- </tr>
- <tr class="field">
- <th class="docinfo-name">License:</th>
- <td class="field-body">Distributed under the Boost Software License,
- Version 1.0. (See accompanying file <tt class="literal">
- <span class="pre">LICENSE_1_0.txt</span></tt> or copy at
- <a class="reference" target="_top" href="http://www.boost.org/LICENSE_1_0.txt">
- http://www.boost.org/LICENSE_1_0.txt>)</td>
- </tr>
-</tbody></table>
-
-</td></tr></tbody></table></body></html>
\ No newline at end of file
+ <td>Convolves coordinate values of point with the outer
+shell and holes of an object that models polygon_45_with_holes.</td>
+ </tr>
+ </tbody>
+ </table>
+ <h1>Polygon 45 With Holes Data</h1>
+ <p> </p>
+ <p>The library provides a model of polygon 45 with holes concept
+declared
+ <font face="Courier New">template<typename T>
+polygon_45_with_holes_data </font>where T is the coordinate type.</p>
+ <p>This data type is used internally when a 45 degree polygon
+with holes is needed and is available to the library user who finds it
+convenient to use a library polygon data type instead of providing
+their own. The data type is implemented to be convenient to use
+with the library traits.</p>
+ <h2>Members</h2>
+ <table id="table2" border="1" width="100%">
+ <tbody>
+ <tr>
+ <td width="586"><b><font face="Courier New">geometry_type</font></b></td>
+ <td><font face="Times New Roman">polygon_45_with_holes_concept</font></td>
+ </tr>
+ <tr>
+ <td width="586"><b><font face="Courier New">coordinate_type</font></b></td>
+ <td><font face="Times New Roman">T</font></td>
+ </tr>
+ <tr>
+ <td width="586"><b><font face="Courier New">iterator_type</font></b></td>
+ <td>Iterator over vertices point_data<T> vertices of
+polygon</td>
+ </tr>
+ <tr>
+ <td width="586"><b><font face="Courier New">iterator_holes_type</font></b></td>
+ <td><font face="Times New Roman">Iterator over hole
+polygons of type polygon_45_data<T>.</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New"><b>polygon_45_with_holes_data</b>()</font></td>
+ <td><font face="Times New Roman">Default constructs the </font>polygon.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New"><b>polygon_45_with_holes_data</b>(const
+polygon_45_with_holes_data& that)</font></td>
+ <td><font face="Times New Roman">Copy construct</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">polygon_45_with_holes_data&
+ <b> <br />
+operator=</b>(const polygon_45_with_holes_data& that)</font></td>
+ <td>Assignment operator.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T2><b> </b> polygon_45_with_holes_data&<b> <br />
+operator=</b>(const T2& that) const</font></td>
+ <td>Assign from an object that is a model of polygon 45
+with holes.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">iterator_type <b>begin</b>()
+const</font></td>
+ <td>Get the begin iterator over vertices of the polygon.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">iterator_type <b>end</b>()
+const</font></td>
+ <td>Get the end iterator over vertices of the polygon.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">iterator_hole_type
+ <b>begin_holes</b>() const</font></td>
+ <td>Get the begin compact iterator over non-redundant
+coordinates of the polygon.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">iterator_hole_type
+ <b>end_holes</b>() const</font></td>
+ <td>Get the end compact iterator over non-redundant
+coordinates of the polygon.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">std::size_t <b>size</b>()
+const</font></td>
+ <td>Get the number of elements in the sequence stored to
+the polygon, usually equal to the number of edges of the polygon.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">std::size_t <b>size_holes</b>()
+const</font></td>
+ <td>Get the number of holes in the polygon</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename iT><b> <br />
+ </b>void <b>set</b>(iT begin_points, iT end_points)</font></td>
+ <td>Sets the polygon to the iterator range of points.
+No check is performed to ensure the points describe a 45 degree figure.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename iT><b> <br />
+ </b>void <b>set_holes</b>(iT begin_holes, iT end_choless)</font></td>
+ <td>Sets the polygon holes the iterator range of hole
+polygons. These polygons in the input range may be either
+polygon_45_data or polygon_45_with_holes_data or any type that provides
+begin and end member functions to iterate over point_data<T>.</td>
+ </tr>
+ </tbody>
+ </table>
+ </td>
+ </tr>
+ <tr>
+ <td style="background-color: rgb(238, 238, 238);" nowrap="1"
+ valign="top"> </td>
+ <td
+ style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;"
+ valign="top" width="100%">
+ <table class="docinfo" id="table3" frame="void" rules="none">
+ <colgroup> <col class="docinfo-name" /><col
+ class="docinfo-content" /> </colgroup> <tbody valign="top">
+ <tr>
+ <th class="docinfo-name">Copyright:</th>
+ <td>Copyright © Intel Corporation 2008-2010.</td>
+ </tr>
+ <tr class="field">
+ <th class="docinfo-name">License:</th>
+ <td class="field-body">Distributed under the Boost Software
+License, Version 1.0. (See accompanying file <tt class="literal"> <span
+ class="pre">LICENSE_1_0.txt</span></tt> or copy at <a
+ class="reference" target="_top"
+ href="http://www.boost.org/LICENSE_1_0.txt">
+http://www.boost.org/LICENSE_1_0.txt>)</td>
+ </tr>
+ </tbody>
+ </table>
+ </td>
+ </tr>
+ </tbody>
+</table>
+</body>
+</html>
Modified: branches/release/libs/polygon/doc/gtl_polygon_90_concept.htm
==============================================================================
--- branches/release/libs/polygon/doc/gtl_polygon_90_concept.htm (original)
+++ branches/release/libs/polygon/doc/gtl_polygon_90_concept.htm 2013-04-15 18:27:46 EDT (Mon, 15 Apr 2013)
@@ -1,411 +1,469 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:(null)1="http://www.w3.org/TR/REC-html40" lang="en"><head>
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"
+ xmlns:v="urn:schemas-microsoft-com:vml"
+ xmlns:o="urn:schemas-microsoft-com:office:office"
+ xmlns:(null)1="http://www.w3.org/TR/REC-html40" lang="en">
+<head>
<!--
Copyright 2009-2010 Intel Corporation
license banner
---><title>Boost Polygon Library: Polygon 90 Concept</title>
-
-
-
- <meta http-equiv="content-type" content="text/html;charset=ISO-8859-1" /><!-- <link type="text/css" rel="stylesheet" href="adobe_source.css"> --></head><body><table style="margin: 0pt; padding: 0pt; width: 100%;" border="0" cellpadding="0" cellspacing="0"><tbody><tr>
-<td style="background-color: rgb(238, 238, 238);" nowrap="1" valign="top">
- <div style="padding: 5px;" align="center">
- <img src="images/boost.png" border="0" height="86" width="277" /><a title="www.boost.org home page" href="http://www.boost.org/" tabindex="2" style="border: medium none ;">
- </a>
- </div>
- <div style="margin: 5px;">
- <h3 class="navbar">Contents</h3>
- <ul>
- <li>Boost.Polygon Main Page</li>
- <li>Design Overview</li>
- <li>Isotropy</li>
- <li>Coordinate Concept</li>
- <li>Interval Concept</li>
- <li>Point Concept</li>
+-->
+ <title>Boost Polygon Library: Polygon 90 Concept</title>
+ <meta http-equiv="content-type" content="text/html;charset=ISO-8859-1" />
+<!-- <link type="text/css" rel="stylesheet" href="adobe_source.css"> -->
+</head>
+<body>
+<table style="margin: 0pt; padding: 0pt; width: 100%;" border="0"
+ cellpadding="0" cellspacing="0">
+ <tbody>
+ <tr>
+ <td style="background-color: rgb(238, 238, 238);" nowrap="1"
+ valign="top">
+ <div style="padding: 5px;" align="center"> <img
+ src="images/boost.png" border="0" height="86" width="277" /><a
+ title="www.boost.org home page" href="http://www.boost.org/"
+ tabindex="2" style="border: medium none ;"> </a> </div>
+ <div style="margin: 5px;">
+ <h3 class="navbar">Contents</h3>
+ <ul>
+ <li>Boost.Polygon Main Page</li>
+ <li>Design Overview</li>
+ <li>Isotropy</li>
+ <li>Coordinate Concept</li>
+ <li>Interval Concept</li>
+ <li>Point Concept</li>
<li>Segment Concept</li>
-
- <li>Rectangle Concept</li>
- <li>Polygon 90 Concept</li>
- <li>Polygon 90 With Holes Concept</li>
- <li>Polygon 45 Concept</li>
- <li>Polygon 45 With Holes Concept</li>
- <li>Polygon Concept</li>
- <li>Polygon With Holes Concept</li>
- <li>Polygon 90 Set Concept</li>
- <li>Polygon 45 Set Concept</li>
- <li>Polygon Set Concept</li>
- <li>Connectivity Extraction 90</li>
- <li>Connectivity Extraction 45</li>
- <li>Connectivity Extraction</li>
- <li>Property Merge 90</li>
- <li>Property Merge 45</li>
- <li>Property Merge</li>
+ <li>Rectangle Concept</li>
+ <li>Polygon 90 Concept</li>
+ <li><a href="gtl_polygon_90_with_holes_concept.htm">Polygon 90
+With Holes Concept</a></li>
+ <li>Polygon 45 Concept</li>
+ <li><a href="gtl_polygon_45_with_holes_concept.htm">Polygon 45
+With Holes Concept</a></li>
+ <li>Polygon Concept</li>
+ <li><a href="gtl_polygon_with_holes_concept.htm">Polygon With
+Holes Concept</a></li>
+ <li><a href="gtl_polygon_90_set_concept.htm">Polygon 90 Set
+Concept</a></li>
+ <li><a href="gtl_polygon_45_set_concept.htm">Polygon 45 Set
+Concept</a></li>
+ <li>Polygon Set Concept</li>
+ <li><a href="gtl_connectivity_extraction_90.htm">Connectivity
+Extraction 90</a></li>
+ <li><a href="gtl_connectivity_extraction_45.htm">Connectivity
+Extraction 45</a></li>
+ <li><a href="gtl_connectivity_extraction.htm">Connectivity
+Extraction</a></li>
+ <li>Property Merge 90</li>
+ <li>Property Merge 45</li>
+ <li>Property Merge</li>
<li><a href="voronoi_main.htm">Voronoi Main Page<br />
-</a></li>
+ </a></li>
<li>Voronoi Benchmark<br />
</li>
<li>Voronoi Builder</li>
- <li><a href="voronoi_diagram.htm">Voronoi Diagram<br />
-</a></li>
- <li>Voronoi Predicates</li>
- <li>Voronoi Robust FPT<br />
- </li>
-
-
- </ul>
- <h3 class="navbar">Other Resources</h3>
- <ul>
+ <li>Voronoi Diagram</li>
+ </ul>
+ <h3 class="navbar">Other Resources</h3>
+ <ul>
<li>GTL Boostcon 2009 Paper</li>
- <li><a href="GTL_boostcon_draft03.pdf">GTL Boostcon 2009
- Presentation</a></li>
+ <li><a href="GTL_boostcon_draft03.pdf">GTL Boostcon 2009
+Presentation</a></li>
<li>Performance Analysis</li>
<li>Layout Versus Schematic Tutorial</li>
<li>Minkowski Sum Tutorial</li>
<li>Voronoi Basic Tutorial</li>
- <li>Voronoi Advanced Tutorial</li>
-</ul>
- </div>
- <h3 class="navbar">Polygon Sponsor</h3>
- <div style="padding: 5px;" align="center">
- <img src="images/intlogo.gif" border="0" height="51" width="127" /><a title="www.adobe.com home page" href="http://www.adobe.com/" tabindex="2" style="border: medium none ;">
- </a>
- </div>
-</td>
-<td style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;" valign="top" width="100%">
-
-<!-- End Header -->
-
-<br />
-<p>
-</p><h1>Polygon 90 Concept</h1>
-
-<p>
-</p><p>The polygon_90 concept tag is <font face="Courier New">
+ <li><a href="voronoi_advanced_tutorial.htm">Voronoi Advanced
+Tutorial</a></li>
+ </ul>
+ </div>
+ <h3 class="navbar">Polygon Sponsor</h3>
+ <div style="padding: 5px;" align="center"> <img
+ src="images/intlogo.gif" border="0" height="51" width="127" /><a
+ title="www.adobe.com home page" href="http://www.adobe.com/"
+ tabindex="2" style="border: medium none ;"> </a> </div>
+ </td>
+ <td
+ style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;"
+ valign="top" width="100%">
+<!-- End Header --><br />
+ <p>
+ </p>
+ <h1>Polygon 90 Concept</h1>
+ <p> </p>
+ <p>The polygon_90 concept tag is <font face="Courier New">
polygon_90_concept</font></p>
-<p>
-To register a user defined type as a model of
-<font face="Times New Roman">polygon_90 </font>concept, specialize the
-geometry concept meta-function for that type. In the example below CPolygon90 is registered as a model of
-polygon_90 concept.</p><p>
-<font face="Courier New">template <><br />
-struct geometry_concept<CPolygon90> { typedef polygon_90_concept type; };</font></p><p>
-<font face="Times New Roman">The semantic of a polygon_90 is that it can provide
-iterators over the x and y coordinates that correspond to its horizontal and
-vertical sides, starting with an x coordinate. A mutable polygon_90 must
-also be able to set its geometry based on an interator range over such
-coordinates. Since most polygons use vertex points in internal storage
-iterator adaptors for converting to and from point sequences are provided in
-iterator_points_to_compact.hpp and iterator_compact_to_points.hpp to aid in the
-specialization of polygon_90_traits. A std::vector<int> or std::list<int>
-could be made models of polygon_90_concept by simply providing access to their
-iterators through traits. Library functions that create polygon objects
-require that those objects provide a default constructor.</font></p><p>
-<font face="Times New Roman">Below is shown the default polygon traits.
-Specialization of these traits is required for types that don't conform to the
-default behavior. Note that these traits are also used by the
-polygon_90_with_holes concept.</font></p><p><font face="Courier New">template <typename
-T><br />
+ <p> To register a user defined type as a model of <font
+ face="Times New Roman">polygon_90 </font>concept, specialize the
+geometry concept meta-function for that type. In the example
+below CPolygon90 is registered as a model of polygon_90 concept.</p>
+ <p> <font face="Courier New">template <><br />
+struct geometry_concept<CPolygon90> { typedef polygon_90_concept
+type; };</font></p>
+ <p> <font face="Times New Roman">The semantic of a polygon_90 is
+that it can provide iterators over the x and y coordinates that
+correspond to its horizontal and vertical sides, starting with an x
+coordinate. A mutable polygon_90 must also be able to set its
+geometry based on an interator range over such coordinates. Since
+most polygons use vertex points in internal storage iterator adaptors
+for converting to and from point sequences are provided in
+iterator_points_to_compact.hpp and iterator_compact_to_points.hpp to
+aid in the specialization of polygon_90_traits. A
+std::vector<int> or std::list<int> could be made models of
+polygon_90_concept by simply providing access to their iterators
+through traits. Library functions that create polygon objects
+require that those objects provide a default constructor.</font></p>
+ <p> <font face="Times New Roman">Below is shown the default
+polygon traits. Specialization of these traits is required for
+types that don't conform to the default behavior. Note that these
+traits are also used by the polygon_90_with_holes concept.</font></p>
+ <p><font face="Courier New">template <typename T><br />
struct polygon_90_traits {<br />
- typedef typename T::coordinate_type coordinate_type;<br />
- typedef typename T::compact_iterator_type
+ typedef typename T::coordinate_type
+coordinate_type;<br />
+ typedef typename T::compact_iterator_type
compact_iterator_type;<br />
- static inline compact_iterator_type begin_compact(const
-T& t) {<br />
- return t.begin_compact();<br />
+ static inline compact_iterator_type
+begin_compact(const T& t) {<br />
+ return
+t.begin_compact();<br />
}<br />
- static inline compact_iterator_type end_compact(const
-T& t) {<br />
- return t.end_compact();<br />
+ static inline compact_iterator_type
+end_compact(const T& t) {<br />
+ return
+t.end_compact();<br />
}<br />
- static inline unsigned int size(const T& t) {<br />
+ static inline unsigned int size(const T&
+t) {<br />
return t.size();<br />
}<br />
- static inline winding_direction winding(const T& t) {<br />
- return unknown_winding;<br />
+ static inline winding_direction winding(const
+T& t) {<br />
+ return
+unknown_winding;<br />
}<br />
};</font></p>
-<p><font face="Courier New">template <typename T><br />
+ <p><font face="Courier New">template <typename T><br />
struct polygon_90_mutable_traits { <br />
template <typename iT><br />
- static inline T& set_compact(T& t, iT input_begin, iT
-input_end) {<br />
- t.set_compact(input_begin,
-input_end);<br />
+ static inline T& set_compact(T& t, iT
+input_begin, iT input_end) {<br />
+
+t.set_compact(input_begin, input_end);<br />
return t;<br />
}</font><br />
-<font face="Courier New">};</font></p>
-<p>An object that is a model of <font face="Courier New">
-polygon_90_concept</font> can be viewed as a model of any of its
-refinements if it is determined at runtime to conform to the restriction of
-those concepts. This concept casting is accomplished through the
-<font face="Courier New">view_as<>()</font> function.</p>
-<p><font face="Courier New">view_as<rectangle_concept>(polygon_90_object)</font></p>
-<p>The return value of <font face="Courier New">view_as<>()</font> can be
-passed into any interface that expects an object of the conceptual type
-specified in its template parameter.</p>
-<h2>Functions</h2>
-<table id="table1" border="1" width="100%">
- <tbody><tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- compact_iterator_type <b>begin_compact</b>(const T& polygon)</font></td>
- <td><font face="Times New Roman">Expects a model of polygon_90.
- Returns the begin iterator over the range of coordinates that correspond
- to horizontal and vertical edges.</font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- compact_iterator_type <b>end_compact</b>(const T& polygon)</font></td>
- <td><font face="Times New Roman">Expects a model of polygon_90.
- Returns the end iterator over the range of coordinates that correspond
- to horizontal and vertical edges.</font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- point_iterator_type <b>begin_points</b>(const T& polygon)</font></td>
- <td><font face="Times New Roman">Expects a model of polygon_90.
- Returns the begin iterator over the range of points that correspond to
- vertices of the polygon.</font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- point_iterator_type <b>end_points</b>(const T& polygon)</font></td>
- <td><font face="Times New Roman">Expects a model of polygon_90.
- Returns the end iterator over the range of points that correspond to
- vertices of the polygon.</font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T, typename
- iterator><br />
- void <b>set_compact</b>(T& polygon, iterator b, iterator e)</font></td>
- <td><font face="Times New Roman">Expects a model of polygon_90.
- Sets the polygon to the coordinate data range [b,e) that corresponds to
- .horizontal and vertical edges.</font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T, typename
- iterator><br />
- void <b>set_points</b>(T& polygon, iterator b, iterator e)</font></td>
- <td><font face="Times New Roman">Expects a model of polygon_90.
- Sets the polygon to the point data range [b,e) that corresponds to
- vertices of a manhattan polygon. Non-manhattan edges between
- successive input points results in undefined behavior.</font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- unsigned int <b>size</b>(const T& polygon)</font></td>
- <td><font face="Times New Roman">Returns the number of edges in the
- polygon.</font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- T1& <b>assign</b>(T1& left, const T2& right)</font></td>
- <td>Copies data from right object that models polygon_90 into left object
- that models polygon_90.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T,
- typename point_type><br />
- bool <b>contains</b>(const T&, const point_type& point, <br />
-
- bool consider_touch=true)</font></td>
- <td>Given an object that models polygon_90 and an object that models
- point, returns true
- if the polygon contains the point. If the consider_touch
- flag is true will return true if the point lies along the boundary of
- the polygon. Linear wrt. vertices.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">// get the center coordinate<br />
- template <typename T, typename point_type><br />
- void <b>center</b>(point_type& p, const T& polygon)</font></td>
- <td>Sets object that models point to the center point of the bounding
- box of an object that models polygon_90. Linear wrt. vertices.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T,
- typename rectangle_type><br />
- bool <b>extents</b>(rectangle_type& bbox, const T& polygon)</font></td>
- <td>Sets object that models rectangle to the bounding box of an object
- that models polygon_90 and returns true. Returns false and leaves
- bbox unchanged if polygon is empty. Linear wrt. vertices.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- manhattan_area_type <b>area</b>(const T& polygon)</font></td>
- <td>Returns the area of an object
- that models polygon_90. Linear wrt. vertices.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- direction_1d <b>winding</b>(const T& polygon)</font></td>
- <td>Returns the winding direction of an object
- that models polygon_90, LOW == CLOCKWISE, HIGH = COUNTERCLOCKWISE.
- Complexity depends upon winding trait.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- coordinate_difference <b>perimeter</b>(const T& polygon)</font></td>
- <td>Returns the perimeter length of an object
- that models polygon_90. Linear wrt. vertices.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T,
- typename transform_type><br />
- T& <b>transform</b>(T& polygon, const transform_type&)</font></td>
- <td>Applies transform() on the vertices of polygon and sets the polygon to that described by the result of
- transforming its vertices. Linear wrt. vertices.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- T& <b>scale_up</b>(T& polygon, unsigned_area_type factor)</font></td>
- <td>Scales up coordinate of an object that models
- polygon_90 by unsigned factor. Linear wrt. vertices.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- T& <b>scale_down</b>(T& polygon, unsigned_area_type factor)</font></td>
- <td>Scales down coordinates of an object that models
- polygon_90 by unsigned factor. Linear wrt. vertices.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T, scaling_type><br />
- T& <b>scale</b>(T& rectangle, double scaling) </font></td>
- <td>Scales coordinates of an object that models polygon_90 by floating
- point factor. Linear wrt. vertices.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- T& <b>move</b>(T& polygon, orientation_2d,<br />
- coordinate_difference displacement)</font></td>
- <td>Adds displacement value to coordinate indicated by orientation_2d of
- vertices of an object that models polygon_90 . Linear wrt.
- vertices.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename polygon_type, typename point_type><br />
- polygon_type& <b>convolve</b>(polygon_type& polygon,<br />
+ <font face="Courier New">};</font></p>
+ <p>An object that is a model of <font face="Courier New">
+polygon_90_concept</font> can be viewed as a model of any of its
+refinements if it is determined at runtime to conform to the
+restriction of those concepts. This concept casting is
+accomplished through the
+ <font face="Courier New">view_as<>()</font> function.</p>
+ <p><font face="Courier New">view_as<rectangle_concept>(polygon_90_object)</font></p>
+ <p>The return value of <font face="Courier New">view_as<>()</font>
+can be passed into any interface that expects an object of the
+conceptual type specified in its template parameter.</p>
+ <h2>Functions</h2>
+ <table id="table1" border="1" width="100%">
+ <tbody>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+compact_iterator_type <b>begin_compact</b>(const T& polygon)</font></td>
+ <td><font face="Times New Roman">Expects a model of
+polygon_90. Returns the begin iterator over the range of
+coordinates that correspond to horizontal and vertical edges.</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+compact_iterator_type <b>end_compact</b>(const T& polygon)</font></td>
+ <td><font face="Times New Roman">Expects a model of
+polygon_90. Returns the end iterator over the range of
+coordinates that correspond to horizontal and vertical edges.</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+point_iterator_type <b>begin_points</b>(const T& polygon)</font></td>
+ <td><font face="Times New Roman">Expects a model of
+polygon_90. Returns the begin iterator over the range of points
+that correspond to vertices of the polygon.</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+point_iterator_type <b>end_points</b>(const T& polygon)</font></td>
+ <td><font face="Times New Roman">Expects a model of
+polygon_90. Returns the end iterator over the range of points
+that correspond to vertices of the polygon.</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename iterator><br />
+void <b>set_compact</b>(T& polygon, iterator b, iterator e)</font></td>
+ <td><font face="Times New Roman">Expects a model of
+polygon_90. Sets the polygon to the coordinate data range
+[b,e) that corresponds to .horizontal and vertical edges.</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename iterator><br />
+void <b>set_points</b>(T& polygon, iterator b, iterator e)</font></td>
+ <td><font face="Times New Roman">Expects a model of
+polygon_90. Sets the polygon to the point data range [b,e)
+that corresponds to vertices of a manhattan polygon.
+Non-manhattan edges between successive input points results in
+undefined behavior.</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+unsigned int <b>size</b>(const T& polygon)</font></td>
+ <td><font face="Times New Roman">Returns the number of
+edges in the polygon.</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+T1& <b>assign</b>(T1& left, const T2& right)</font></td>
+ <td>Copies data from right object that models polygon_90
+into left object that models polygon_90.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename point_type><br />
+bool <b>contains</b>(const T&, const point_type& point, <br />
+
+bool consider_touch=true)</font></td>
+ <td>Given an object that models polygon_90 and an object
+that models point, returns true if the polygon contains the
+point. If the consider_touch flag is true will return true if the
+point lies along the boundary of the polygon. Linear wrt.
+vertices.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">// get the center
+coordinate<br />
+template <typename T, typename point_type><br />
+void <b>center</b>(point_type& p, const T& polygon)</font></td>
+ <td>Sets object that models point to the center point of
+the bounding box of an object that models polygon_90. Linear wrt.
+vertices.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename rectangle_type><br />
+bool <b>extents</b>(rectangle_type& bbox, const T& polygon)</font></td>
+ <td>Sets object that models rectangle to the bounding box
+of an object that models polygon_90 and returns true. Returns
+false and leaves bbox unchanged if polygon is empty. Linear wrt.
+vertices.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+manhattan_area_type <b>area</b>(const T& polygon)</font></td>
+ <td>Returns the area of an object that models
+polygon_90. Linear wrt. vertices.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+direction_1d <b>winding</b>(const T& polygon)</font></td>
+ <td>Returns the winding direction of an object that models
+polygon_90, LOW == CLOCKWISE, HIGH = COUNTERCLOCKWISE. Complexity
+depends upon winding trait.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+coordinate_difference <b>perimeter</b>(const T& polygon)</font></td>
+ <td>Returns the perimeter length of an object that models
+polygon_90. Linear wrt. vertices.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename transform_type><br />
+T& <b>transform</b>(T& polygon, const transform_type&)</font></td>
+ <td>Applies transform() on the vertices of polygon and sets
+the polygon to that described by the result of transforming its
+vertices. Linear wrt. vertices.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+T& <b>scale_up</b>(T& polygon, unsigned_area_type factor)</font></td>
+ <td>Scales up coordinate of an object that models
+polygon_90 by unsigned factor. Linear wrt. vertices.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+T& <b>scale_down</b>(T& polygon, unsigned_area_type factor)</font></td>
+ <td>Scales down coordinates of an object that models
+polygon_90 by unsigned factor. Linear wrt. vertices.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, scaling_type><br />
+T& <b>scale</b>(T& rectangle, double scaling) </font></td>
+ <td>Scales coordinates of an object that models polygon_90
+by floating point factor. Linear wrt. vertices.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+T& <b>move</b>(T& polygon, orientation_2d,<br />
+ coordinate_difference
+displacement)</font></td>
+ <td>Adds displacement value to coordinate indicated by
+orientation_2d of vertices of an object that models polygon_90 .
+Linear wrt. vertices.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename polygon_type, typename point_type><br />
+polygon_type& <b>convolve</b>(polygon_type& polygon,<br />
+
const point_type& point)</font></td>
- <td>Convolves coordinate values of point with vertices of an
- object that models polygon_90. Linear wrt. vertices.</td>
- </tr>
- </tbody></table>
- <h1>Polygon 90 Data</h1>
-
-<p>
-</p><p>The library provides a model of polygon 90 concept declared
-<font face="Courier New">
-template<typename T> polygon_90_data </font>where T is the coordinate type.</p>
-<p>This data type is used internally when a Manhattan polygon is needed and is
-available to the library user who finds it convenient to use a library polygon
-data type instead of providing their own. The data type is implemented to
-be convenient to use with the library traits.</p>
-<h2>Members</h2>
-<table id="table2" border="1" width="100%">
- <tbody><tr>
- <td width="586"><b><font face="Courier New">geometry_type</font></b></td>
- <td><font face="Times New Roman">polygon_90_concept</font></td>
- </tr>
- <tr>
- <td width="586"><b><font face="Courier New">coordinate_type</font></b></td>
- <td><font face="Times New Roman">T</font></td>
- </tr>
- <tr>
- <td width="586"><b><font face="Courier New">iterator_type</font></b></td>
- <td>Iterator over vertices point_data<T> vertices of polygon</td>
- </tr>
- <tr>
- <td width="586"><b><font face="Courier New">compact_iterator_type</font></b></td>
- <td><font face="Times New Roman">Iterator over non-redundant coordinates
- of the polygon, alternating x, y, x, y starting with an x, where each x
- corresponds to a vertical edge and each y corresponds to a horizontal
- edge.</font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New"><b>polygon_90_data</b>()</font></td>
- <td><font face="Times New Roman">Default constructs the </font>polygon.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New"><b>polygon_90_data</b>(const
- polygon_90_data& that)</font></td>
- <td><font face="Times New Roman">Copy construct</font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">polygon_90_data& <b>operator=</b>(const
- polygon_90_data& that)</font></td>
- <td>Assignment operator.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T2><b>
- <br /> </b>polygon_90_data& <b>operator=</b>(const T2& that) const</font></td>
- <td>Assign from an object that is a model of polygon 90.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">iterator_type <b>begin</b>()
- const</font></td>
- <td>Get the begin iterator over vertices of the polygon.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">iterator_type <b>end</b>()
- const</font></td>
- <td>Get the end iterator over vertices of the polygon.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">compact_iterator_type <b>
- begin_compact</b>() const</font></td>
- <td>Get the begin compact iterator over non-redundant coordinates of the
- polygon.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">compact_iterator_type <b>
- end_compact</b>() const</font></td>
- <td>Get the end compact iterator over non-redundant coordinates of the
- polygon.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">std::size_t <b>size</b>() const</font></td>
- <td>Get the number of elements in the sequence stored to the polygon,
- usually equal to the number of edges of the polygon.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename iT><b>
- <br /> </b>void <b>set</b>(iT begin_points, iT end_points)</font></td>
- <td>Sets the polygon to the iterator range of points. No check is
- performed to ensure the points describe a Manhattan figure, every other
- x and y value of the points is used to initialize the polygon.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename iT><b>
- <br /> </b>void <b>set_compact</b>(iT begin_coords, iT end_coords)</font></td>
- <td>Sets the polygon to the iterator range of coordinates. These
- coordinates correspond to the x values of vertical edges and y values of
- horizontal edges. It is expected that the sequence start with an x
- value and proceed x then y then x then y.</td>
- </tr>
-</tbody></table>
- </td></tr><tr>
-<td style="background-color: rgb(238, 238, 238);" nowrap="1" valign="top">
- </td>
-<td style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;" valign="top" width="100%">
-
-
-<table class="docinfo" id="table3" frame="void" rules="none">
- <colgroup>
- <col class="docinfo-name" /><col class="docinfo-content" />
- </colgroup>
- <tbody valign="top">
- <tr>
- <th class="docinfo-name">Copyright:</th>
- <td>Copyright © Intel Corporation 2008-2010.</td>
- </tr>
- <tr class="field">
- <th class="docinfo-name">License:</th>
- <td class="field-body">Distributed under the Boost Software License,
- Version 1.0. (See accompanying file <tt class="literal">
- <span class="pre">LICENSE_1_0.txt</span></tt> or copy at
- <a class="reference" target="_top" href="http://www.boost.org/LICENSE_1_0.txt">
- http://www.boost.org/LICENSE_1_0.txt>)</td>
- </tr>
-</tbody></table>
-
-</td></tr></tbody></table></body></html>
\ No newline at end of file
+ <td>Convolves coordinate values of point with vertices of
+an object that models polygon_90. Linear wrt. vertices.</td>
+ </tr>
+ </tbody>
+ </table>
+ <h1>Polygon 90 Data</h1>
+ <p> </p>
+ <p>The library provides a model of polygon 90 concept declared
+ <font face="Courier New">template<typename T>
+polygon_90_data </font>where T is the coordinate type.</p>
+ <p>This data type is used internally when a Manhattan polygon is
+needed and is available to the library user who finds it convenient to
+use a library polygon data type instead of providing their own.
+The data type is implemented to be convenient to use with the library
+traits.</p>
+ <h2>Members</h2>
+ <table id="table2" border="1" width="100%">
+ <tbody>
+ <tr>
+ <td width="586"><b><font face="Courier New">geometry_type</font></b></td>
+ <td><font face="Times New Roman">polygon_90_concept</font></td>
+ </tr>
+ <tr>
+ <td width="586"><b><font face="Courier New">coordinate_type</font></b></td>
+ <td><font face="Times New Roman">T</font></td>
+ </tr>
+ <tr>
+ <td width="586"><b><font face="Courier New">iterator_type</font></b></td>
+ <td>Iterator over vertices point_data<T> vertices of
+polygon</td>
+ </tr>
+ <tr>
+ <td width="586"><b><font face="Courier New">compact_iterator_type</font></b></td>
+ <td><font face="Times New Roman">Iterator over
+non-redundant coordinates of the polygon, alternating x, y, x, y
+starting with an x, where each x corresponds to a vertical edge and
+each y corresponds to a horizontal edge.</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New"><b>polygon_90_data</b>()</font></td>
+ <td><font face="Times New Roman">Default constructs the </font>polygon.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New"><b>polygon_90_data</b>(const
+polygon_90_data& that)</font></td>
+ <td><font face="Times New Roman">Copy construct</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">polygon_90_data&
+ <b>operator=</b>(const polygon_90_data& that)</font></td>
+ <td>Assignment operator.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T2><b> <br />
+ </b>polygon_90_data& <b>operator=</b>(const T2&
+that) const</font></td>
+ <td>Assign from an object that is a model of polygon 90.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">iterator_type <b>begin</b>()
+const</font></td>
+ <td>Get the begin iterator over vertices of the polygon.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">iterator_type <b>end</b>()
+const</font></td>
+ <td>Get the end iterator over vertices of the polygon.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">compact_iterator_type
+ <b> begin_compact</b>() const</font></td>
+ <td>Get the begin compact iterator over non-redundant
+coordinates of the polygon.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">compact_iterator_type
+ <b> end_compact</b>() const</font></td>
+ <td>Get the end compact iterator over non-redundant
+coordinates of the polygon.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">std::size_t <b>size</b>()
+const</font></td>
+ <td>Get the number of elements in the sequence stored to
+the polygon, usually equal to the number of edges of the polygon.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename iT><b> <br />
+ </b>void <b>set</b>(iT begin_points, iT end_points)</font></td>
+ <td>Sets the polygon to the iterator range of points.
+No check is performed to ensure the points describe a Manhattan figure,
+every other x and y value of the points is used to initialize the
+polygon.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename iT><b> <br />
+ </b>void <b>set_compact</b>(iT begin_coords, iT end_coords)</font></td>
+ <td>Sets the polygon to the iterator range of
+coordinates. These coordinates correspond to the x values of
+vertical edges and y values of horizontal edges. It is expected
+that the sequence start with an x value and proceed x then y then x
+then y.</td>
+ </tr>
+ </tbody>
+ </table>
+ </td>
+ </tr>
+ <tr>
+ <td style="background-color: rgb(238, 238, 238);" nowrap="1"
+ valign="top"> </td>
+ <td
+ style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;"
+ valign="top" width="100%">
+ <table class="docinfo" id="table3" frame="void" rules="none">
+ <colgroup> <col class="docinfo-name" /><col
+ class="docinfo-content" /> </colgroup> <tbody valign="top">
+ <tr>
+ <th class="docinfo-name">Copyright:</th>
+ <td>Copyright © Intel Corporation 2008-2010.</td>
+ </tr>
+ <tr class="field">
+ <th class="docinfo-name">License:</th>
+ <td class="field-body">Distributed under the Boost Software
+License, Version 1.0. (See accompanying file <tt class="literal"> <span
+ class="pre">LICENSE_1_0.txt</span></tt> or copy at <a
+ class="reference" target="_top"
+ href="http://www.boost.org/LICENSE_1_0.txt">
+http://www.boost.org/LICENSE_1_0.txt>)</td>
+ </tr>
+ </tbody>
+ </table>
+ </td>
+ </tr>
+ </tbody>
+</table>
+</body>
+</html>
Modified: branches/release/libs/polygon/doc/gtl_polygon_90_set_concept.htm
==============================================================================
--- branches/release/libs/polygon/doc/gtl_polygon_90_set_concept.htm (original)
+++ branches/release/libs/polygon/doc/gtl_polygon_90_set_concept.htm 2013-04-15 18:27:46 EDT (Mon, 15 Apr 2013)
@@ -1,917 +1,1016 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:(null)1="http://www.w3.org/TR/REC-html40" lang="en"><head>
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"
+ xmlns:v="urn:schemas-microsoft-com:vml"
+ xmlns:o="urn:schemas-microsoft-com:office:office"
+ xmlns:(null)1="http://www.w3.org/TR/REC-html40" lang="en">
+<head>
<!--
Copyright 2009-2010 Intel Corporation
license banner
---><title>Boost Polygon Library: Polygon 90 Set Concept</title>
-
-
-
- <meta http-equiv="content-type" content="text/html;charset=ISO-8859-1" /><!-- <link type="text/css" rel="stylesheet" href="adobe_source.css"> --></head><body><table style="margin: 0pt; padding: 0pt; width: 100%;" border="0" cellpadding="0" cellspacing="0"><tbody><tr>
-<td style="background-color: rgb(238, 238, 238);" nowrap="1" valign="top">
- <div style="padding: 5px;" align="center">
- <img src="images/boost.png" border="0" height="86" width="277" /><a title="www.boost.org home page" href="http://www.boost.org/" tabindex="2" style="border: medium none ;">
- </a>
- </div>
- <div style="margin: 5px;">
- <h3 class="navbar">Contents</h3>
- <ul>
- <li>Boost.Polygon Main Page</li>
- <li>Design Overview</li>
- <li>Isotropy</li>
- <li>Coordinate Concept</li>
- <li>Interval Concept</li>
- <li>Point Concept</li>
+-->
+ <title>Boost Polygon Library: Polygon 90 Set Concept</title>
+ <meta http-equiv="content-type" content="text/html;charset=ISO-8859-1" />
+<!-- <link type="text/css" rel="stylesheet" href="adobe_source.css"> -->
+</head>
+<body>
+<table style="margin: 0pt; padding: 0pt; width: 100%;" border="0"
+ cellpadding="0" cellspacing="0">
+ <tbody>
+ <tr>
+ <td style="background-color: rgb(238, 238, 238);" nowrap="1"
+ valign="top">
+ <div style="padding: 5px;" align="center"> <img
+ src="images/boost.png" border="0" height="86" width="277" /><a
+ title="www.boost.org home page" href="http://www.boost.org/"
+ tabindex="2" style="border: medium none ;"> </a> </div>
+ <div style="margin: 5px;">
+ <h3 class="navbar">Contents</h3>
+ <ul>
+ <li>Boost.Polygon Main Page</li>
+ <li>Design Overview</li>
+ <li>Isotropy</li>
+ <li>Coordinate Concept</li>
+ <li>Interval Concept</li>
+ <li>Point Concept</li>
<li>Segment Concept</li>
-
- <li>Rectangle Concept</li>
- <li>Polygon 90 Concept</li>
- <li>Polygon 90 With Holes Concept</li>
- <li>Polygon 45 Concept</li>
- <li>Polygon 45 With Holes Concept</li>
- <li>Polygon Concept</li>
- <li>Polygon With Holes Concept</li>
- <li>Polygon 90 Set Concept</li>
- <li>Polygon 45 Set Concept</li>
- <li>Polygon Set Concept</li>
- <li>Connectivity Extraction 90</li>
- <li>Connectivity Extraction 45</li>
- <li>Connectivity Extraction</li>
- <li>Property Merge 90</li>
- <li>Property Merge 45</li>
- <li>Property Merge</li>
+ <li>Rectangle Concept</li>
+ <li>Polygon 90 Concept</li>
+ <li><a href="gtl_polygon_90_with_holes_concept.htm">Polygon 90
+With Holes Concept</a></li>
+ <li>Polygon 45 Concept</li>
+ <li><a href="gtl_polygon_45_with_holes_concept.htm">Polygon 45
+With Holes Concept</a></li>
+ <li>Polygon Concept</li>
+ <li><a href="gtl_polygon_with_holes_concept.htm">Polygon With
+Holes Concept</a></li>
+ <li>Polygon 90 Set Concept</li>
+ <li><a href="gtl_polygon_45_set_concept.htm">Polygon 45 Set
+Concept</a></li>
+ <li>Polygon Set Concept</li>
+ <li><a href="gtl_connectivity_extraction_90.htm">Connectivity
+Extraction 90</a></li>
+ <li><a href="gtl_connectivity_extraction_45.htm">Connectivity
+Extraction 45</a></li>
+ <li><a href="gtl_connectivity_extraction.htm">Connectivity
+Extraction</a></li>
+ <li>Property Merge 90</li>
+ <li>Property Merge 45</li>
+ <li>Property Merge</li>
<li><a href="voronoi_main.htm">Voronoi Main Page<br />
-</a></li>
+ </a></li>
<li>Voronoi Benchmark<br />
</li>
<li>Voronoi Builder</li>
- <li><a href="voronoi_diagram.htm">Voronoi Diagram<br />
-</a></li>
- <li>Voronoi Predicates</li>
- <li>Voronoi Robust FPT<br />
- </li>
-
-
- </ul>
- <h3 class="navbar">Other Resources</h3>
- <ul>
+ <li>Voronoi Diagram</li>
+ </ul>
+ <h3 class="navbar">Other Resources</h3>
+ <ul>
<li>GTL Boostcon 2009 Paper</li>
- <li><a href="GTL_boostcon_draft03.pdf">GTL Boostcon 2009
- Presentation</a></li>
+ <li><a href="GTL_boostcon_draft03.pdf">GTL Boostcon 2009
+Presentation</a></li>
<li>Performance Analysis</li>
<li>Layout Versus Schematic Tutorial</li>
<li>Minkowski Sum Tutorial</li>
<li>Voronoi Basic Tutorial</li>
- <li>Voronoi Advanced Tutorial</li>
-</ul>
- </div>
- <h3 class="navbar">Polygon Sponsor</h3>
- <div style="padding: 5px;" align="center">
- <img src="images/intlogo.gif" border="0" height="51" width="127" /><a title="www.adobe.com home page" href="http://www.adobe.com/" tabindex="2" style="border: medium none ;">
- </a>
- </div>
-</td>
-<td style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;" valign="top" width="100%">
-
-<!-- End Header -->
-
-<br />
-<p>
-</p><h1>Polygon 90 Set Concept</h1>
-
-<p>
-</p><p>The polygon_90_set concept tag is <font face="Courier New">
+ <li><a href="voronoi_advanced_tutorial.htm">Voronoi Advanced
+Tutorial</a></li>
+ </ul>
+ </div>
+ <h3 class="navbar">Polygon Sponsor</h3>
+ <div style="padding: 5px;" align="center"> <img
+ src="images/intlogo.gif" border="0" height="51" width="127" /><a
+ title="www.adobe.com home page" href="http://www.adobe.com/"
+ tabindex="2" style="border: medium none ;"> </a> </div>
+ </td>
+ <td
+ style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;"
+ valign="top" width="100%">
+<!-- End Header --><br />
+ <p>
+ </p>
+ <h1>Polygon 90 Set Concept</h1>
+ <p> </p>
+ <p>The polygon_90_set concept tag is <font face="Courier New">
polygon_90_set_concept</font></p>
-<p>
-<font face="Times New Roman">The semantic of a polygon_90_set is zero or more
-Manhattan geometry regions.</font></p><p>
-<font face="Times New Roman">The motivation for providing the
-polygon_90_set_concept is that it is a very common special case of planar
-geometry which afford the implementation of a variety of optimizations on the
-general planar geometry algorithms. Manhattan geometry processing by the
-polygon_90_set_concept can be 100X faster than arbitrary angle polygon
-manipulation. Because the performance benefits are so large and the
-special case is important enough, the library provides these performance
-benefits for those application domains that require them.</font></p><p>Users are recommended to use std::vector and std::list of user defined polygons
-or library provided polygon_90_set_data<coordinate_type> objects. Lists
-and vectors of models of polygon_90_concept or polygon_90_with_holes_concept or
-rectangle_concept are automatically models of polygon_90_set_concept.</p>
-<h2>Operators</h2>
-<p>The return type of some operators is the <font face="Courier New">polygon_90_set_view</font>
-operator template type. This type is itself a model of the polygon_90_set
-concept, but furthermore can be used as an argument to the <font face="Courier New">polygon_90_set_data</font>
-constructor and assignment operator. The operator template exists to
-eliminate temp copies of intermediate results when Boolean operators are chained
+ <p> <font face="Times New Roman">The semantic of a
+polygon_90_set is zero or more Manhattan geometry regions.</font></p>
+ <p> <font face="Times New Roman">The motivation for providing
+the polygon_90_set_concept is that it is a very common special case of
+planar geometry which afford the implementation of a variety of
+optimizations on the general planar geometry algorithms.
+Manhattan geometry processing by the polygon_90_set_concept can be 100X
+faster than arbitrary angle polygon manipulation. Because the
+performance benefits are so large and the special case is important
+enough, the library provides these performance benefits for those
+application domains that require them.</font></p>
+ <p>Users are recommended to use std::vector and std::list of user
+defined polygons or library provided
+polygon_90_set_data<coordinate_type> objects. Lists and
+vectors of models of polygon_90_concept or
+polygon_90_with_holes_concept or rectangle_concept are automatically
+models of polygon_90_set_concept.</p>
+ <h2>Operators</h2>
+ <p>The return type of some operators is the <font
+ face="Courier New">polygon_90_set_view</font> operator template
+type. This type is itself a model of the polygon_90_set concept,
+but furthermore can be used as an argument to the <font
+ face="Courier New">polygon_90_set_data</font> constructor and
+assignment operator. The operator template exists to eliminate
+temp copies of intermediate results when Boolean operators are chained
together.</p>
-<p>Operators are declared inside the namespace <font face="Courier New">boost::polygon::operators</font>.</p>
-<table id="table3" border="1" width="100%">
- <tbody><tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- polygon_90_set_view <b>operator</b>|(const T1& l, const T2& r)</font></td>
- <td>Boolean OR operation (polygon set union). Accepts two objects
- that model polygon_90_set or one of its refinements. Returns an
- operator template that performs the operation on demand when chained or
- or nested in a library function call such as assign(). O( n log n)
- runtime complexity and O(n) memory wrt vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- polygon_90_set_view <b>operator</b>+(const T1& l, const T2& r)</font></td>
- <td>Same as operator|. The plus sign is also used for OR
- operations in Boolean logic expressions. O( n log n) runtime
- complexity and O(n) memory wrt vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- polygon_90_set_view <b>operator</b>&(const T1& l, const T2& r)</font></td>
- <td>Boolean AND operation (polygon set intersection). Accepts two
- objects that model polygon_90_set or one of its refinements. O( n
- log n) runtime complexity and O(n) memory wrt vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- polygon_90_set_view <b>operator</b>*(const T1& l, const T2& r)</font></td>
- <td>Same as operator&. The multiplication symbol is also used for
- AND operations in Boolean logic expressions. O( n log n) runtime
- complexity and O(n) memory wrt vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- polygon_90_set_view <b>operator</b>^(const T1& l, const T2& r)</font></td>
- <td>Boolean XOR operation (polygon set disjoint-union). Accepts
- two objects that model polygon_90_set or one of its refinements.
- O( n log n) runtime complexity and O(n) memory wrt vertices +
- intersections. O( n log n) runtime complexity and O(n) memory wrt
- vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- polygon_90_set_view <b>operator</b>-(const T1& l, const T2& r)</font></td>
- <td>Boolean SUBTRACT operation (polygon set difference). Accepts
- two objects that model polygon_90_set or one of its refinements.
- O( n log n) runtime complexity and O(n) memory wrt vertices +
- intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- T1& <b>operator</b>|=(const T1& l, const T2& r)</font></td>
- <td>Same as operator|, but with self assignment, left operand must model
- polygon_90_set and not one of it's refinements. O( n log n)
- runtime complexity and O(n) memory wrt vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- T1& <b>operator</b>+=(T1& l, const T2& r)</font></td>
- <td>Same as operator+, but with self assignment, left operand must model
- polygon_90_set and not one of it's refinements. O( n log n)
- runtime complexity and O(n) memory wrt vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- T1& <b>operator</b>&=(const T1& l, const T2& r)</font></td>
- <td>Same as operator&, but with self assignment, left operand must model
- polygon_90_set and not one of it's refinements. O( n log n)
- runtime complexity and O(n) memory wrt vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- T1& <b>operator</b>*=(T1& l, const T2& r)</font></td>
- <td>Same as operator*, but with self assignment, left operand must model
- polygon_90_set and not one of it's refinements. O( n log n)
- runtime complexity and O(n) memory wrt vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- T1& <b>operator</b>^=(const T1& l, const T2& r)</font></td>
- <td>Same as operator^, but with self assignment, left operand must model
- polygon_90_set and not one of it's refinements. O( n log n)
- runtime complexity and O(n) memory wrt vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- T1& <b>operator</b>-=(T1& l, const T2& r)</font></td>
- <td>Same as operator-, but with self assignment, left operand must model
- polygon_90_set and not one of it's refinements. O( n log n)
- runtime complexity and O(n) memory wrt vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1><br />
- T1 <b>operator</b>+(const T1&, coordinate_type bloating)</font></td>
- <td>Performs resize operation, inflating by bloating ammount. If
- negative the result is a shrink instead of bloat. Note: returns
- result by value. O( n log n) runtime complexity and O(n) memory
- wrt vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- T1 <b>operator</b>-(const T1&, coordinate_type shrinking)</font></td>
- <td>Performs resize operation, deflating by bloating ammount. If
- negative the result is a bloat instead of shrink. Note: returns
- result by value. O( n log n) runtime complexity and O(n) memory
- wrt vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- T1& <b>operator</b>+=(const T1&, coordinate_type bloating)</font></td>
- <td>Performs resize operation, inflating by bloating ammount. If
- negative the result is a shrink instead of bloat. Returns
- reference to modified argument. O( n log n) runtime complexity and
- O(n) memory wrt vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- T1& <b>operator</b>-=(const T1&, coordinate_type shrinking)</font></td>
- <td>Performs resize operation, deflating by bloating ammount. If
- negative the result is a bloat instead of shrink. Returns
- reference to modified argument. O( n log n) runtime complexity and
- O(n) memory wrt vertices + intersections.</td>
- </tr>
- </tbody></table>
-<h2>Functions</h2>
-<table id="table1" border="1" width="100%">
- <tbody><tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- T1& <b>assign</b>(T1& lvalue, const T2& rvalue)</font></td>
- <td>Eliminates overlaps in geometry and copies from an object that
- models polygon_90_set or any of its refinements into an object that
- models polygon_90_set. O( n log n) runtime complexity and O(n)
- memory wrt vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- bool <b>equivalence</b>(const T1& lvalue, const T2& rvalue) </font></td>
- <td>Returns true if an object that models polygon_90_set or one of its
- refinements covers the exact same geometric regions as another object
- that models polygon_90_set or one of its refinements. For example:
- two of polygon_90 objects. O( n log n) runtime complexity and O(n)
- memory wrt vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename
- output_container_type, typename T><br />
- void <b>get_rectangles</b>(output_container_type& output, <br />
-
- const T& polygon_set)</font></td>
- <td>Output container is expected to be a standard container.
- Slices geometry of an object that models polygon_90_set or one of its
- refinements into non overlapping rectangles and appends them to the
- output. O( n log n) runtime complexity and O(n) memory wrt
- vertices + intersections. </td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename
- output_container_type, typename T><br />
- void <b>get_max_rectangles</b>(output_container_type& output, <br />
+ <p>Operators are declared inside the namespace <font
+ face="Courier New">boost::polygon::operators</font>.</p>
+ <table id="table3" border="1" width="100%">
+ <tbody>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+polygon_90_set_view <b>operator</b>|(const T1& l, const T2& r)</font></td>
+ <td>Boolean OR operation (polygon set union). Accepts
+two objects that model polygon_90_set or one of its refinements.
+Returns an operator template that performs the operation on demand when
+chained or or nested in a library function call such as assign().
+O( n log n) runtime complexity and O(n) memory wrt vertices +
+intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+polygon_90_set_view <b>operator</b>+(const T1& l, const T2& r)</font></td>
+ <td>Same as operator|. The plus sign is also used for
+OR operations in Boolean logic expressions. O( n log n) runtime
+complexity and O(n) memory wrt vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+polygon_90_set_view <b>operator</b>&(const T1& l, const
+T2& r)</font></td>
+ <td>Boolean AND operation (polygon set intersection).
+Accepts two objects that model polygon_90_set or one of its
+refinements. O( n log n) runtime complexity and O(n) memory wrt
+vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+polygon_90_set_view <b>operator</b>*(const T1& l, const T2& r)</font></td>
+ <td>Same as operator&. The multiplication symbol
+is also used for AND operations in Boolean logic expressions. O(
+n log n) runtime complexity and O(n) memory wrt vertices +
+intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+polygon_90_set_view <b>operator</b>^(const T1& l, const T2& r)</font></td>
+ <td>Boolean XOR operation (polygon set
+disjoint-union). Accepts two objects that model polygon_90_set or
+one of its refinements. O( n log n) runtime complexity and O(n)
+memory wrt vertices + intersections. O( n log n) runtime
+complexity and O(n) memory wrt vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+polygon_90_set_view <b>operator</b>-(const T1& l, const T2& r)</font></td>
+ <td>Boolean SUBTRACT operation (polygon set
+difference). Accepts two objects that model polygon_90_set or one
+of its refinements. O( n log n) runtime complexity and O(n)
+memory wrt vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+T1& <b>operator</b>|=(const T1& l, const T2& r)</font></td>
+ <td>Same as operator|, but with self assignment, left
+operand must model polygon_90_set and not one of it's
+refinements. O( n log n) runtime complexity and O(n) memory wrt
+vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+T1& <b>operator</b>+=(T1& l, const T2& r)</font></td>
+ <td>Same as operator+, but with self assignment, left
+operand must model polygon_90_set and not one of it's
+refinements. O( n log n) runtime complexity and O(n) memory wrt
+vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+T1& <b>operator</b>&=(const T1& l, const T2& r)</font></td>
+ <td>Same as operator&, but with self assignment, left
+operand must model polygon_90_set and not one of it's
+refinements. O( n log n) runtime complexity and O(n) memory wrt
+vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+T1& <b>operator</b>*=(T1& l, const T2& r)</font></td>
+ <td>Same as operator*, but with self assignment, left
+operand must model polygon_90_set and not one of it's
+refinements. O( n log n) runtime complexity and O(n) memory wrt
+vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+T1& <b>operator</b>^=(const T1& l, const T2& r)</font></td>
+ <td>Same as operator^, but with self assignment, left
+operand must model polygon_90_set and not one of it's
+refinements. O( n log n) runtime complexity and O(n) memory wrt
+vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+T1& <b>operator</b>-=(T1& l, const T2& r)</font></td>
+ <td>Same as operator-, but with self assignment, left
+operand must model polygon_90_set and not one of it's
+refinements. O( n log n) runtime complexity and O(n) memory wrt
+vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1><br />
+T1 <b>operator</b>+(const T1&, coordinate_type bloating)</font></td>
+ <td>Performs resize operation, inflating by bloating
+ammount. If negative the result is a shrink instead of
+bloat. Note: returns result by value. O( n log n) runtime
+complexity and O(n) memory wrt vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+T1 <b>operator</b>-(const T1&, coordinate_type shrinking)</font></td>
+ <td>Performs resize operation, deflating by bloating
+ammount. If negative the result is a bloat instead of
+shrink. Note: returns result by value. O( n log n) runtime
+complexity and O(n) memory wrt vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+T1& <b>operator</b>+=(const T1&, coordinate_type bloating)</font></td>
+ <td>Performs resize operation, inflating by bloating
+ammount. If negative the result is a shrink instead of
+bloat. Returns reference to modified argument. O( n log n)
+runtime complexity and O(n) memory wrt vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+T1& <b>operator</b>-=(const T1&, coordinate_type shrinking)</font></td>
+ <td>Performs resize operation, deflating by bloating
+ammount. If negative the result is a bloat instead of
+shrink. Returns reference to modified argument. O( n log n)
+runtime complexity and O(n) memory wrt vertices + intersections.</td>
+ </tr>
+ </tbody>
+ </table>
+ <h2>Functions</h2>
+ <table id="table1" border="1" width="100%">
+ <tbody>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+T1& <b>assign</b>(T1& lvalue, const T2& rvalue)</font></td>
+ <td>Eliminates overlaps in geometry and copies from an
+object that models polygon_90_set or any of its refinements into an
+object that models polygon_90_set. O( n log n) runtime complexity
+and O(n) memory wrt vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+bool <b>equivalence</b>(const T1& lvalue, const T2& rvalue) </font></td>
+ <td>Returns true if an object that models polygon_90_set or
+one of its refinements covers the exact same geometric regions as
+another object that models polygon_90_set or one of its
+refinements. For example: two of polygon_90 objects. O( n
+log n) runtime complexity and O(n) memory wrt vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename output_container_type, typename T><br />
+void <b>get_rectangles</b>(output_container_type& output, <br />
+
+const T& polygon_set)</font></td>
+ <td>Output container is expected to be a standard
+container. Slices geometry of an object that models
+polygon_90_set or one of its refinements into non overlapping
+rectangles and appends them to the output. O( n log n) runtime
+complexity and O(n) memory wrt vertices + intersections. </td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename output_container_type, typename T><br />
+void <b>get_max_rectangles</b>(output_container_type& output, <br />
+
+const T& polygon_set)</font></td>
+ <td>Output container is expected to be a standard
+container. Given an object that models polygon_90_set or one of
+its refinements finds all overlapping rectangles that are maximal in
+area and appends them to the output. Expected n log n runtime,
+worst case quadratic rutnime.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename polygon_set_type><br />
+void <b>clear</b>(polygon_set_type& polygon_set)</font></td>
+ <td>Makes the object empty of geometry.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename polygon_set_type><br />
+bool <b>empty</b>(const polygon_set_type& polygon_set)</font></td>
+ <td>Checks whether the object is empty of geometry.
+Polygons that are completely covered by holes will result in empty
+returning true. O( n log n) runtime complexity and O(n) memory
+wrt vertices + intersections. </td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename rectangle_type><br />
+bool <b>extents</b>(rectangle_type& extents_rectangle, <br />
+
const T& polygon_set)</font></td>
- <td>Output container is expected to be a standard container. Given
- an object that models polygon_90_set or one of its refinements finds all
- overlapping rectangles that are maximal in area and appends them to the
- output. Expected n log n runtime, worst case quadratic rutnime.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename
- polygon_set_type><br />
- void <b>clear</b>(polygon_set_type& polygon_set)</font></td>
- <td>Makes the object empty of geometry.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename
- polygon_set_type><br />
- bool <b>empty</b>(const polygon_set_type& polygon_set)</font></td>
- <td>Checks whether the object is empty of geometry. Polygons that
- are completely covered by holes will result in empty returning true.
- O( n log n) runtime complexity and O(n) memory wrt vertices +
- intersections. </td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T, typename
- rectangle_type><br />
- bool <b>extents</b>(rectangle_type& extents_rectangle, <br />
- const
- T& polygon_set)</font></td>
- <td>Computes bounding box of an object that models polygon_90_set and
- stores it in an object that models rectangle. If the polygon set
- is empty returns false. If there are holes outside of shells they
- do not contribute to the extents of the polygon set. O( n log n)
- runtime complexity and O(n) memory wrt vertices + intersections. </td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- manhattan_area_type <b>area</b>(const T& polygon_set)</font></td>
- <td>Computes the area covered by geometry in an object that models
- polygon_90_set. O( n log n) runtime complexity and O(n) memory wrt
- vertices + intersections. </td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- T1& <b>interact</b>(T1& a, const T2& b)</font></td>
- <td>Given an object that models polygon_90_set and an object that models
- polygon_90_set or one of its refinements, modifies a to retain only
- regions that overlap or touch regions in b. O( n log n) runtime
- complexity and O(n) memory wrt vertices + intersections. </td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- T& <b>self_intersect</b>(T& polygon_set)</font></td>
- <td>Given an object that models polygon_90_set that has self overlapping
- regions, modifies the argument to contain only the regions of overlap.
- O( n log n) runtime complexity and O(n) memory wrt vertices +
- intersections. </td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- T& <b>self_xor</b>(T& polygon_set)</font></td>
- <td>Given an object that models polygon_90_set that has self overlapping
- regions, modifies the argument to contain only the regions that do not
- overlap. O( n log n) runtime complexity and O(n) memory wrt
- vertices + intersections. </td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- T& <b>bloat</b>(T& polygon_set, unsigned_area_type bloating)</font></td>
- <td>Same as getting all the rectangles, bloating them and putting them
- back. O( n log n) runtime complexity and O(n) memory wrt vertices
- + intersections. </td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- T& <b>bloat</b>(T& polygon_set, orientation_2d orient,<br />
- unsigned_area_type bloating)</font></td>
- <td>Same as getting all the rectangles, bloating them and putting them
- back. O( n log n) runtime complexity and O(n) memory wrt vertices
- + intersections. </td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- T& <b>bloat</b>(T& polygon_set, orientation_2d orient,<br />
- unsigned_area_type low_bloating,<br />
- unsigned_area_type
- high_bloating)</font></td>
- <td>Same as getting all the rectangles, bloating them and putting them
- back. O( n log n) runtime complexity and O(n) memory wrt vertices
- + intersections. </td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- T& <b>bloat</b>(T& polygon_set, direction_2d dir,<br />
- unsigned_area_type bloating)</font></td>
- <td>Same as getting all the rectangles, bloating them and putting them
- back. O( n log n) runtime complexity and O(n) memory wrt vertices
- + intersections. </td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- T& <b>bloat</b>(T& polygon_set, <br />
- unsigned_area_type
- west_bloating,<br />
- unsigned_area_type
- east_bloating,<br />
- unsigned_area_type
- south_bloating,<br />
- unsigned_area_type
- north_bloating)</font></td>
- <td>Same as getting all the rectangles, bloating them and putting them
- back. O( n log n) runtime complexity and O(n) memory wrt vertices
- + intersections. </td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- T& <b>shrink</b>(T& polygon_set, unsigned_area_type shrinking)</font></td>
- <td>Same as getting all the rectangles of the inverse, bloating them and overwriting
- the polygon set with the resulting regions then negating. O( n log
- n) runtime complexity and O(n) memory wrt vertices + intersections. </td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- T& <b>shrink</b>(T& polygon_set, orientation_2d orient,<br />
- unsigned_area_type
- shrinking)</font></td>
- <td>Same as getting all the rectangles of the inverse, bloating them and overwriting
- the polygon set with the resulting regions then negating. O( n log
- n) runtime complexity and O(n) memory wrt vertices + intersections. </td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- T& <b>shrink</b>(T& polygon_set, orientation_2d orient,<br />
- unsigned_area_type
- low_shrinking,<br />
- unsigned_area_type
- high_shrinking)</font></td>
- <td>Same as getting all the rectangles of the inverse, bloating them and overwriting
- the polygon set with the resulting regions then negating. O( n log
- n) runtime complexity and O(n) memory wrt vertices + intersections. </td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- T& <b>shrink</b>(T& polygon_set, direction_2d dir,<br />
- unsigned_area_type
- shrinking)</font></td>
- <td>Same as getting all the rectangles of the inverse, bloating them and overwriting
- the polygon set with the resulting regions then negating. O( n log
- n) runtime complexity and O(n) memory wrt vertices + intersections. </td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- T& <b>shrink</b>(T& polygon_set, <br />
- unsigned_area_type
- west_shrinking,<br />
- unsigned_area_type
- east_shrinking,<br />
- unsigned_area_type
- south_shrinking,<br />
- unsigned_area_type
- north_shrinking)</font></td>
- <td>Same as getting all the rectangles of the inverse, bloating them and overwriting
- the polygon set with the resulting regions then negating. O( n log
- n) runtime complexity and O(n) memory wrt vertices + intersections. </td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T, typename
- coord_type><br />
- T& <b>resize</b>(T& polygon_set, coord_type resizing)</font></td>
- <td>Same as bloat if resizing is positive, same as shrink if resizing is
- negative.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T, typename
- coord_type><br />
- T& <b>resize</b>(polygon_set_type& polygon_set, <br />
- coord_type west, coord_type east,
- <br /> coord_type south, coord_type north)</font></td>
- <td>Same as bloat if resizing is positive, same as shrink if resizing is
- negative. O( n log n) runtime complexity and O(n) memory wrt
- vertices + intersections. </td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
+ <td>Computes bounding box of an object that models
+polygon_90_set and stores it in an object that models rectangle.
+If the polygon set is empty returns false. If there are holes
+outside of shells they do not contribute to the extents of the polygon
+set. O( n log n) runtime complexity and O(n) memory wrt vertices
++ intersections. </td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+manhattan_area_type <b>area</b>(const T& polygon_set)</font></td>
+ <td>Computes the area covered by geometry in an object that
+models polygon_90_set. O( n log n) runtime complexity and O(n)
+memory wrt vertices + intersections. </td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+T1& <b>interact</b>(T1& a, const T2& b)</font></td>
+ <td>Given an object that models polygon_90_set and an
+object that models polygon_90_set or one of its refinements, modifies a
+to retain only regions that overlap or touch regions in b. O( n
+log n) runtime complexity and O(n) memory wrt vertices + intersections.
+ </td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+T& <b>self_intersect</b>(T& polygon_set)</font></td>
+ <td>Given an object that models polygon_90_set that has
+self overlapping regions, modifies the argument to contain only the
+regions of overlap. O( n log n) runtime complexity and O(n)
+memory wrt vertices + intersections. </td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+T& <b>self_xor</b>(T& polygon_set)</font></td>
+ <td>Given an object that models polygon_90_set that has
+self overlapping regions, modifies the argument to contain only the
+regions that do not overlap. O( n log n) runtime complexity and
+O(n) memory wrt vertices + intersections. </td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+T& <b>bloat</b>(T& polygon_set, unsigned_area_type bloating)</font></td>
+ <td>Same as getting all the rectangles, bloating them and
+putting them back. O( n log n) runtime complexity and O(n) memory
+wrt vertices + intersections. </td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+T& <b>bloat</b>(T& polygon_set, orientation_2d orient,<br />
+ unsigned_area_type
+bloating)</font></td>
+ <td>Same as getting all the rectangles, bloating them and
+putting them back. O( n log n) runtime complexity and O(n) memory
+wrt vertices + intersections. </td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+T& <b>bloat</b>(T& polygon_set, orientation_2d orient,<br />
+ unsigned_area_type
+low_bloating,<br />
+ unsigned_area_type
+high_bloating)</font></td>
+ <td>Same as getting all the rectangles, bloating them and
+putting them back. O( n log n) runtime complexity and O(n) memory
+wrt vertices + intersections. </td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+T& <b>bloat</b>(T& polygon_set, direction_2d dir,<br />
+ unsigned_area_type
+bloating)</font></td>
+ <td>Same as getting all the rectangles, bloating them and
+putting them back. O( n log n) runtime complexity and O(n) memory
+wrt vertices + intersections. </td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+T& <b>bloat</b>(T& polygon_set, <br />
+ unsigned_area_type
+west_bloating,<br />
+ unsigned_area_type
+east_bloating,<br />
+ unsigned_area_type
+south_bloating,<br />
+ unsigned_area_type
+north_bloating)</font></td>
+ <td>Same as getting all the rectangles, bloating them and
+putting them back. O( n log n) runtime complexity and O(n) memory
+wrt vertices + intersections. </td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+T& <b>shrink</b>(T& polygon_set, unsigned_area_type shrinking)</font></td>
+ <td>Same as getting all the rectangles of the inverse,
+bloating them and overwriting the polygon set with the resulting
+regions then negating. O( n log n) runtime complexity and O(n)
+memory wrt vertices + intersections. </td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+T& <b>shrink</b>(T& polygon_set, orientation_2d orient,<br />
+
+unsigned_area_type shrinking)</font></td>
+ <td>Same as getting all the rectangles of the inverse,
+bloating them and overwriting the polygon set with the resulting
+regions then negating. O( n log n) runtime complexity and O(n)
+memory wrt vertices + intersections. </td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+T& <b>shrink</b>(T& polygon_set, orientation_2d orient,<br />
+
+unsigned_area_type low_shrinking,<br />
+
+unsigned_area_type high_shrinking)</font></td>
+ <td>Same as getting all the rectangles of the inverse,
+bloating them and overwriting the polygon set with the resulting
+regions then negating. O( n log n) runtime complexity and O(n)
+memory wrt vertices + intersections. </td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+T& <b>shrink</b>(T& polygon_set, direction_2d dir,<br />
+
+unsigned_area_type shrinking)</font></td>
+ <td>Same as getting all the rectangles of the inverse,
+bloating them and overwriting the polygon set with the resulting
+regions then negating. O( n log n) runtime complexity and O(n)
+memory wrt vertices + intersections. </td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+T& <b>shrink</b>(T& polygon_set, <br />
+
+unsigned_area_type west_shrinking,<br />
+
+unsigned_area_type east_shrinking,<br />
+
+unsigned_area_type south_shrinking,<br />
+
+unsigned_area_type north_shrinking)</font></td>
+ <td>Same as getting all the rectangles of the inverse,
+bloating them and overwriting the polygon set with the resulting
+regions then negating. O( n log n) runtime complexity and O(n)
+memory wrt vertices + intersections. </td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename coord_type><br />
+T& <b>resize</b>(T& polygon_set, coord_type resizing)</font></td>
+ <td>Same as bloat if resizing is positive, same as shrink
+if resizing is negative.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename coord_type><br />
+T& <b>resize</b>(polygon_set_type& polygon_set, <br />
+ coord_type west,
+coord_type east, <br />
+ coord_type
+south, coord_type north)</font></td>
+ <td>Same as bloat if resizing is positive, same as shrink
+if resizing is negative. O( n log n) runtime complexity and O(n)
+memory wrt vertices + intersections. </td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
T& <b>grow_and</b>(T& polygon_set, unsigned_area_type bloating)</font></td>
- <td>Same as bloating non-overlapping regions and then applying self
- intersect to retain only the overlaps introduced by the bloat. O(
- n log n) runtime complexity and O(n) memory wrt vertices +
- intersections. </td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
+ <td>Same as bloating non-overlapping regions and then
+applying self intersect to retain only the overlaps introduced by the
+bloat. O( n log n) runtime complexity and O(n) memory wrt
+vertices + intersections. </td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
T& <b>grow_and</b>(T& polygon_set, orientation_2d orient,<br />
-
+
unsigned_area_type bloating)</font></td>
- <td>Same as bloating non-overlapping regions and then applying self
- intersect to retain only the overlaps introduced by the bloat. O(
- n log n) runtime complexity and O(n) memory wrt vertices +
- intersections. </td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
+ <td>Same as bloating non-overlapping regions and then
+applying self intersect to retain only the overlaps introduced by the
+bloat. O( n log n) runtime complexity and O(n) memory wrt
+vertices + intersections. </td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
T& <b>grow_and</b>(T& polygon_set, orientation_2d orient,<br />
-
+
unsigned_area_type low_bloating,<br />
-
+
unsigned_area_type high_bloating)</font></td>
- <td>Same as bloating non-overlapping regions and then applying self
- intersect to retain only the overlaps introduced by the bloat. O(
- n log n) runtime complexity and O(n) memory wrt vertices +
- intersections. </td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
+ <td>Same as bloating non-overlapping regions and then
+applying self intersect to retain only the overlaps introduced by the
+bloat. O( n log n) runtime complexity and O(n) memory wrt
+vertices + intersections. </td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
T& <b>grow_and</b>(T& polygon_set, direction_2d dir,<br />
-
+
unsigned_area_type bloating)</font></td>
- <td>Same as bloating non-overlapping regions and then applying self
- intersect to retain only the overlaps introduced by the bloat. O(
- n log n) runtime complexity and O(n) memory wrt vertices +
- intersections. </td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
+ <td>Same as bloating non-overlapping regions and then
+applying self intersect to retain only the overlaps introduced by the
+bloat. O( n log n) runtime complexity and O(n) memory wrt
+vertices + intersections. </td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
T& <b>grow_and</b>(T& polygon_set, <br />
-
+
unsigned_area_type west_bloating,<br />
-
+
unsigned_area_type east_bloating,<br />
-
+
unsigned_area_type south_bloating,<br />
-
+
unsigned_area_type north_bloating)</font></td>
- <td>Same as bloating non-overlapping regions and then applying self
- intersect to retain only the overlaps introduced by the bloat. O(
- n log n) runtime complexity and O(n) memory wrt vertices +
- intersections. </td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
+ <td>Same as bloating non-overlapping regions and then
+applying self intersect to retain only the overlaps introduced by the
+bloat. O( n log n) runtime complexity and O(n) memory wrt
+vertices + intersections. </td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
T& <b>scale_up</b>(T& polygon_set, unsigned_area_type factor)</font></td>
- <td>Scales geometry up by unsigned factor. O( n log n) runtime
- complexity and O(n) memory wrt vertices + intersections. </td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
+ <td>Scales geometry up by unsigned factor. O( n log
+n) runtime complexity and O(n) memory wrt vertices + intersections. </td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
T& <b>scale_down</b>(T& polygon_set, unsigned_area_type factor)</font></td>
- <td>Scales geometry down by unsigned factor. O( n log n) runtime
- complexity and O(n) memory wrt vertices + intersections. </td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T, typename scaling_type><br />
+ <td>Scales geometry down by unsigned factor. O( n log
+n) runtime complexity and O(n) memory wrt vertices + intersections. </td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename scaling_type><br />
T& <b>scale</b>(polygon_set_type& polygon_set, <br />
- const scaling_type& scaling)</font></td>
- <td>Scales geometry by applying scaling.scale() on all vertices.
- O( n log n) runtime complexity and O(n) memory wrt vertices +
- intersections. </td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T, typename coord_type><br />
+ const
+scaling_type& scaling)</font></td>
+ <td>Scales geometry by applying scaling.scale() on all
+vertices. O( n log n) runtime complexity and O(n) memory wrt
+vertices + intersections. </td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename coord_type><br />
T& <b>move</b>(T& polygon_set,<br />
- orientation_2d orient, coord_type
-displacement)</font></td>
- <td>Moves geometry by displacement amount in the orientation.
- O( n log n) runtime complexity and O(n) memory wrt vertices +
- intersections. </td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T, typename coord_type><br />
+ orientation_2d orient,
+coord_type displacement)</font></td>
+ <td>Moves geometry by displacement amount in the
+orientation. O( n log n) runtime complexity and O(n)
+memory wrt vertices + intersections. </td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename coord_type><br />
T& <b>move</b>(T& polygon_set, coord_type x_displacement, <br />
coord_type y_displacement)</font></td>
- <td>Moves the geometry by x_dispacement in x and y_displacement in y.
- Note: for consistency should be convolve(polygon_set, point). O( n
- log n) runtime complexity and O(n) memory wrt vertices + intersections. </td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T, typename transformation_type><br />
+ <td>Moves the geometry by x_dispacement in x and
+y_displacement in y. Note: for consistency should be
+convolve(polygon_set, point). O( n log n) runtime complexity and
+O(n) memory wrt vertices + intersections. </td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename transformation_type><br />
T& <b>transform</b>(T& polygon_set,<br />
- const
-transformation_type& transformation)</font></td>
- <td>Applies transformation.transform() on all vertices. O( n log
- n) runtime complexity and O(n) memory wrt vertices + intersections. </td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
+
+const transformation_type& transformation)</font></td>
+ <td>Applies transformation.transform() on all
+vertices. O( n log n) runtime complexity and O(n) memory wrt
+vertices + intersections. </td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
T& <b>keep</b>(T& polygon_set, <br />
unsigned_area_type min_area,<br />
unsigned_area_type max_area,<br />
unsigned_area_type min_width,<br />
unsigned_area_type max_width,<br />
- unsigned_area_type min_height,<br />
- unsigned_area_type max_height)</font></td>
- <td>Retains only regions that satisfy the min/max criteria in the
- argument list. Note: useful for visualization to cull too small
- polygons. O( n log n) runtime complexity and O(n) memory wrt
- vertices + intersections. </td>
- </tr>
- </tbody></table>
- <h1>Polygon 90 Set Data Object</h1>
-
-<p>
-</p><p>The polygon 90 set data type encapsulates the internal data format that
-serves as the input to the sweep-line algorithm that implements polygon-clipping
-boolean operations. It also internally keeps track of whether that data
-has been sorted or scanned and maintains the invariant that when its flags
-indicate that the data is sorted or scanned the data has not been changed to
-violate that assumption. Using the Polygon 90 Set Data type directly can
-be more efficient than using lists and vectors of polygons in the functions
-above because of the invariants it can enforce which provide the opportunity to
-maintain the data is sorted form rather than going all the way out to polygons
-then resorting those vertices for a subsequent operation.</p>
-<p>The declaration of Polygon 90 Set Data is the following:</p>
-<p><font face="Courier New">template <typename T><br />
+ unsigned_area_type
+min_height,<br />
+ unsigned_area_type
+max_height)</font></td>
+ <td>Retains only regions that satisfy the min/max criteria
+in the argument list. Note: useful for visualization to cull too
+small polygons. O( n log n) runtime complexity and O(n) memory
+wrt vertices + intersections. </td>
+ </tr>
+ </tbody>
+ </table>
+ <h1>Polygon 90 Set Data Object</h1>
+ <p> </p>
+ <p>The polygon 90 set data type encapsulates the internal data
+format that serves as the input to the sweep-line algorithm that
+implements polygon-clipping boolean operations. It also
+internally keeps track of whether that data has been sorted or scanned
+and maintains the invariant that when its flags indicate that the data
+is sorted or scanned the data has not been changed to violate that
+assumption. Using the Polygon 90 Set Data type directly can be
+more efficient than using lists and vectors of polygons in the
+functions above because of the invariants it can enforce which provide
+the opportunity to maintain the data is sorted form rather than going
+all the way out to polygons then resorting those vertices for a
+subsequent operation.</p>
+ <p>The declaration of Polygon 90 Set Data is the following:</p>
+ <p><font face="Courier New">template <typename T><br />
class polygon_90_set_data;</font></p>
-<p>The class is parameterized on the coordinate data type. Algorithms that
-benefit from knowledge of the invariants enforced by the class are implemented
-as member functions to provide them access to information about those
-invariants. </p>
-<h2>Member Functions</h2>
-<table id="table2" border="1" width="100%">
- <tbody><tr>
- <td width="586"><font face="Courier New"><b>polygon_90_set_data</b>()</font></td>
- <td>Default constructor. Scanning orientation defaults to
- HORIZONTAL</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New"><b>polygon_90_set_data</b>(orientation_2d
- orient)</font></td>
- <td>Construct with scanning orientation.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename iT><br />
- <b>polygon_90_set_data</b>(orientation_2d orient, <br />
+ <p>The class is parameterized on the coordinate data type.
+Algorithms that benefit from knowledge of the invariants enforced by
+the class are implemented as member functions to provide them access to
+information about those invariants. </p>
+ <h2>Member Functions</h2>
+ <table id="table2" border="1" width="100%">
+ <tbody>
+ <tr>
+ <td width="586"><font face="Courier New"><b>polygon_90_set_data</b>()</font></td>
+ <td>Default constructor. Scanning orientation
+defaults to HORIZONTAL</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New"><b>polygon_90_set_data</b>(orientation_2d
+orient)</font></td>
+ <td>Construct with scanning orientation.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename iT><br />
+ <b>polygon_90_set_data</b>(orientation_2d orient, <br />
+
iT input_begin, iT input_end)</font></td>
- <td>Construct with scanning orientation from an iterator range of
- insertable objects.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">
- <b>polygon_90_set_data</b>(const polygon_90_set_data& that)</font></td>
- <td>Copy construct.</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">template <typename l, typename r, typename op><br />
-<b>polygon_90_set_data</b>(const polygon_90_set_view<l,r,op>&
-t)</font></td>
- <td>Copy construct from a Boolean operator template.</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">
-<b>polygon_90_set_data</b>(orientation_2d orient, <br />
+ <td>Construct with scanning orientation from an iterator
+range of insertable objects.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New"> <b>polygon_90_set_data</b>(const
+polygon_90_set_data& that)</font></td>
+ <td>Copy construct.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename l, typename r, typename op><br />
+ <b>polygon_90_set_data</b>(const
+polygon_90_set_view<l,r,op>& t)</font></td>
+ <td>Copy construct from a Boolean operator template.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">
+ <b>polygon_90_set_data</b>(orientation_2d orient, <br />
+
const polygon_90_set_data& that)</font></td>
- <td>Construct with scanning orientation and copy from another polygon
- set.</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">polygon_90_set_data& <br /><b>operator=</b>(const polygon_90_set_data& that)</font></td>
- <td>Assignment from another polygon set, may change scanning
- orientation.</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">template <typename l, typename r, typename op><br />
-polygon_90_set_data& <br /><b>operator=</b>(const polygon_90_set_view<l, r,
+ <td>Construct with scanning orientation and copy from
+another polygon set.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">polygon_90_set_data&
+ <br />
+ <b>operator=</b>(const polygon_90_set_data& that)</font></td>
+ <td>Assignment from another polygon set, may change
+scanning orientation.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename l, typename r, typename op><br />
+polygon_90_set_data& <br />
+ <b>operator=</b>(const polygon_90_set_view<l, r,
op>& that)</font></td>
- <td>Assignment from a Boolean operator template.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename geometry_object><br />
-polygon_90_set_data& <b>operator=</b>(const geometry_object& geo)</font></td>
- <td>Assignment from an insertable object.</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">
+ <td>Assignment from a Boolean operator template.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename geometry_object><br />
+polygon_90_set_data& <b>operator=</b>(const geometry_object&
+geo)</font></td>
+ <td>Assignment from an insertable object.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">
template <typename iT><br />
void <b>insert</b>(iT input_begin, iT input_end)</font></td>
- <td>Insert objects of an iterator range. Linear wrt. inserted
- vertices.</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">
+ <td>Insert objects of an iterator range. Linear wrt.
+inserted vertices.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">
void <b>insert</b>(const polygon_90_set_data& polygon_set)</font></td>
- <td>Insert a polygon set. Linear wrt. inserted vertices.</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">
+ <td>Insert a polygon set. Linear wrt. inserted
+vertices.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">
template <typename geometry_type><br />
-void <b>insert</b>(const geometry_type& geometry_object, <br /> bool is_hole
-= false)</font></td>
- <td>Insert a geometry object, if is_hole is true then the inserted
- region is subtractive rather than additive. Linear wrt. inserted
- vertices.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">
-template <typename output_container><br />
+void <b>insert</b>(const geometry_type& geometry_object, <br />
+ bool
+is_hole = false)</font></td>
+ <td>Insert a geometry object, if is_hole is true then the
+inserted region is subtractive rather than additive. Linear wrt.
+inserted vertices.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename output_container><br />
void <b>get</b>(output_container& output) const</font></td>
- <td>Expects a standard container of geometry objects. Will scan
- and eliminate overlaps. Converts polygon set geometry to objects
- of that type and appends them to the container. Polygons will be
- output with counterclockwise winding, hole polygons will be output with
- clockwise winding. The last vertex of an output polygon is not the
- duplicate of the first, and the number of points is equal to the number
- of edges. O( n log n) runtime complexity and O(n) memory wrt
- vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">
-template <typename output_container><br />
+ <td>Expects a standard container of geometry objects.
+Will scan and eliminate overlaps. Converts polygon set geometry
+to objects of that type and appends them to the container.
+Polygons will be output with counterclockwise winding, hole polygons
+will be output with clockwise winding. The last vertex of an
+output polygon is not the duplicate of the first, and the number of
+points is equal to the number of edges. O( n log n) runtime
+complexity and O(n) memory wrt vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename output_container><br />
void <b>get_polygons</b>(output_container& output) const</font></td>
- <td>Expects a standard container of polygon objects. Will scan and
- eliminate overlaps. Converts polygon set geometry to polygons and
- appends them to the container. Polygons will have holes fractured
- out to the outer boundary along the positive direction of the scanline
- orientation of the polygon set. O( n log n) runtime complexity and
- O(n) memory wrt vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">
-template <typename output_container><br />
+ <td>Expects a standard container of polygon objects.
+Will scan and eliminate overlaps. Converts polygon set geometry
+to polygons and appends them to the container. Polygons will have
+holes fractured out to the outer boundary along the positive direction
+of the scanline orientation of the polygon set. O( n log n)
+runtime complexity and O(n) memory wrt vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename output_container><br />
void <b>get_rectangles</b>(output_container& output) const</font></td>
- <td>Expects a standard container of rectangle objects. Will scan
- and eliminate overlaps. Slices polygon set geometry to rectangles
- along the scanning orientation and appends them to the container.
- O( n log n) runtime complexity and O(n) memory wrt vertices +
- intersections.</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">
+ <td>Expects a standard container of rectangle
+objects. Will scan and eliminate overlaps. Slices polygon
+set geometry to rectangles along the scanning orientation and appends
+them to the container. O( n log n) runtime complexity and O(n)
+memory wrt vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">
template <typename output_container><br />
-void <b>get_rectangles</b>(output_container& output, <br /> orientation_2d
-slicing_orientation) const </font>
- </td>
- <td>Expects a standard container of rectangle objects. Will scan
- and eliminate overlaps. Slices polygon set geometry to rectangles
- along the given orientation and appends them to the container. O(
- n log n) runtime complexity and O(n) memory wrt vertices +
- intersections.</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">
+void <b>get_rectangles</b>(output_container& output, <br />
+ orientation_2d slicing_orientation) const </font> </td>
+ <td>Expects a standard container of rectangle
+objects. Will scan and eliminate overlaps. Slices polygon
+set geometry to rectangles along the given orientation and appends them
+to the container. O( n log n) runtime complexity and O(n) memory
+wrt vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">
bool <b>operator==</b>(const polygon_90_set_data& p) const</font></td>
- <td>Once scanned the data representation of geometry within a polygon
- set is in a mathematically canonical form. Comparison between two
- sets is therefore a linear time operation once they are in the scanned
- state. Will scan and eliminate overlaps in both polygon sets. O( n
- log n) runtime complexity and O(n) memory wrt vertices + intersections
- the first time, linear subsequently.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">
-bool <b>operator!=</b>(const polygon_90_set_data& p) const</font></td>
- <td>Inverse logic of equivalence operator.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">void <b>clear</b>()</font></td>
- <td>Make the polygon set empty. Note: does not de-allocate memory.
- Use shrink to fit idiom and assign default constructed polygon set to
- de-allocate.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">bool <b>empty</b>() const </font>
- </td>
- <td>Check whether the polygon set contains no geometry. Will scan
- and eliminate overlaps because subtractive regions might make the
- polygon set empty. O( n log n) runtime complexity and O(n) memory
- wrt vertices + intersections the first time, linear subsequently.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">orientation_2d <b>orient</b>() const</font></td>
- <td>Get the scanning orientation. Depending on the data it is
- sometimes more efficient to scan in a specific orientation. This
- is particularly true of Manhattan geometry data. Constant time.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">void <b>clean</b>() const</font></td>
- <td>Scan and eliminate overlaps. O( n log n) runtime complexity
- and O(n) memory wrt vertices + intersections the first time, constant
- time subsequently.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">
-template <typename input_iterator_type><br />
-void <b>set</b>(input_iterator_type input_begin, <br /> input_iterator_type input_end,
-<br /> orientation_2d orient) </font>
- </td>
- <td>Overwrite geometry in polygon set with insertable objects in the
- iterator range. Also sets the scanning orientation to that
- specified.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">
-template <typename rectangle_type><br />
+ <td>Once scanned the data representation of geometry within
+a polygon set is in a mathematically canonical form. Comparison
+between two sets is therefore a linear time operation once they are in
+the scanned state. Will scan and eliminate overlaps in both polygon
+sets. O( n log n) runtime complexity and O(n) memory wrt vertices
++ intersections the first time, linear subsequently.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">bool <b>operator!=</b>(const
+polygon_90_set_data& p) const</font></td>
+ <td>Inverse logic of equivalence operator.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">void <b>clear</b>()</font></td>
+ <td>Make the polygon set empty. Note: does not
+de-allocate memory. Use shrink to fit idiom and assign default
+constructed polygon set to de-allocate.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">bool <b>empty</b>()
+const </font> </td>
+ <td>Check whether the polygon set contains no
+geometry. Will scan and eliminate overlaps because subtractive
+regions might make the polygon set empty. O( n log n) runtime
+complexity and O(n) memory wrt vertices + intersections the first time,
+linear subsequently.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">orientation_2d <b>orient</b>()
+const</font></td>
+ <td>Get the scanning orientation. Depending on the
+data it is sometimes more efficient to scan in a specific
+orientation. This is particularly true of Manhattan geometry
+data. Constant time.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">void <b>clean</b>()
+const</font></td>
+ <td>Scan and eliminate overlaps. O( n log n) runtime
+complexity and O(n) memory wrt vertices + intersections the first time,
+constant time subsequently.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename input_iterator_type><br />
+void <b>set</b>(input_iterator_type input_begin, <br />
+ input_iterator_type
+input_end, <br />
+ orientation_2d orient)
+ </font> </td>
+ <td>Overwrite geometry in polygon set with insertable
+objects in the iterator range. Also sets the scanning orientation
+to that specified.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename rectangle_type><br />
bool <b>extents</b>(rectangle_type& extents_rectangle) const</font></td>
- <td>Given an object that models rectangle, scans and eliminates overlaps
- in the polygon set because subtractive regions may alter its extents
- then computes the bounding box and assigns it to extents_rectangle.
- O( n log n) runtime complexity and O(n) memory wrt vertices +
- intersections the first time, linear subsequently.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">
-polygon_90_set_data&<br />
-<b>bloat</b>(unsigned_area_type west_bloating,<br />
+ <td>Given an object that models rectangle, scans and
+eliminates overlaps in the polygon set because subtractive regions may
+alter its extents then computes the bounding box and assigns it to
+extents_rectangle. O( n log n) runtime complexity and O(n) memory
+wrt vertices + intersections the first time, linear subsequently.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">polygon_90_set_data&<br />
+ <b>bloat</b>(unsigned_area_type west_bloating,<br />
unsigned_area_type east_bloating,<br />
unsigned_area_type south_bloating,<br />
unsigned_area_type north_bloating) </font></td>
- <td>Scans to eliminate overlaps and subtractive regions. Inserts
- rectangles of width specified by bloating values to the indicated side
- of geometry within the polygon set and fills corners with rectangles of
- the length and width specified for the adjacent sides. O( n log n)
- runtime complexity and O(n) memory wrt vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">
-polygon_90_set_data&<br />
-<b>shrink</b>(unsigned_area_type west_shrinking,<br />
+ <td>Scans to eliminate overlaps and subtractive
+regions. Inserts rectangles of width specified by bloating values
+to the indicated side of geometry within the polygon set and fills
+corners with rectangles of the length and width specified for the
+adjacent sides. O( n log n) runtime complexity and O(n) memory
+wrt vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">polygon_90_set_data&<br />
+ <b>shrink</b>(unsigned_area_type west_shrinking,<br />
unsigned_area_type east_shrinking,<br />
unsigned_area_type south_shrinking,<br />
unsigned_area_type north_shrinking)</font></td>
- <td>Scans to eliminate overlaps and subtractive regions. Inserts
- subtractiive rectangles of width specified by bloating values to the
- indicated side of geometry within the polygon set and subtractive
- rectangle at convex corners of the length and width specified for the
- adjacent sides. Scans to eliminate overlapping subtractive
- regions. O( n log n) runtime complexity and O(n) memory wrt
- vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">
+ <td>Scans to eliminate overlaps and subtractive
+regions. Inserts subtractiive rectangles of width specified by
+bloating values to the indicated side of geometry within the polygon
+set and subtractive rectangle at convex corners of the length and width
+specified for the adjacent sides. Scans to eliminate overlapping
+subtractive regions. O( n log n) runtime complexity and O(n)
+memory wrt vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">polygon_90_set_data&<br />
+ <b>resize</b>(coordinate_type west, coordinate_type east, <br />
+ coordinate_type south,
+coordinate_type north)</font></td>
+ <td>Call bloat or shrink or shrink then bloat depending on
+whether the resizing values are positive or negative. O( n log n)
+runtime complexity and O(n) memory wrt vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">polygon_90_set_data&
+ <b>move</b>(coordinate_type x_delta, <br />
+
+coordinate_type y_delta) </font> </td>
+ <td>Add x_delta to x values and y_delta to y values of
+vertices stored within the polygon set. Linear wrt. vertices.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename transformation_type><br />
+polygon_90_set_data& <br />
+ <b>transform</b>(const transformation_type&
+transformation) </font> </td>
+ <td>Applies transformation.transform() on vertices stored
+within the polygon set. Linear wrt. vertices.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">polygon_90_set_data&
+ <b>scale_up</b>(unsigned_area_type factor)</font></td>
+ <td>Scales vertices stored within the polygon set up by
+factor. Linear wrt. vertices.</td>
+ </tr>
+ <tr>
+ <td width="586">
+ <p><font face="Courier New">polygon_90_set_data& <b>scale_down</b>(unsigned_area_type
+factor)</font> </p>
+ </td>
+ <td>Scales vertices stored within the polygon set down by
+factor. Linear wrt. vertices.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename scaling_type><br />
polygon_90_set_data&<br />
-<b>resize</b>(coordinate_type west, coordinate_type east, <br /> coordinate_type south, coordinate_type north)</font></td>
- <td>Call bloat or shrink or shrink then bloat depending on whether the
- resizing values are positive or negative. O( n log n) runtime
- complexity and O(n) memory wrt vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">
-polygon_90_set_data& <b>move</b>(coordinate_type x_delta, <br />
-coordinate_type y_delta) </font>
- </td>
- <td>Add x_delta to x values and y_delta to y values of vertices stored
- within the polygon set. Linear wrt. vertices.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">
-template <typename transformation_type><br />
-polygon_90_set_data& <br /><b>transform</b>(const transformation_type& transformation) </font>
- </td>
- <td>Applies transformation.transform() on vertices stored within the
- polygon set. Linear wrt. vertices.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">
-polygon_90_set_data& <b>scale_up</b>(unsigned_area_type factor)</font></td>
- <td>Scales vertices stored within the polygon set up by factor.
- Linear wrt. vertices.</td>
- </tr>
- <tr>
- <td width="586">
-<p><font face="Courier New">polygon_90_set_data& <b>scale_down</b>(unsigned_area_type
-factor)</font> </p></td>
- <td>Scales vertices stored within the polygon set down by factor.
- Linear wrt. vertices.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">
-template <typename scaling_type><br />
-polygon_90_set_data&<br /> <b>scale</b>(const anisotropic_scale_factor<scaling_type>&
- f)</font></td>
- <td>Scales vertices stored within the polygon set by applying f.scale().
- Linear wrt. vertices.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">polygon_90_set_data& <b>scale</b>(double factor) </font></td>
- <td>Scales vertices stored within the polygon set by floating point
- factor. Linear wrt. vertices.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">polygon_90_set_data& <b>self_xor</b>()</font></td>
- <td>Retain only non-overlapping regions of geometry within polygon set.
- O( n log n) runtime complexity and O(n) memory wrt vertices +
- intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">polygon_90_set_data& <b>self_intersect</b>()</font></td>
- <td>Retain only overlapping regions of geometry within a polygon set.
- O( n log n) runtime complexity and O(n) memory wrt vertices +
- intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">polygon_90_set_data&<br /> <b>interact</b>(const polygon_90_set_data& that)</font></td>
- <td>Retain only regions that touch or overlap regions in argument.
- O( n log n) runtime complexity and O(n) memory wrt vertices +
- intersections.</td>
- </tr>
- </tbody></table>
- </td></tr><tr>
-<td style="background-color: rgb(238, 238, 238);" nowrap="1" valign="top">
- </td>
-<td style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;" valign="top" width="100%">
-
-
-<table class="docinfo" id="table4" frame="void" rules="none">
- <colgroup>
- <col class="docinfo-name" /><col class="docinfo-content" />
- </colgroup>
- <tbody valign="top">
- <tr>
- <th class="docinfo-name">Copyright:</th>
- <td>Copyright © Intel Corporation 2008-2010.</td>
- </tr>
- <tr class="field">
- <th class="docinfo-name">License:</th>
- <td class="field-body">Distributed under the Boost Software License,
- Version 1.0. (See accompanying file <tt class="literal">
- <span class="pre">LICENSE_1_0.txt</span></tt> or copy at
- <a class="reference" target="_top" href="http://www.boost.org/LICENSE_1_0.txt">
- http://www.boost.org/LICENSE_1_0.txt>)</td>
- </tr>
-</tbody></table>
-
-</td></tr></tbody></table></body></html>
\ No newline at end of file
+ <b>scale</b>(const
+anisotropic_scale_factor<scaling_type>& f)</font></td>
+ <td>Scales vertices stored within the polygon set by
+applying f.scale(). Linear wrt. vertices.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">polygon_90_set_data&
+ <b>scale</b>(double factor) </font></td>
+ <td>Scales vertices stored within the polygon set by
+floating point factor. Linear wrt. vertices.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">polygon_90_set_data&
+ <b>self_xor</b>()</font></td>
+ <td>Retain only non-overlapping regions of geometry within
+polygon set. O( n log n) runtime complexity and O(n) memory wrt
+vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">polygon_90_set_data&
+ <b>self_intersect</b>()</font></td>
+ <td>Retain only overlapping regions of geometry within a
+polygon set. O( n log n) runtime complexity and O(n) memory wrt
+vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">polygon_90_set_data&<br />
+ <b>interact</b>(const polygon_90_set_data& that)</font></td>
+ <td>Retain only regions that touch or overlap regions in
+argument. O( n log n) runtime complexity and O(n) memory wrt
+vertices + intersections.</td>
+ </tr>
+ </tbody>
+ </table>
+ </td>
+ </tr>
+ <tr>
+ <td style="background-color: rgb(238, 238, 238);" nowrap="1"
+ valign="top"> </td>
+ <td
+ style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;"
+ valign="top" width="100%">
+ <table class="docinfo" id="table4" frame="void" rules="none">
+ <colgroup> <col class="docinfo-name" /><col
+ class="docinfo-content" /> </colgroup> <tbody valign="top">
+ <tr>
+ <th class="docinfo-name">Copyright:</th>
+ <td>Copyright © Intel Corporation 2008-2010.</td>
+ </tr>
+ <tr class="field">
+ <th class="docinfo-name">License:</th>
+ <td class="field-body">Distributed under the Boost Software
+License, Version 1.0. (See accompanying file <tt class="literal"> <span
+ class="pre">LICENSE_1_0.txt</span></tt> or copy at <a
+ class="reference" target="_top"
+ href="http://www.boost.org/LICENSE_1_0.txt">
+http://www.boost.org/LICENSE_1_0.txt>)</td>
+ </tr>
+ </tbody>
+ </table>
+ </td>
+ </tr>
+ </tbody>
+</table>
+</body>
+</html>
Modified: branches/release/libs/polygon/doc/gtl_polygon_90_with_holes_concept.htm
==============================================================================
--- branches/release/libs/polygon/doc/gtl_polygon_90_with_holes_concept.htm (original)
+++ branches/release/libs/polygon/doc/gtl_polygon_90_with_holes_concept.htm 2013-04-15 18:27:46 EDT (Mon, 15 Apr 2013)
@@ -1,464 +1,516 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:(null)1="http://www.w3.org/TR/REC-html40" lang="en"><head>
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"
+ xmlns:v="urn:schemas-microsoft-com:vml"
+ xmlns:o="urn:schemas-microsoft-com:office:office"
+ xmlns:(null)1="http://www.w3.org/TR/REC-html40" lang="en">
+<head>
<!--
Copyright 2009-2010 Intel Corporation
license banner
---><title>Boost Polygon Library: Polygon 90 With Holes Concept</title>
-
-
-
- <meta http-equiv="content-type" content="text/html;charset=ISO-8859-1" /><!-- <link type="text/css" rel="stylesheet" href="adobe_source.css"> --></head><body><table style="margin: 0pt; padding: 0pt; width: 100%;" border="0" cellpadding="0" cellspacing="0"><tbody><tr>
-<td style="background-color: rgb(238, 238, 238);" nowrap="1" valign="top">
- <div style="padding: 5px;" align="center">
- <img src="images/boost.png" border="0" height="86" width="277" /><a title="www.boost.org home page" href="http://www.boost.org/" tabindex="2" style="border: medium none ;">
- </a>
- </div>
- <div style="margin: 5px;">
- <h3 class="navbar">Contents</h3>
- <ul>
- <li>Boost.Polygon Main Page</li>
- <li>Design Overview</li>
- <li>Isotropy</li>
- <li>Coordinate Concept</li>
- <li>Interval Concept</li>
- <li>Point Concept</li>
+-->
+ <title>Boost Polygon Library: Polygon 90 With Holes Concept</title>
+ <meta http-equiv="content-type" content="text/html;charset=ISO-8859-1" />
+<!-- <link type="text/css" rel="stylesheet" href="adobe_source.css"> -->
+</head>
+<body>
+<table style="margin: 0pt; padding: 0pt; width: 100%;" border="0"
+ cellpadding="0" cellspacing="0">
+ <tbody>
+ <tr>
+ <td style="background-color: rgb(238, 238, 238);" nowrap="1"
+ valign="top">
+ <div style="padding: 5px;" align="center"> <img
+ src="images/boost.png" border="0" height="86" width="277" /><a
+ title="www.boost.org home page" href="http://www.boost.org/"
+ tabindex="2" style="border: medium none ;"> </a> </div>
+ <div style="margin: 5px;">
+ <h3 class="navbar">Contents</h3>
+ <ul>
+ <li>Boost.Polygon Main Page</li>
+ <li>Design Overview</li>
+ <li>Isotropy</li>
+ <li>Coordinate Concept</li>
+ <li>Interval Concept</li>
+ <li>Point Concept</li>
<li>Segment Concept</li>
-
- <li>Rectangle Concept</li>
- <li>Polygon 90 Concept</li>
- <li>Polygon 90 With Holes Concept</li>
- <li>Polygon 45 Concept</li>
- <li>Polygon 45 With Holes Concept</li>
- <li>Polygon Concept</li>
- <li>Polygon With Holes Concept</li>
- <li>Polygon 90 Set Concept</li>
- <li>Polygon 45 Set Concept</li>
- <li>Polygon Set Concept</li>
- <li>Connectivity Extraction 90</li>
- <li>Connectivity Extraction 45</li>
- <li>Connectivity Extraction</li>
- <li>Property Merge 90</li>
- <li>Property Merge 45</li>
- <li>Property Merge</li>
+ <li>Rectangle Concept</li>
+ <li>Polygon 90 Concept</li>
+ <li>Polygon 90 With Holes Concept</li>
+ <li>Polygon 45 Concept</li>
+ <li><a href="gtl_polygon_45_with_holes_concept.htm">Polygon 45
+With Holes Concept</a></li>
+ <li>Polygon Concept</li>
+ <li><a href="gtl_polygon_with_holes_concept.htm">Polygon With
+Holes Concept</a></li>
+ <li><a href="gtl_polygon_90_set_concept.htm">Polygon 90 Set
+Concept</a></li>
+ <li><a href="gtl_polygon_45_set_concept.htm">Polygon 45 Set
+Concept</a></li>
+ <li>Polygon Set Concept</li>
+ <li><a href="gtl_connectivity_extraction_90.htm">Connectivity
+Extraction 90</a></li>
+ <li><a href="gtl_connectivity_extraction_45.htm">Connectivity
+Extraction 45</a></li>
+ <li><a href="gtl_connectivity_extraction.htm">Connectivity
+Extraction</a></li>
+ <li>Property Merge 90</li>
+ <li>Property Merge 45</li>
+ <li>Property Merge</li>
<li><a href="voronoi_main.htm">Voronoi Main Page<br />
-</a></li>
+ </a></li>
<li>Voronoi Benchmark<br />
</li>
<li>Voronoi Builder</li>
- <li><a href="voronoi_diagram.htm">Voronoi Diagram<br />
-</a></li>
- <li>Voronoi Predicates</li>
- <li>Voronoi Robust FPT<br />
- </li>
-
-
- </ul>
- <h3 class="navbar">Other Resources</h3>
- <ul>
+ <li>Voronoi Diagram</li>
+ </ul>
+ <h3 class="navbar">Other Resources</h3>
+ <ul>
<li>GTL Boostcon 2009 Paper</li>
- <li><a href="GTL_boostcon_draft03.pdf">GTL Boostcon 2009
- Presentation</a></li>
+ <li><a href="GTL_boostcon_draft03.pdf">GTL Boostcon 2009
+Presentation</a></li>
<li>Performance Analysis</li>
<li>Layout Versus Schematic Tutorial</li>
<li>Minkowski Sum Tutorial</li>
<li>Voronoi Basic Tutorial</li>
- <li>Voronoi Advanced Tutorial</li>
-</ul>
- </div>
- <h3 class="navbar">Polygon Sponsor</h3>
- <div style="padding: 5px;" align="center">
- <img src="images/intlogo.gif" border="0" height="51" width="127" /><a title="www.adobe.com home page" href="http://www.adobe.com/" tabindex="2" style="border: medium none ;">
- </a>
- </div>
-</td>
-<td style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;" valign="top" width="100%">
-
-<!-- End Header -->
-
-<br />
-<p>
-</p><h1>Polygon 90 With Holes Concept</h1>
-
-<p>
-</p><p>The polygon_90_with_holes concept tag is <font face="Courier New">
+ <li><a href="voronoi_advanced_tutorial.htm">Voronoi Advanced
+Tutorial</a></li>
+ </ul>
+ </div>
+ <h3 class="navbar">Polygon Sponsor</h3>
+ <div style="padding: 5px;" align="center"> <img
+ src="images/intlogo.gif" border="0" height="51" width="127" /><a
+ title="www.adobe.com home page" href="http://www.adobe.com/"
+ tabindex="2" style="border: medium none ;"> </a> </div>
+ </td>
+ <td
+ style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;"
+ valign="top" width="100%">
+<!-- End Header --><br />
+ <p>
+ </p>
+ <h1>Polygon 90 With Holes Concept</h1>
+ <p> </p>
+ <p>The polygon_90_with_holes concept tag is <font
+ face="Courier New">
polygon_90_with_holes_concept</font></p>
-<p>
-To register a user defined type as a model of
-<font face="Times New Roman">polygon_90_with_holes </font>concept, specialize the
-geometry concept meta-function for that type. In the example below CPolygon90WithHoles is registered as a model of
-polygon<font face="Times New Roman">_90_with_holes </font> concept.</p><p>
-<font face="Courier New">template <><br />
-struct geometry_concept<CPolygon90WithHoles> { typedef polygon_90_with_holes_concept type; };</font></p><p>
-<font face="Times New Roman">The semantic of a polygon_90_with_holes is a
-polygon_90 that it can provide iterators over holes that are also polygon_90.
-A mutable polygon_90_with_holes must also be able to set its geometry based on
-an interator range over polygon_90 holes. There is no convention of
-winding of holes enforced within the library. </font></p><p>
-<font face="Times New Roman">Below is shown the default polygon with holes
-traits. Specialization of these traits is required for types that don't
-conform to the default behavior.</font></p><p><font face="Courier New">template <typename
-T, typename enable = void><br />
+ <p> To register a user defined type as a model of <font
+ face="Times New Roman">polygon_90_with_holes </font>concept,
+specialize the geometry concept meta-function for that type. In
+the example below CPolygon90WithHoles is registered as a model of
+polygon<font face="Times New Roman">_90_with_holes </font> concept.</p>
+ <p> <font face="Courier New">template <><br />
+struct geometry_concept<CPolygon90WithHoles> { typedef
+polygon_90_with_holes_concept type; };</font></p>
+ <p> <font face="Times New Roman">The semantic of a
+polygon_90_with_holes is a polygon_90 that it can provide iterators
+over holes that are also polygon_90. A mutable
+polygon_90_with_holes must also be able to set its geometry based on an
+interator range over polygon_90 holes. There is no convention of
+winding of holes enforced within the library. </font></p>
+ <p> <font face="Times New Roman">Below is shown the default
+polygon with holes traits. Specialization of these traits is
+required for types that don't conform to the default behavior.</font></p>
+ <p><font face="Courier New">template <typename T, typename
+enable = void><br />
struct polygon_with_holes_traits {<br />
- typedef typename T::iterator_holes_type
+ typedef typename T::iterator_holes_type
iterator_holes_type;<br />
typedef typename T::hole_type hole_type;<br />
- static inline iterator_holes_type begin_holes(const T&
-t) {<br />
- return t.begin_holes();<br />
+ static inline iterator_holes_type
+begin_holes(const T& t) {<br />
+ return
+t.begin_holes();<br />
}<br />
- static inline iterator_holes_type end_holes(const T& t)
-{<br />
- return t.end_holes();<br />
+ static inline iterator_holes_type
+end_holes(const T& t) {<br />
+ return
+t.end_holes();<br />
}<br />
- static inline unsigned int size_holes(const T& t) {<br />
- return t.size_holes();<br />
+ static inline unsigned int size_holes(const
+T& t) {<br />
+ return
+t.size_holes();<br />
}<br />
};</font></p>
-<p><font face="Courier New">template <typename T, typename enable = void><br />
+ <p><font face="Courier New">template <typename T, typename
+enable = void><br />
struct polygon_with_holes_mutable_traits {<br />
template <typename iT><br />
- static inline T& set_holes(T& t, iT inputBegin, iT
-inputEnd) {<br />
- t.set_holes(inputBegin,
-inputEnd);<br />
+ static inline T& set_holes(T& t, iT
+inputBegin, iT inputEnd) {<br />
+
+t.set_holes(inputBegin, inputEnd);<br />
return t;<br />
}<br />
};</font></p>
-<p>An object that is a model of <font face="Courier New">
-polygon_90_with_holes_concept</font> can be viewed as a model of any of its
-refinements if it is determined at runtime to conform to the restriction of
-those concepts. This concept casting is accomplished through the
-<font face="Courier New">view_as<>()</font> function.</p>
-<p><font face="Courier New">view_as<rectangle_concept>(polygon_90_with_holes_object)</font><br />
-<font face="Courier New">view_as<polygon_90_concept>(polygon_90_with_holes_object)</font></p>
-<p>The return value of <font face="Courier New">view_as<>()</font> can be
-passed into any interface that expects an object of the conceptual type
-specified in its template parameter.</p>
-<h2>Functions</h2>
-<table id="table1" border="1" width="100%">
- <tbody><tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- compact_iterator_type <b>begin_compact</b>(const T& polygon)</font></td>
- <td><font face="Times New Roman">Expects a model of polygon_90.
- Returns the begin iterator over the range of coordinates that correspond
- to horizontal and vertical edges.</font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- compact_iterator_type <b>end_compact</b>(const T& polygon)</font></td>
- <td><font face="Times New Roman">Expects a model of polygon_90.
- Returns the end iterator over the range of coordinates that correspond
- to horizontal and vertical edges.</font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- point_iterator_type <b>begin_points</b>(const T& polygon)</font></td>
- <td><font face="Times New Roman">Expects a model of
- polygon_90_with_holes.
- Returns the begin iterator over the range of points that correspond to
- vertices of the polygon.</font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- point_iterator_type <b>end_points</b>(const T& polygon)</font></td>
- <td><font face="Times New Roman">Expects a model of
- polygon_90_with_holes.
- Returns the end iterator over the range of points that correspond to
- vertices of the polygon.</font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- hole_iterator_type <b>begin_holes</b>(const T& polygon)</font></td>
- <td><font face="Times New Roman">Expects a model of
- polygon_90_with_holes.
- Returns the begin iterator over the range of coordinates that correspond
- to horizontal and vertical edges.</font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- hole_iterator_type <b>end_</b><b>holes</b>(const T& polygon)</font></td>
- <td><font face="Times New Roman">Expects a model of
- polygon_90_with_holes.
- Returns the end iterator over the range of coordinates that correspond
- to horizontal and vertical edges.</font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T, typename
- iterator><br />
- void <b>set_compact</b>(T& polygon, iterator b, iterator e)</font></td>
- <td><font face="Times New Roman">Expects a model of
- polygon_90_with_holes.
- Sets the polygon to the coordinate data range [b,e) that corresponds to
- .horizontal and vertical edges.</font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T, typename
- iterator><br />
- void <b>set_points</b>(T& polygon, iterator b, iterator e)</font></td>
- <td><font face="Times New Roman">Expects a model of
- polygon_90_with_holes.
- Sets the polygon to the point data range [b,e) that corresponds to
- vertices of a manhattan polygon. Non-manhattan edges between
- successive input points results in undefined behavior.</font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T, typename
- iterator><br />
- void <b>set_holes</b>(T& polygon, iterator b, iterator e)</font></td>
- <td><font face="Times New Roman">Expects a model of
- polygon_90_with_holes.
- Sets the polygon holes to the hole data range [b,e)</font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- unsigned int <b>size</b>(const T& polygon)</font></td>
- <td><font face="Times New Roman">Returns the number of edges in the
- outer shell of the polygon_90_with_holes. Does not include sizes
- of the holes.</font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- T1& <b>assign</b>(T1& left, const T2& right)</font></td>
- <td>Copies data from right object that models polygon_90_with_holes or
- one of its refinements into left object
- that models polygon_90_with_holes.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T,
- typename point_type><br />
- bool <b>contains</b>(const T&, const point_type& point, <br />
-
- bool consider_touch=true)</font></td>
- <td>Given an object that models polygon_90_with_holes and an object that models
- point, returns true
- if the polygon shell contains the point and one of its holes does not
- contain the point. If the consider_touch
- flag is true will return true if the point lies along the boundary of
- the polygon or one of its holes.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">// get the center coordinate<br />
- template <typename T, typename point_type><br />
- void <b>center</b>(point_type& p, const T& polygon)</font></td>
- <td>Sets object that models point to the center point of the bounding
- box of an object that models polygon_90_with_holes.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T,
- typename rectangle_type><br />
- bool <b>extents</b>(rectangle_type& bbox, const T& polygon)</font></td>
- <td>Sets object that models rectangle to the bounding box of an object
- that models polygon_90_with_holes and returns true. Returns false
- and leaves bbox unchanged if polygon is empty.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- manhattan_area_type <b>area</b>(const T& polygon)</font></td>
- <td>Returns the area of an object
- that models polygon_90_with_holes including subtracting the area of its
- holes from the area of the outer shell polygon.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- direction_1d <b>winding</b>(const T& polygon)</font></td>
- <td>Returns the winding direction of an object
- that models polygon_90_with_holes, LOW == CLOCKWISE, HIGH =
- COUNTERCLOCKWISE.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- coordinate_difference <b>perimeter</b>(const T& polygon)</font></td>
- <td>Returns the perimeter length of an object
- that models polygon_90, including the perimeters of the holes.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T,
- typename transform_type><br />
- T& <b>transform</b>(T& polygon, const transform_type&)</font></td>
- <td>Applies transform() on the vertices of polygon and sets the polygon to that described by the result of
- transforming its vertices. Also applies transform() on the holes
- of the polygon.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- T& <b>scale_up</b>(T& polygon, unsigned_area_type factor)</font></td>
- <td>Scales up outer shell and holes of an object that models
- polygon_90 by unsigned factor.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- T& <b>scale_down</b>(T& polygon, unsigned_area_type factor)</font></td>
- <td>Scales down outer shell and holes of an object that models
- polygon_90 by unsigned factor.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T, scaling_type><br />
- T& <b>scale</b>(T& rectangle, double scaling) </font></td>
- <td>Scales outer shell and holes of an object that models polygon_90 by
- floating point factor.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- T& <b>move</b>(T& polygon, orientation_2d,<br />
- coordinate_difference displacement)</font></td>
- <td>Adds displacement value to coordinate indicated by orientation_2d of
- vertices of an object that models polygon_90 .</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename polygon_type, typename point_type><br />
- polygon_type& <b>convolve</b>(polygon_type& polygon,<br />
+ <p>An object that is a model of <font face="Courier New">
+polygon_90_with_holes_concept</font> can be viewed as a model of any of
+its refinements if it is determined at runtime to conform to the
+restriction of those concepts. This concept casting is
+accomplished through the
+ <font face="Courier New">view_as<>()</font> function.</p>
+ <p><font face="Courier New">view_as<rectangle_concept>(polygon_90_with_holes_object)</font><br />
+ <font face="Courier New">view_as<polygon_90_concept>(polygon_90_with_holes_object)</font></p>
+ <p>The return value of <font face="Courier New">view_as<>()</font>
+can be passed into any interface that expects an object of the
+conceptual type specified in its template parameter.</p>
+ <h2>Functions</h2>
+ <table id="table1" border="1" width="100%">
+ <tbody>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+compact_iterator_type <b>begin_compact</b>(const T& polygon)</font></td>
+ <td><font face="Times New Roman">Expects a model of
+polygon_90. Returns the begin iterator over the range of
+coordinates that correspond to horizontal and vertical edges.</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+compact_iterator_type <b>end_compact</b>(const T& polygon)</font></td>
+ <td><font face="Times New Roman">Expects a model of
+polygon_90. Returns the end iterator over the range of
+coordinates that correspond to horizontal and vertical edges.</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+point_iterator_type <b>begin_points</b>(const T& polygon)</font></td>
+ <td><font face="Times New Roman">Expects a model of
+polygon_90_with_holes. Returns the begin iterator over the range
+of points that correspond to vertices of the polygon.</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+point_iterator_type <b>end_points</b>(const T& polygon)</font></td>
+ <td><font face="Times New Roman">Expects a model of
+polygon_90_with_holes. Returns the end iterator over the range of
+points that correspond to vertices of the polygon.</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+hole_iterator_type <b>begin_holes</b>(const T& polygon)</font></td>
+ <td><font face="Times New Roman">Expects a model of
+polygon_90_with_holes. Returns the begin iterator over the range
+of coordinates that correspond to horizontal and vertical edges.</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+hole_iterator_type <b>end_</b><b>holes</b>(const T& polygon)</font></td>
+ <td><font face="Times New Roman">Expects a model of
+polygon_90_with_holes. Returns the end iterator over the range of
+coordinates that correspond to horizontal and vertical edges.</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename iterator><br />
+void <b>set_compact</b>(T& polygon, iterator b, iterator e)</font></td>
+ <td><font face="Times New Roman">Expects a model of
+polygon_90_with_holes. Sets the polygon to the coordinate
+data range [b,e) that corresponds to .horizontal and vertical edges.</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename iterator><br />
+void <b>set_points</b>(T& polygon, iterator b, iterator e)</font></td>
+ <td><font face="Times New Roman">Expects a model of
+polygon_90_with_holes. Sets the polygon to the point data
+range [b,e) that corresponds to vertices of a manhattan polygon.
+Non-manhattan edges between successive input points results in
+undefined behavior.</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename iterator><br />
+void <b>set_holes</b>(T& polygon, iterator b, iterator e)</font></td>
+ <td><font face="Times New Roman">Expects a model of
+polygon_90_with_holes. Sets the polygon holes to the hole
+data range [b,e)</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+unsigned int <b>size</b>(const T& polygon)</font></td>
+ <td><font face="Times New Roman">Returns the number of
+edges in the outer shell of the polygon_90_with_holes. Does not
+include sizes of the holes.</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+T1& <b>assign</b>(T1& left, const T2& right)</font></td>
+ <td>Copies data from right object that models
+polygon_90_with_holes or one of its refinements into left object that
+models polygon_90_with_holes.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename point_type><br />
+bool <b>contains</b>(const T&, const point_type& point, <br />
+
+bool consider_touch=true)</font></td>
+ <td>Given an object that models polygon_90_with_holes and
+an object that models point, returns true if the polygon shell contains
+the point and one of its holes does not contain the point. If the
+consider_touch flag is true will return true if the point lies along
+the boundary of the polygon or one of its holes.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">// get the center
+coordinate<br />
+template <typename T, typename point_type><br />
+void <b>center</b>(point_type& p, const T& polygon)</font></td>
+ <td>Sets object that models point to the center point of
+the bounding box of an object that models polygon_90_with_holes.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename rectangle_type><br />
+bool <b>extents</b>(rectangle_type& bbox, const T& polygon)</font></td>
+ <td>Sets object that models rectangle to the bounding box
+of an object that models polygon_90_with_holes and returns true.
+Returns false and leaves bbox unchanged if polygon is empty.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+manhattan_area_type <b>area</b>(const T& polygon)</font></td>
+ <td>Returns the area of an object that models
+polygon_90_with_holes including subtracting the area of its holes from
+the area of the outer shell polygon.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+direction_1d <b>winding</b>(const T& polygon)</font></td>
+ <td>Returns the winding direction of an object that models
+polygon_90_with_holes, LOW == CLOCKWISE, HIGH = COUNTERCLOCKWISE.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+coordinate_difference <b>perimeter</b>(const T& polygon)</font></td>
+ <td>Returns the perimeter length of an object that models
+polygon_90, including the perimeters of the holes.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename transform_type><br />
+T& <b>transform</b>(T& polygon, const transform_type&)</font></td>
+ <td>Applies transform() on the vertices of polygon and sets
+the polygon to that described by the result of transforming its
+vertices. Also applies transform() on the holes of the polygon.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+T& <b>scale_up</b>(T& polygon, unsigned_area_type factor)</font></td>
+ <td>Scales up outer shell and holes of an object that
+models polygon_90 by unsigned factor.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+T& <b>scale_down</b>(T& polygon, unsigned_area_type factor)</font></td>
+ <td>Scales down outer shell and holes of an object that
+models polygon_90 by unsigned factor.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, scaling_type><br />
+T& <b>scale</b>(T& rectangle, double scaling) </font></td>
+ <td>Scales outer shell and holes of an object that models
+polygon_90 by floating point factor.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+T& <b>move</b>(T& polygon, orientation_2d,<br />
+ coordinate_difference
+displacement)</font></td>
+ <td>Adds displacement value to coordinate indicated by
+orientation_2d of vertices of an object that models polygon_90 .</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename polygon_type, typename point_type><br />
+polygon_type& <b>convolve</b>(polygon_type& polygon,<br />
+
const point_type& point)</font></td>
- <td>Convolves coordinate values of point with the outer shell and holes of an
- object that models polygon_90_with_holes.</td>
- </tr>
- </tbody></table>
- <h1>Polygon 90 With Holes Data</h1>
-
-<p>
-</p><p>The library provides a model of polygon 90 with holes concept declared
-<font face="Courier New">
-template<typename T> polygon_90_with_holes_data </font>where T is the
-coordinate type.</p>
-<p>This data type is used internally when a Manhattan polygon with holes is
-needed and is available to the library user who finds it convenient to use a
-library polygon data type instead of providing their own. The data type is
-implemented to be convenient to use with the library traits.</p>
-<h2>Members</h2>
-<table id="table2" border="1" width="100%">
- <tbody><tr>
- <td width="586"><b><font face="Courier New">geometry_type</font></b></td>
- <td><font face="Times New Roman">polygon_90_with_holes_concept</font></td>
- </tr>
- <tr>
- <td width="586"><b><font face="Courier New">coordinate_type</font></b></td>
- <td><font face="Times New Roman">T</font></td>
- </tr>
- <tr>
- <td width="586"><b><font face="Courier New">iterator_type</font></b></td>
- <td>Iterator over vertices point_data<T> vertices of polygon</td>
- </tr>
- <tr>
- <td width="586"><b><font face="Courier New">compact_iterator_type</font></b></td>
- <td><font face="Times New Roman">Iterator over non-redundant coordinates
- of the polygon, alternating x, y, x, y starting with an x, where each x
- corresponds to a vertical edge and each y corresponds to a horizontal
- edge.</font></td>
- </tr>
- <tr>
- <td width="586"><b><font face="Courier New">iterator_holes_type</font></b></td>
- <td><font face="Times New Roman">Iterator over hole polygons of type
- polygon_90_data<T>.</font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New"><b>polygon_90_with_holes_data</b>()</font></td>
- <td><font face="Times New Roman">Default constructs the </font>polygon.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New"><b>polygon_90_with_holes_data</b>(const
- polygon_90_with_holes_data& that)</font></td>
- <td><font face="Times New Roman">Copy construct</font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">polygon_90_with_holes_data& <b>
- <br />operator=</b>(const polygon_90_with_holes_data& that)</font></td>
- <td>Assignment operator.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T2><b> </b>polygon_90_with_holes_data&<b>
- <br /> operator=</b>(const T2& that) const</font></td>
- <td>Assign from an object that is a model of polygon 90 with holes.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">iterator_type <b>begin</b>()
- const</font></td>
- <td>Get the begin iterator over vertices of the polygon.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">iterator_type <b>end</b>()
- const</font></td>
- <td>Get the end iterator over vertices of the polygon.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">compact_iterator_type <b>begin_compact</b>()
- const</font></td>
- <td>Get the begin compact iterator over non-redundant coordinates of the
- polygon.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">compact_iterator_type <b>end_compact</b>()
- const</font></td>
- <td>Get the end compact iterator over non-redundant coordinates of the
- polygon.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">iterator_hole_type <b>begin_holes</b>()
- const</font></td>
- <td>Get the begin compact iterator over non-redundant coordinates of the
- polygon.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">iterator_hole_type <b>end_holes</b>()
- const</font></td>
- <td>Get the end compact iterator over non-redundant coordinates of the
- polygon.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">std::size_t <b>size</b>() const</font></td>
- <td>Get the number of elements in the sequence stored to the polygon,
- usually equal to the number of edges of the polygon.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">std::size_t <b>size_holes</b>() const</font></td>
- <td>Get the number of holes in the polygon</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename iT><b>
- <br /> </b>void <b>set</b>(iT begin_points, iT end_points)</font></td>
- <td>Sets the polygon to the iterator range of points. No check is
- performed to ensure the points describe a Manhattan figure, every other
- x and y value of the points is used to initialize the polygon.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename iT><b>
- <br /> </b>void <b>set_compact</b>(iT begin_coords, iT end_coords)</font></td>
- <td>Sets the polygon to the iterator range of coordinates. These
- coordinates correspond to the x values of vertical edges and y values of
- horizontal edges. It is expected that the sequence start with an x
- value and proceed x then y then x then y.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename iT><b>
- <br /> </b>void <b>set_holes</b>(iT begin_holes, iT end_choless)</font></td>
- <td>Sets the polygon holes the iterator range of hole polygons. These
- polygons in the input range may be either polygon_90_data or
- polygon_90_with_holes_data or any type that provides begin_compact and
- end_compact member functions.</td>
- </tr>
-</tbody></table>
- </td></tr><tr>
-<td style="background-color: rgb(238, 238, 238);" nowrap="1" valign="top">
- </td>
-<td style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;" valign="top" width="100%">
-
-
-<table class="docinfo" id="table3" frame="void" rules="none">
- <colgroup>
- <col class="docinfo-name" /><col class="docinfo-content" />
- </colgroup>
- <tbody valign="top">
- <tr>
- <th class="docinfo-name">Copyright:</th>
- <td>Copyright © Intel Corporation 2008-2010.</td>
- </tr>
- <tr class="field">
- <th class="docinfo-name">License:</th>
- <td class="field-body">Distributed under the Boost Software License,
- Version 1.0. (See accompanying file <tt class="literal">
- <span class="pre">LICENSE_1_0.txt</span></tt> or copy at
- <a class="reference" target="_top" href="http://www.boost.org/LICENSE_1_0.txt">
- http://www.boost.org/LICENSE_1_0.txt>)</td>
- </tr>
-</tbody></table>
-
-</td></tr></tbody></table></body></html>
\ No newline at end of file
+ <td>Convolves coordinate values of point with the outer
+shell and holes of an object that models polygon_90_with_holes.</td>
+ </tr>
+ </tbody>
+ </table>
+ <h1>Polygon 90 With Holes Data</h1>
+ <p> </p>
+ <p>The library provides a model of polygon 90 with holes concept
+declared
+ <font face="Courier New">template<typename T>
+polygon_90_with_holes_data </font>where T is the coordinate type.</p>
+ <p>This data type is used internally when a Manhattan polygon
+with holes is needed and is available to the library user who finds it
+convenient to use a library polygon data type instead of providing
+their own. The data type is implemented to be convenient to use
+with the library traits.</p>
+ <h2>Members</h2>
+ <table id="table2" border="1" width="100%">
+ <tbody>
+ <tr>
+ <td width="586"><b><font face="Courier New">geometry_type</font></b></td>
+ <td><font face="Times New Roman">polygon_90_with_holes_concept</font></td>
+ </tr>
+ <tr>
+ <td width="586"><b><font face="Courier New">coordinate_type</font></b></td>
+ <td><font face="Times New Roman">T</font></td>
+ </tr>
+ <tr>
+ <td width="586"><b><font face="Courier New">iterator_type</font></b></td>
+ <td>Iterator over vertices point_data<T> vertices of
+polygon</td>
+ </tr>
+ <tr>
+ <td width="586"><b><font face="Courier New">compact_iterator_type</font></b></td>
+ <td><font face="Times New Roman">Iterator over
+non-redundant coordinates of the polygon, alternating x, y, x, y
+starting with an x, where each x corresponds to a vertical edge and
+each y corresponds to a horizontal edge.</font></td>
+ </tr>
+ <tr>
+ <td width="586"><b><font face="Courier New">iterator_holes_type</font></b></td>
+ <td><font face="Times New Roman">Iterator over hole
+polygons of type polygon_90_data<T>.</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New"><b>polygon_90_with_holes_data</b>()</font></td>
+ <td><font face="Times New Roman">Default constructs the </font>polygon.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New"><b>polygon_90_with_holes_data</b>(const
+polygon_90_with_holes_data& that)</font></td>
+ <td><font face="Times New Roman">Copy construct</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">polygon_90_with_holes_data&
+ <b> <br />
+operator=</b>(const polygon_90_with_holes_data& that)</font></td>
+ <td>Assignment operator.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T2><b> </b>polygon_90_with_holes_data&<b> <br />
+operator=</b>(const T2& that) const</font></td>
+ <td>Assign from an object that is a model of polygon 90
+with holes.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">iterator_type <b>begin</b>()
+const</font></td>
+ <td>Get the begin iterator over vertices of the polygon.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">iterator_type <b>end</b>()
+const</font></td>
+ <td>Get the end iterator over vertices of the polygon.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">compact_iterator_type
+ <b>begin_compact</b>() const</font></td>
+ <td>Get the begin compact iterator over non-redundant
+coordinates of the polygon.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">compact_iterator_type
+ <b>end_compact</b>() const</font></td>
+ <td>Get the end compact iterator over non-redundant
+coordinates of the polygon.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">iterator_hole_type
+ <b>begin_holes</b>() const</font></td>
+ <td>Get the begin compact iterator over non-redundant
+coordinates of the polygon.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">iterator_hole_type
+ <b>end_holes</b>() const</font></td>
+ <td>Get the end compact iterator over non-redundant
+coordinates of the polygon.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">std::size_t <b>size</b>()
+const</font></td>
+ <td>Get the number of elements in the sequence stored to
+the polygon, usually equal to the number of edges of the polygon.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">std::size_t <b>size_holes</b>()
+const</font></td>
+ <td>Get the number of holes in the polygon</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename iT><b> <br />
+ </b>void <b>set</b>(iT begin_points, iT end_points)</font></td>
+ <td>Sets the polygon to the iterator range of points.
+No check is performed to ensure the points describe a Manhattan figure,
+every other x and y value of the points is used to initialize the
+polygon.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename iT><b> <br />
+ </b>void <b>set_compact</b>(iT begin_coords, iT end_coords)</font></td>
+ <td>Sets the polygon to the iterator range of
+coordinates. These coordinates correspond to the x values of
+vertical edges and y values of horizontal edges. It is expected
+that the sequence start with an x value and proceed x then y then x
+then y.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename iT><b> <br />
+ </b>void <b>set_holes</b>(iT begin_holes, iT end_choless)</font></td>
+ <td>Sets the polygon holes the iterator range of hole
+polygons. These polygons in the input range may be either
+polygon_90_data or polygon_90_with_holes_data or any type that provides
+begin_compact and end_compact member functions.</td>
+ </tr>
+ </tbody>
+ </table>
+ </td>
+ </tr>
+ <tr>
+ <td style="background-color: rgb(238, 238, 238);" nowrap="1"
+ valign="top"> </td>
+ <td
+ style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;"
+ valign="top" width="100%">
+ <table class="docinfo" id="table3" frame="void" rules="none">
+ <colgroup> <col class="docinfo-name" /><col
+ class="docinfo-content" /> </colgroup> <tbody valign="top">
+ <tr>
+ <th class="docinfo-name">Copyright:</th>
+ <td>Copyright © Intel Corporation 2008-2010.</td>
+ </tr>
+ <tr class="field">
+ <th class="docinfo-name">License:</th>
+ <td class="field-body">Distributed under the Boost Software
+License, Version 1.0. (See accompanying file <tt class="literal"> <span
+ class="pre">LICENSE_1_0.txt</span></tt> or copy at <a
+ class="reference" target="_top"
+ href="http://www.boost.org/LICENSE_1_0.txt">
+http://www.boost.org/LICENSE_1_0.txt>)</td>
+ </tr>
+ </tbody>
+ </table>
+ </td>
+ </tr>
+ </tbody>
+</table>
+</body>
+</html>
Modified: branches/release/libs/polygon/doc/gtl_polygon_concept.htm
==============================================================================
--- branches/release/libs/polygon/doc/gtl_polygon_concept.htm (original)
+++ branches/release/libs/polygon/doc/gtl_polygon_concept.htm 2013-04-15 18:27:46 EDT (Mon, 15 Apr 2013)
@@ -1,378 +1,433 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:(null)1="http://www.w3.org/TR/REC-html40" lang="en"><head>
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"
+ xmlns:v="urn:schemas-microsoft-com:vml"
+ xmlns:o="urn:schemas-microsoft-com:office:office"
+ xmlns:(null)1="http://www.w3.org/TR/REC-html40" lang="en">
+<head>
<!--
Copyright 2009-2010 Intel Corporation
license banner
---><title>Boost Polygon Library: Polygon Concept</title>
-
-
-
- <meta http-equiv="content-type" content="text/html;charset=ISO-8859-1" /><!-- <link type="text/css" rel="stylesheet" href="adobe_source.css"> --></head><body><table style="margin: 0pt; padding: 0pt; width: 100%;" border="0" cellpadding="0" cellspacing="0"><tbody><tr>
-<td style="background-color: rgb(238, 238, 238);" nowrap="1" valign="top">
- <div style="padding: 5px;" align="center">
- <img src="images/boost.png" border="0" height="86" width="277" /><a title="www.boost.org home page" href="http://www.boost.org/" tabindex="2" style="border: medium none ;">
- </a>
- </div>
- <div style="margin: 5px;">
- <h3 class="navbar">Contents</h3>
- <ul>
- <li>Boost.Polygon Main Page</li>
- <li>Design Overview</li>
- <li>Isotropy</li>
- <li>Coordinate Concept</li>
- <li>Interval Concept</li>
- <li>Point Concept</li>
+-->
+ <title>Boost Polygon Library: Polygon Concept</title>
+ <meta http-equiv="content-type" content="text/html;charset=ISO-8859-1" />
+<!-- <link type="text/css" rel="stylesheet" href="adobe_source.css"> -->
+</head>
+<body>
+<table style="margin: 0pt; padding: 0pt; width: 100%;" border="0"
+ cellpadding="0" cellspacing="0">
+ <tbody>
+ <tr>
+ <td style="background-color: rgb(238, 238, 238);" nowrap="1"
+ valign="top">
+ <div style="padding: 5px;" align="center"> <img
+ src="images/boost.png" border="0" height="86" width="277" /><a
+ title="www.boost.org home page" href="http://www.boost.org/"
+ tabindex="2" style="border: medium none ;"> </a> </div>
+ <div style="margin: 5px;">
+ <h3 class="navbar">Contents</h3>
+ <ul>
+ <li>Boost.Polygon Main Page</li>
+ <li>Design Overview</li>
+ <li>Isotropy</li>
+ <li>Coordinate Concept</li>
+ <li>Interval Concept</li>
+ <li>Point Concept</li>
<li>Segment Concept</li>
-
- <li>Rectangle Concept</li>
- <li>Polygon 90 Concept</li>
- <li>Polygon 90 With Holes Concept</li>
- <li>Polygon 45 Concept</li>
- <li>Polygon 45 With Holes Concept</li>
- <li>Polygon Concept</li>
- <li>Polygon With Holes Concept</li>
- <li>Polygon 90 Set Concept</li>
- <li>Polygon 45 Set Concept</li>
- <li>Polygon Set Concept</li>
- <li>Connectivity Extraction 90</li>
- <li>Connectivity Extraction 45</li>
- <li>Connectivity Extraction</li>
- <li>Property Merge 90</li>
- <li>Property Merge 45</li>
- <li>Property Merge</li>
+ <li>Rectangle Concept</li>
+ <li>Polygon 90 Concept</li>
+ <li><a href="gtl_polygon_90_with_holes_concept.htm">Polygon 90
+With Holes Concept</a></li>
+ <li>Polygon 45 Concept</li>
+ <li><a href="gtl_polygon_45_with_holes_concept.htm">Polygon 45
+With Holes Concept</a></li>
+ <li>Polygon Concept</li>
+ <li><a href="gtl_polygon_with_holes_concept.htm">Polygon With
+Holes Concept</a></li>
+ <li><a href="gtl_polygon_90_set_concept.htm">Polygon 90 Set
+Concept</a></li>
+ <li><a href="gtl_polygon_45_set_concept.htm">Polygon 45 Set
+Concept</a></li>
+ <li>Polygon Set Concept</li>
+ <li><a href="gtl_connectivity_extraction_90.htm">Connectivity
+Extraction 90</a></li>
+ <li><a href="gtl_connectivity_extraction_45.htm">Connectivity
+Extraction 45</a></li>
+ <li><a href="gtl_connectivity_extraction.htm">Connectivity
+Extraction</a></li>
+ <li>Property Merge 90</li>
+ <li>Property Merge 45</li>
+ <li>Property Merge</li>
<li><a href="voronoi_main.htm">Voronoi Main Page<br />
-</a></li>
+ </a></li>
<li>Voronoi Benchmark<br />
</li>
<li>Voronoi Builder</li>
- <li><a href="voronoi_diagram.htm">Voronoi Diagram<br />
-</a></li>
- <li>Voronoi Predicates</li>
- <li>Voronoi Robust FPT<br />
- </li>
-
-
- </ul>
- <h3 class="navbar">Other Resources</h3>
- <ul>
+ <li>Voronoi Diagram</li>
+ </ul>
+ <h3 class="navbar">Other Resources</h3>
+ <ul>
<li>GTL Boostcon 2009 Paper</li>
- <li><a href="GTL_boostcon_draft03.pdf">GTL Boostcon 2009
- Presentation</a></li>
+ <li><a href="GTL_boostcon_draft03.pdf">GTL Boostcon 2009
+Presentation</a></li>
<li>Performance Analysis</li>
<li>Layout Versus Schematic Tutorial</li>
<li>Minkowski Sum Tutorial</li>
<li>Voronoi Basic Tutorial</li>
- <li>Voronoi Advanced Tutorial</li>
-</ul>
- </div>
- <h3 class="navbar">Polygon Sponsor</h3>
- <div style="padding: 5px;" align="center">
- <img src="images/intlogo.gif" border="0" height="51" width="127" /><a title="www.adobe.com home page" href="http://www.adobe.com/" tabindex="2" style="border: medium none ;">
- </a>
- </div>
-</td>
-<td style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;" valign="top" width="100%">
-
-<!-- End Header -->
-
-<br />
-<p>
-</p><h1>Polygon Concept</h1>
-
-<p>
-</p><p>The polygon concept tag is <font face="Courier New">
+ <li><a href="voronoi_advanced_tutorial.htm">Voronoi Advanced
+Tutorial</a></li>
+ </ul>
+ </div>
+ <h3 class="navbar">Polygon Sponsor</h3>
+ <div style="padding: 5px;" align="center"> <img
+ src="images/intlogo.gif" border="0" height="51" width="127" /><a
+ title="www.adobe.com home page" href="http://www.adobe.com/"
+ tabindex="2" style="border: medium none ;"> </a> </div>
+ </td>
+ <td
+ style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;"
+ valign="top" width="100%">
+<!-- End Header --><br />
+ <p>
+ </p>
+ <h1>Polygon Concept</h1>
+ <p> </p>
+ <p>The polygon concept tag is <font face="Courier New">
polygon_concept</font></p>
-<p>
-To register a user defined type as a model of
-<font face="Times New Roman">polygon </font>concept, specialize the
-geometry concept meta-function for that type. In the example below CPolygon is registered as a model of
-polygon concept.</p><p>
-<font face="Courier New">template <><br />
-struct geometry_concept<CPolygon> { typedef polygon_concept type; };</font></p><p>
-<font face="Times New Roman">The semantic of a polygon is that it can provide
-iterators over the points that represent its vertices. It is acceptable to
-have the last edge explict with the first and last point equal to each other or
-implied by this segement that would connect the first and last point. A
-mutable polygon must also be able to set its geometry based on an interator
-range over such points. A std::vector<point_data<int> > or std::list<point_data<int>
->
-could be made models of polygon_concept by simply providing access to their
-iterators through traits. Library functions that create polygon objects
-require that those objects provide a default constructor.</font></p><p>
-<font face="Times New Roman">Below is shown the default polygon traits.
-Specialization of these traits is required for types that don't conform to the
-default behavior. Note that these same traits are also used by several
-other polygon concepts through SFINE enable template parameter. The SFINE
-enable parameter also allows the library to provide default specialization that
-work for any object that models the 90 degree polygon concepts.</font></p><p>
-<font face="Courier New">template <typename T, typename enable = gtl_yes><br />
+ <p> To register a user defined type as a model of <font
+ face="Times New Roman">polygon </font>concept, specialize the
+geometry concept meta-function for that type. In the example
+below CPolygon is registered as a model of polygon concept.</p>
+ <p> <font face="Courier New">template <><br />
+struct geometry_concept<CPolygon> { typedef polygon_concept type;
+};</font></p>
+ <p> <font face="Times New Roman">The semantic of a polygon is
+that it can provide iterators over the points that represent its
+vertices. It is acceptable to have the last edge explict with the
+first and last point equal to each other or implied by this segement
+that would connect the first and last point. A mutable polygon
+must also be able to set its geometry based on an interator range over
+such points. A std::vector<point_data<int> > or
+std::list<point_data<int> > could be made models of
+polygon_concept by simply providing access to their iterators through
+traits. Library functions that create polygon objects require
+that those objects provide a default constructor.</font></p>
+ <p> <font face="Times New Roman">Below is shown the default
+polygon traits. Specialization of these traits is required for
+types that don't conform to the default behavior. Note that these
+same traits are also used by several other polygon concepts through
+SFINE enable template parameter. The SFINE enable parameter also
+allows the library to provide default specialization that work for any
+object that models the 90 degree polygon concepts.</font></p>
+ <p><font face="Courier New">template <typename T, typename
+enable = gtl_yes><br />
struct polygon_traits {};<br />
-<br />
+ <br />
template <typename T><br />
struct polygon_traits<T, <br />
typename gtl_or_4<<br />
- typename gtl_same_type<typename geometry_concept<T>::type,
-polygon_concept>::type,<br />
- typename gtl_same_type<typename geometry_concept<T>::type,
-polygon_concept>::type,<br />
- typename gtl_same_type<typename geometry_concept<T>::type,
-polygon_with_holes_concept>::type,<br />
- typename gtl_same_type<typename geometry_concept<T>::type,
-polygon_with_holes_concept>::type<br />
+ typename gtl_same_type<typename
+geometry_concept<T>::type, polygon_concept>::type,<br />
+ typename gtl_same_type<typename
+geometry_concept<T>::type, polygon_concept>::type,<br />
+ typename gtl_same_type<typename
+geometry_concept<T>::type, polygon_with_holes_concept>::type,<br />
+ typename gtl_same_type<typename
+geometry_concept<T>::type, polygon_with_holes_concept>::type<br />
>::type> {<br />
- typedef typename T::coordinate_type coordinate_type;<br />
- typedef typename T::iterator_type iterator_type;<br />
+ typedef typename T::coordinate_type
+coordinate_type;<br />
+ typedef typename T::iterator_type
+iterator_type;<br />
typedef typename T::point_type point_type;<br />
- static inline iterator_type begin_points(const T& t) {<br />
+ static inline iterator_type begin_points(const
+T& t) {<br />
return t.begin();<br />
}<br />
- static inline iterator_type end_points(const T& t) {<br />
+ static inline iterator_type end_points(const
+T& t) {<br />
return t.end();<br />
}<br />
- static inline unsigned int size(const T& t) {<br />
+ static inline unsigned int size(const T&
+t) {<br />
return t.size();<br />
}<br />
- static inline winding_direction winding(const T& t) {<br />
- return unknown_winding;<br />
+ static inline winding_direction winding(const
+T& t) {<br />
+ return
+unknown_winding;<br />
}<br />
};</font></p>
-<p><font face="Courier New">template <typename T, typename enable = void><br />
+ <p><font face="Courier New">template <typename T, typename
+enable = void><br />
struct polygon_mutable_traits {<br />
template <typename iT><br />
- static inline T& set_points(T& t, iT input_begin, iT
-input_end) {<br />
- t.set(input_begin,
-input_end);<br />
+ static inline T& set_points(T& t, iT
+input_begin, iT input_end) {<br />
+
+t.set(input_begin, input_end);<br />
return t;<br />
}<br />
};</font></p>
-<p>Example code custom_polygon.cpp
-demonstrates mapping a
- user defined polygon class to the library polygon_concept</p>
-<p>An object that is a model of <font face="Courier New">
-polygon_concept</font> can be viewed as a model of any of its
-refinements if it is determined at runtime to conform to the restriction of
-those concepts. This concept casting is accomplished through the
-<font face="Courier New">view_as<>()</font> function.</p>
-<p><font face="Courier New">view_as<rectangle_concept>(polygon_object)</font><br />
-<font face="Courier New">view_as<polygon_90_concept>(polygon_object)</font><br />
-<font face="Courier New">view_as<polygon_45_concept>(polygon_object)</font></p>
-<p>The return value of <font face="Courier New">view_as<>()</font> can be
-passed into any interface that expects an object of the conceptual type
-specified in its template parameter. </p>
-<h2>Functions</h2>
-<table id="table1" border="1" width="100%">
- <tbody><tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- point_iterator_type <b>begin_points</b>(const T& polygon)</font></td>
- <td><font face="Times New Roman">Expects a model of polygon.
- Returns the begin iterator over the range of points that correspond to
- vertices of the polygon.</font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- point_iterator_type <b>end_points</b>(const T& polygon)</font></td>
- <td><font face="Times New Roman">Expects a model of polygon.
- Returns the end iterator over the range of points that correspond to
- vertices of the polygon.</font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T, typename
- iterator><br />
- void <b>set_points</b>(T& polygon, iterator b, iterator e)</font></td>
- <td><font face="Times New Roman">Expects a model of polygon.
- Sets the polygon to the point data range [b,e) that corresponds to
- vertices of a manhattan polygon.</font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- unsigned int <b>size</b>(const T& polygon)</font></td>
- <td><font face="Times New Roman">Returns the number of edges in the
- polygon.</font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- T1& <b>assign</b>(T1& left, const T2& right)</font></td>
- <td>Copies data from right object that models polygon into left object
- that models polygon.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T,
- typename point_type><br />
- bool <b>contains</b>(const T&, const point_type& point, <br />
-
- bool consider_touch=true)</font></td>
- <td>Given an object that models polygon and an object that models
- point, returns true
- if the polygon contains the point. If the consider_touch
- flag is true will return true if the point lies along the boundary of
- the polygon. Linear wrt. vertices.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">// get the center coordinate<br />
- template <typename T, typename point_type><br />
- void <b>center</b>(point_type& p, const T& polygon)</font></td>
- <td>Sets object that models point to the center point of the bounding
- box of an object that models polygon. Linear wrt. vertices.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T,
- typename rectangle_type><br />
- bool <b>extents</b>(rectangle_type& bbox, const T& polygon)</font></td>
- <td>Sets object that models rectangle to the bounding box of an object
- that models polygon and returns true. Returns false and leaves
- bbox unchanged if polygon is empty. Linear wrt. vertices.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- area_type <b>area</b>(const T& polygon)</font></td>
- <td>Returns the area of an object
- that models polygon. Linear wrt. vertices.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- direction_1d <b>winding</b>(const T& polygon)</font></td>
- <td>Returns the winding direction of an object
- that models polygon, LOW == CLOCKWISE, HIGH = COUNTERCLOCKWISE.
- Complexity depends upon winding trait.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- coordinate_distance <b>perimeter</b>(const T& polygon)</font></td>
- <td>Returns the perimeter length of an object
- that models polygon. Linear wrt. vertices.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T,
- typename transform_type><br />
- T& <b>transform</b>(T& polygon, const transform_type&)</font></td>
- <td>Applies transform() on the vertices of polygon and sets the polygon to that described by the result of
- transforming its vertices. Linear wrt. vertices.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- T& <b>scale_up</b>(T& polygon, unsigned_area_type factor)</font></td>
- <td>Scales up coordinate of an object that models
- polygon by unsigned factor. Linear wrt. vertices.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- T& <b>scale_down</b>(T& polygon, unsigned_area_type factor)</font></td>
- <td>Scales down coordinates of an object that models
- polygon by unsigned factor. Linear wrt. vertices.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T, scaling_type><br />
- T& <b>scale</b>(T& rectangle, double scaling) </font></td>
- <td>Scales coordinates of an object that models polygon by floating
- point factor. Linear wrt. vertices.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- T& <b>move</b>(T& polygon, orientation_2d,<br />
- coordinate_difference displacement)</font></td>
- <td>Adds displacement value to coordinate indicated by orientation_2d of
- vertices of an object that models polygon . Linear wrt. vertices.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename polygon_type, typename point_type><br />
- polygon_type& <b>convolve</b>(polygon_type& polygon,<br />
+ <p>Example code custom_polygon.cpp
+demonstrates mapping a user defined polygon class to the library
+polygon_concept</p>
+ <p>An object that is a model of <font face="Courier New">
+polygon_concept</font> can be viewed as a model of any of its
+refinements if it is determined at runtime to conform to the
+restriction of those concepts. This concept casting is
+accomplished through the
+ <font face="Courier New">view_as<>()</font> function.</p>
+ <p><font face="Courier New">view_as<rectangle_concept>(polygon_object)</font><br />
+ <font face="Courier New">view_as<polygon_90_concept>(polygon_object)</font><br />
+ <font face="Courier New">view_as<polygon_45_concept>(polygon_object)</font></p>
+ <p>The return value of <font face="Courier New">view_as<>()</font>
+can be passed into any interface that expects an object of the
+conceptual type specified in its template parameter. </p>
+ <h2>Functions</h2>
+ <table id="table1" border="1" width="100%">
+ <tbody>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+point_iterator_type <b>begin_points</b>(const T& polygon)</font></td>
+ <td><font face="Times New Roman">Expects a model of
+polygon. Returns the begin iterator over the range of points that
+correspond to vertices of the polygon.</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+point_iterator_type <b>end_points</b>(const T& polygon)</font></td>
+ <td><font face="Times New Roman">Expects a model of
+polygon. Returns the end iterator over the range of points that
+correspond to vertices of the polygon.</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename iterator><br />
+void <b>set_points</b>(T& polygon, iterator b, iterator e)</font></td>
+ <td><font face="Times New Roman">Expects a model of
+polygon. Sets the polygon to the point data range [b,e)
+that corresponds to vertices of a manhattan polygon.</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+unsigned int <b>size</b>(const T& polygon)</font></td>
+ <td><font face="Times New Roman">Returns the number of
+edges in the polygon.</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+T1& <b>assign</b>(T1& left, const T2& right)</font></td>
+ <td>Copies data from right object that models polygon into
+left object that models polygon.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename point_type><br />
+bool <b>contains</b>(const T&, const point_type& point, <br />
+
+bool consider_touch=true)</font></td>
+ <td>Given an object that models polygon and an object that
+models point, returns true if the polygon contains the point. If
+the consider_touch flag is true will return true if the point lies
+along the boundary of the polygon. Linear wrt. vertices.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">// get the center
+coordinate<br />
+template <typename T, typename point_type><br />
+void <b>center</b>(point_type& p, const T& polygon)</font></td>
+ <td>Sets object that models point to the center point of
+the bounding box of an object that models polygon. Linear wrt.
+vertices.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename rectangle_type><br />
+bool <b>extents</b>(rectangle_type& bbox, const T& polygon)</font></td>
+ <td>Sets object that models rectangle to the bounding box
+of an object that models polygon and returns true. Returns false
+and leaves bbox unchanged if polygon is empty. Linear wrt.
+vertices.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+area_type <b>area</b>(const T& polygon)</font></td>
+ <td>Returns the area of an object that models
+polygon. Linear wrt. vertices.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+direction_1d <b>winding</b>(const T& polygon)</font></td>
+ <td>Returns the winding direction of an object that models
+polygon, LOW == CLOCKWISE, HIGH = COUNTERCLOCKWISE. Complexity
+depends upon winding trait.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+coordinate_distance <b>perimeter</b>(const T& polygon)</font></td>
+ <td>Returns the perimeter length of an object that models
+polygon. Linear wrt. vertices.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename transform_type><br />
+T& <b>transform</b>(T& polygon, const transform_type&)</font></td>
+ <td>Applies transform() on the vertices of polygon and sets
+the polygon to that described by the result of transforming its
+vertices. Linear wrt. vertices.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+T& <b>scale_up</b>(T& polygon, unsigned_area_type factor)</font></td>
+ <td>Scales up coordinate of an object that models polygon
+by unsigned factor. Linear wrt. vertices.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+T& <b>scale_down</b>(T& polygon, unsigned_area_type factor)</font></td>
+ <td>Scales down coordinates of an object that models
+polygon by unsigned factor. Linear wrt. vertices.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, scaling_type><br />
+T& <b>scale</b>(T& rectangle, double scaling) </font></td>
+ <td>Scales coordinates of an object that models polygon by
+floating point factor. Linear wrt. vertices.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+T& <b>move</b>(T& polygon, orientation_2d,<br />
+ coordinate_difference
+displacement)</font></td>
+ <td>Adds displacement value to coordinate indicated by
+orientation_2d of vertices of an object that models polygon .
+Linear wrt. vertices.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename polygon_type, typename point_type><br />
+polygon_type& <b>convolve</b>(polygon_type& polygon,<br />
+
const point_type& point)</font></td>
- <td>Convolves coordinate values of point with vertices of an
- object that models polygon. Linear wrt. vertices.</td>
- </tr>
- </tbody></table>
- <h1>Polygon Data</h1>
-
-<p>
-</p><p>The library provides a model of polygon concept declared
-<font face="Courier New">
-template<typename T> polygon_data </font>where T is the coordinate type.</p>
-<p>This data type is used internally when a polygon is needed and is available
-to the library user who finds it convenient to use a library polygon data type
-instead of providing their own. The data type is implemented to be
-convenient to use with the library traits.</p>
-<p>Example code polygon_usage.cpp
-demonstrates using
- the library provided polygon data types and functions</p>
-<h2>Members</h2>
-<table id="table2" border="1" width="100%">
- <tbody><tr>
- <td width="586"><b><font face="Courier New">geometry_type</font></b></td>
- <td><font face="Times New Roman">polygon_concept</font></td>
- </tr>
- <tr>
- <td width="586"><b><font face="Courier New">coordinate_type</font></b></td>
- <td><font face="Times New Roman">T</font></td>
- </tr>
- <tr>
- <td width="586"><b><font face="Courier New">iterator_type</font></b></td>
- <td>Iterator over vertices point_data<T> vertices of polygon</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New"><b>polygon_data</b>()</font></td>
- <td><font face="Times New Roman">Default constructs the </font>polygon.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New"><b>polygon_data</b>(const
- polygon_data& that)</font></td>
- <td><font face="Times New Roman">Copy construct</font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">polygon_data& <b>operator=</b>(const
- polygon_data& that)</font></td>
- <td>Assignment operator.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T2><b>
- <br /> </b>polygon_data& <b>operator=</b>(const T2& that) const</font></td>
- <td>Assign from an object that is a model of polygon.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">iterator_type <b>begin</b>()
- const</font></td>
- <td>Get the begin iterator over vertices of the polygon.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">iterator_type <b>end</b>()
- const</font></td>
- <td>Get the end iterator over vertices of the polygon.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">std::size_t <b>size</b>() const</font></td>
- <td>Get the number of elements in the sequence stored to the polygon,
- usually equal to the number of edges of the polygon.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename iT><b>
- <br /> </b>void <b>set</b>(iT begin_points, iT end_points)</font></td>
- <td>Sets the polygon to the iterator range of points. </td>
- </tr>
-</tbody></table>
- </td></tr><tr>
-<td style="background-color: rgb(238, 238, 238);" nowrap="1" valign="top">
- </td>
-<td style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;" valign="top" width="100%">
-
-
-<table class="docinfo" id="table3" frame="void" rules="none">
- <colgroup>
- <col class="docinfo-name" /><col class="docinfo-content" />
- </colgroup>
- <tbody valign="top">
- <tr>
- <th class="docinfo-name">Copyright:</th>
- <td>Copyright © Intel Corporation 2008-2010.</td>
- </tr>
- <tr class="field">
- <th class="docinfo-name">License:</th>
- <td class="field-body">Distributed under the Boost Software License,
- Version 1.0. (See accompanying file <tt class="literal">
- <span class="pre">LICENSE_1_0.txt</span></tt> or copy at
- <a class="reference" target="_top" href="http://www.boost.org/LICENSE_1_0.txt">
- http://www.boost.org/LICENSE_1_0.txt>)</td>
- </tr>
-</tbody></table>
-
-</td></tr></tbody></table></body></html>
\ No newline at end of file
+ <td>Convolves coordinate values of point with vertices of
+an object that models polygon. Linear wrt. vertices.</td>
+ </tr>
+ </tbody>
+ </table>
+ <h1>Polygon Data</h1>
+ <p> </p>
+ <p>The library provides a model of polygon concept declared
+ <font face="Courier New">template<typename T> polygon_data </font>where
+T is the coordinate type.</p>
+ <p>This data type is used internally when a polygon is needed and
+is available to the library user who finds it convenient to use a
+library polygon data type instead of providing their own. The
+data type is implemented to be convenient to use with the library
+traits.</p>
+ <p>Example code polygon_usage.cpp
+demonstrates using the library provided polygon data types and functions</p>
+ <h2>Members</h2>
+ <table id="table2" border="1" width="100%">
+ <tbody>
+ <tr>
+ <td width="586"><b><font face="Courier New">geometry_type</font></b></td>
+ <td><font face="Times New Roman">polygon_concept</font></td>
+ </tr>
+ <tr>
+ <td width="586"><b><font face="Courier New">coordinate_type</font></b></td>
+ <td><font face="Times New Roman">T</font></td>
+ </tr>
+ <tr>
+ <td width="586"><b><font face="Courier New">iterator_type</font></b></td>
+ <td>Iterator over vertices point_data<T> vertices of
+polygon</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New"><b>polygon_data</b>()</font></td>
+ <td><font face="Times New Roman">Default constructs the </font>polygon.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New"><b>polygon_data</b>(const
+polygon_data& that)</font></td>
+ <td><font face="Times New Roman">Copy construct</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">polygon_data& <b>operator=</b>(const
+polygon_data& that)</font></td>
+ <td>Assignment operator.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T2><b> <br />
+ </b>polygon_data& <b>operator=</b>(const T2& that)
+const</font></td>
+ <td>Assign from an object that is a model of polygon.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">iterator_type <b>begin</b>()
+const</font></td>
+ <td>Get the begin iterator over vertices of the polygon.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">iterator_type <b>end</b>()
+const</font></td>
+ <td>Get the end iterator over vertices of the polygon.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">std::size_t <b>size</b>()
+const</font></td>
+ <td>Get the number of elements in the sequence stored to
+the polygon, usually equal to the number of edges of the polygon.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename iT><b> <br />
+ </b>void <b>set</b>(iT begin_points, iT end_points)</font></td>
+ <td>Sets the polygon to the iterator range of points.
+ </td>
+ </tr>
+ </tbody>
+ </table>
+ </td>
+ </tr>
+ <tr>
+ <td style="background-color: rgb(238, 238, 238);" nowrap="1"
+ valign="top"> </td>
+ <td
+ style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;"
+ valign="top" width="100%">
+ <table class="docinfo" id="table3" frame="void" rules="none">
+ <colgroup> <col class="docinfo-name" /><col
+ class="docinfo-content" /> </colgroup> <tbody valign="top">
+ <tr>
+ <th class="docinfo-name">Copyright:</th>
+ <td>Copyright © Intel Corporation 2008-2010.</td>
+ </tr>
+ <tr class="field">
+ <th class="docinfo-name">License:</th>
+ <td class="field-body">Distributed under the Boost Software
+License, Version 1.0. (See accompanying file <tt class="literal"> <span
+ class="pre">LICENSE_1_0.txt</span></tt> or copy at <a
+ class="reference" target="_top"
+ href="http://www.boost.org/LICENSE_1_0.txt">
+http://www.boost.org/LICENSE_1_0.txt>)</td>
+ </tr>
+ </tbody>
+ </table>
+ </td>
+ </tr>
+ </tbody>
+</table>
+</body>
+</html>
Modified: branches/release/libs/polygon/doc/gtl_polygon_set_concept.htm
==============================================================================
--- branches/release/libs/polygon/doc/gtl_polygon_set_concept.htm (original)
+++ branches/release/libs/polygon/doc/gtl_polygon_set_concept.htm 2013-04-15 18:27:46 EDT (Mon, 15 Apr 2013)
@@ -1,672 +1,732 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:(null)1="http://www.w3.org/TR/REC-html40" lang="en"><head>
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"
+ xmlns:v="urn:schemas-microsoft-com:vml"
+ xmlns:o="urn:schemas-microsoft-com:office:office"
+ xmlns:(null)1="http://www.w3.org/TR/REC-html40" lang="en">
+<head>
<!--
Copyright 2009-2010 Intel Corporation
license banner
---><title>Boost Polygon Library: Polygon Set Concept</title>
-
-
-
- <meta http-equiv="content-type" content="text/html;charset=ISO-8859-1" /><!-- <link type="text/css" rel="stylesheet" href="adobe_source.css"> --></head><body><table style="margin: 0pt; padding: 0pt; width: 100%;" border="0" cellpadding="0" cellspacing="0"><tbody><tr>
-<td style="background-color: rgb(238, 238, 238);" nowrap="1" valign="top">
- <div style="padding: 5px;" align="center">
- <img src="images/boost.png" border="0" height="86" width="277" /><a title="www.boost.org home page" href="http://www.boost.org/" tabindex="2" style="border: medium none ;">
- </a>
- </div>
- <div style="margin: 5px;">
- <h3 class="navbar">Contents</h3>
- <ul>
- <li>Boost.Polygon Main Page</li>
- <li>Design Overview</li>
- <li>Isotropy</li>
- <li>Coordinate Concept</li>
- <li>Interval Concept</li>
- <li>Point Concept</li>
+-->
+ <title>Boost Polygon Library: Polygon Set Concept</title>
+ <meta http-equiv="content-type" content="text/html;charset=ISO-8859-1" />
+<!-- <link type="text/css" rel="stylesheet" href="adobe_source.css"> -->
+</head>
+<body>
+<table style="margin: 0pt; padding: 0pt; width: 100%;" border="0"
+ cellpadding="0" cellspacing="0">
+ <tbody>
+ <tr>
+ <td style="background-color: rgb(238, 238, 238);" nowrap="1"
+ valign="top">
+ <div style="padding: 5px;" align="center"> <img
+ src="images/boost.png" border="0" height="86" width="277" /><a
+ title="www.boost.org home page" href="http://www.boost.org/"
+ tabindex="2" style="border: medium none ;"> </a> </div>
+ <div style="margin: 5px;">
+ <h3 class="navbar">Contents</h3>
+ <ul>
+ <li>Boost.Polygon Main Page</li>
+ <li>Design Overview</li>
+ <li>Isotropy</li>
+ <li>Coordinate Concept</li>
+ <li>Interval Concept</li>
+ <li>Point Concept</li>
<li>Segment Concept</li>
-
- <li>Rectangle Concept</li>
- <li>Polygon 90 Concept</li>
- <li>Polygon 90 With Holes Concept</li>
- <li>Polygon 45 Concept</li>
- <li>Polygon 45 With Holes Concept</li>
- <li>Polygon Concept</li>
- <li>Polygon With Holes Concept</li>
- <li>Polygon 90 Set Concept</li>
- <li>Polygon 45 Set Concept</li>
- <li>Polygon Set Concept</li>
- <li>Connectivity Extraction 90</li>
- <li>Connectivity Extraction 45</li>
- <li>Connectivity Extraction</li>
- <li>Property Merge 90</li>
- <li>Property Merge 45</li>
- <li>Property Merge</li>
+ <li>Rectangle Concept</li>
+ <li>Polygon 90 Concept</li>
+ <li><a href="gtl_polygon_90_with_holes_concept.htm">Polygon 90
+With Holes Concept</a></li>
+ <li>Polygon 45 Concept</li>
+ <li><a href="gtl_polygon_45_with_holes_concept.htm">Polygon 45
+With Holes Concept</a></li>
+ <li>Polygon Concept</li>
+ <li><a href="gtl_polygon_with_holes_concept.htm">Polygon With
+Holes Concept</a></li>
+ <li><a href="gtl_polygon_90_set_concept.htm">Polygon 90 Set
+Concept</a></li>
+ <li><a href="gtl_polygon_45_set_concept.htm">Polygon 45 Set
+Concept</a></li>
+ <li>Polygon Set Concept</li>
+ <li><a href="gtl_connectivity_extraction_90.htm">Connectivity
+Extraction 90</a></li>
+ <li><a href="gtl_connectivity_extraction_45.htm">Connectivity
+Extraction 45</a></li>
+ <li><a href="gtl_connectivity_extraction.htm">Connectivity
+Extraction</a></li>
+ <li>Property Merge 90</li>
+ <li>Property Merge 45</li>
+ <li>Property Merge</li>
<li><a href="voronoi_main.htm">Voronoi Main Page<br />
-</a></li>
+ </a></li>
<li>Voronoi Benchmark<br />
</li>
<li>Voronoi Builder</li>
- <li><a href="voronoi_diagram.htm">Voronoi Diagram<br />
-</a></li>
- <li>Voronoi Predicates</li>
- <li>Voronoi Robust FPT<br />
- </li>
-
-
- </ul>
- <h3 class="navbar">Other Resources</h3>
- <ul>
+ <li>Voronoi Diagram</li>
+ </ul>
+ <h3 class="navbar">Other Resources</h3>
+ <ul>
<li>GTL Boostcon 2009 Paper</li>
- <li><a href="GTL_boostcon_draft03.pdf">GTL Boostcon 2009
- Presentation</a></li>
+ <li><a href="GTL_boostcon_draft03.pdf">GTL Boostcon 2009
+Presentation</a></li>
<li>Performance Analysis</li>
<li>Layout Versus Schematic Tutorial</li>
<li>Minkowski Sum Tutorial</li>
<li>Voronoi Basic Tutorial</li>
- <li>Voronoi Advanced Tutorial</li>
-</ul>
- </div>
- <h3 class="navbar">Polygon Sponsor</h3>
- <div style="padding: 5px;" align="center">
- <img src="images/intlogo.gif" border="0" height="51" width="127" /><a title="www.adobe.com home page" href="http://www.adobe.com/" tabindex="2" style="border: medium none ;">
- </a>
- </div>
-</td>
-<td style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;" valign="top" width="100%">
-
-<!-- End Header -->
-
-<br />
-<p>
-</p><h1>Polygon Set Concept</h1>
-
-<p>
-</p><p>The polygon_set concept tag is <font face="Courier New">
+ <li><a href="voronoi_advanced_tutorial.htm">Voronoi Advanced
+Tutorial</a></li>
+ </ul>
+ </div>
+ <h3 class="navbar">Polygon Sponsor</h3>
+ <div style="padding: 5px;" align="center"> <img
+ src="images/intlogo.gif" border="0" height="51" width="127" /><a
+ title="www.adobe.com home page" href="http://www.adobe.com/"
+ tabindex="2" style="border: medium none ;"> </a> </div>
+ </td>
+ <td
+ style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;"
+ valign="top" width="100%">
+<!-- End Header --><br />
+ <p>
+ </p>
+ <h1>Polygon Set Concept</h1>
+ <p> </p>
+ <p>The polygon_set concept tag is <font face="Courier New">
polygon_set_concept</font></p>
-<p>
-<font face="Times New Roman">The semantic of a polygon_set is zero or more
-geometry regions. A Polygon Set Concept may be defined with floating point
-coordinates, but a snap rounding distance of one integer unit will still be
-applied, furthermore, geometry outside the domain where one integer unit is
-sufficient to provide robustness may lead to undefined behavior in algorithms.
-It is recommended to use integer coordinates for robust operations. In the
-case that data represented contains only Manhattan geometry a runtime check will
-default to the Manhattan algorithm. The results of which are identical to
-what the general algorithm would do, but obtained more efficiently. In the
-case that the data represented contains only Manhattan and 45-degree geometry a
-runtime check will default to the faster 45-degree algorithm. The results
-of which may differ slight from what the general algorithm would do because
-non-integer intersections will be handled differently.</font></p><p>Users are recommended to use std::vector and std::list of user defined polygons
-or library provided polygon_set_data<coordinate_type> objects. Lists
-and vectors of models of polygon_concept or polygon_with_holes_concept are automatically models of polygon_set_concept.</p>
-<p>Example code custom_polygon_set.cpp
- demonstrates mapping a user defined class to the library polygon_set_concept</p>
-<p>An object that is a model of <font face="Courier New">
-polygon_set_concept</font> can be viewed as a model of <font face="Courier New">
+ <p> <font face="Times New Roman">The semantic of a polygon_set
+is zero or more geometry regions. A Polygon Set Concept may be
+defined with floating point coordinates, but a snap rounding distance
+of one integer unit will still be applied, furthermore, geometry
+outside the domain where one integer unit is sufficient to provide
+robustness may lead to undefined behavior in algorithms. It is
+recommended to use integer coordinates for robust operations. In
+the case that data represented contains only Manhattan geometry a
+runtime check will default to the Manhattan algorithm. The
+results of which are identical to what the general algorithm would do,
+but obtained more efficiently. In the case that the data
+represented contains only Manhattan and 45-degree geometry a runtime
+check will default to the faster 45-degree algorithm. The results
+of which may differ slight from what the general algorithm would do
+because non-integer intersections will be handled differently.</font></p>
+ <p>Users are recommended to use std::vector and std::list of user
+defined polygons or library provided
+polygon_set_data<coordinate_type> objects. Lists and
+vectors of models of polygon_concept or polygon_with_holes_concept are
+automatically models of polygon_set_concept.</p>
+ <p>Example code custom_polygon_set.cpp
+demonstrates mapping a user defined class to the library
+polygon_set_concept</p>
+ <p>An object that is a model of <font face="Courier New">
+polygon_set_concept</font> can be viewed as a model of <font
+ face="Courier New">
polygon_90_set_concept</font> or <font face="Courier New">
-polygon_45_set_concept</font> if it is determined at runtime to conform to the
-restrictions of those concepts. This concept casting is accomplished
-through the <font face="Courier New">view_as<>()</font> function.</p>
-<p><font face="Courier New">view_as<polygon_90_set_concept>(polygon_set_object)<br />
+polygon_45_set_concept</font> if it is determined at runtime to conform
+to the restrictions of those concepts. This concept casting is
+accomplished through the <font face="Courier New">view_as<>()</font>
+function.</p>
+ <p><font face="Courier New">view_as<polygon_90_set_concept>(polygon_set_object)<br />
view_as<polygon_45_set_concept>(polygon_set_object)</font></p>
-<p>The return value of <font face="Courier New">view_as<>()</font> can be passed
-into any interface that expects an object of the conceptual type specified in
-its template parameter. Polygon sets cannot be viewed as single polygons
-or rectangles since it generally cannot be known whether a polygon set contains
-only a single polygon without converting to polygons.</p>
-<h2>Operators</h2>
-<p>The return type of some operators is the <font face="Courier New">polygon_set_view</font>
-operator template type. This type is itself a model of the polygon 90 set
-concept, but furthermore can be used as an argument to the <font face="Courier New">polygon_set_data</font>
-constructor and assignment operator. The operator template exists to
-eliminate temp copies of intermediate results when Boolean operators are chained
-together.</p>
-<p>Operators are declared inside the namespace <font face="Courier New">boost::polygon::operators</font>.</p>
-<table id="table5" border="1" width="100%">
- <tbody><tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- polygon_set_view <b>operator</b>|(const T1& l, const T2& r)</font></td>
- <td>Boolean OR operation (polygon set union). Accepts two objects
- that model polygon_set or one of its refinements. Returns an
- operator template that performs the operation on demand when chained or
- or nested in a library function call such as assign(). Expected n
- log n runtime, worst case quadratic runtime wrt. vertices +
- intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- polygon_set_view <b>operator</b>+(const T1& l, const T2& r)</font></td>
- <td>Same as operator|. The plus sign is also used for OR
- operations in Boolean logic expressions. Expected n log n runtime,
- worst case quadratic runtime wrt. vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- polygon_set_view <b>operator</b>&(const T1& l, const T2& r)</font></td>
- <td>Boolean AND operation (polygon set intersection). Accepts two
- objects that model polygon_set or one of its refinements. Expected
- n log n runtime, worst case quadratic runtime wrt. vertices +
- intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- polygon_set_view <b>operator</b>*(const T1& l, const T2& r)</font></td>
- <td>Same as operator&. The multiplication symbol is also used for
- AND operations in Boolean logic expressions. Expected n log n
- runtime, worst case quadratic runtime wrt. vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- polygon_set_view <b>operator</b>^(const T1& l, const T2& r)</font></td>
- <td>Boolean XOR operation (polygon set disjoint-union). Accepts
- two objects that model polygon_set or one of its refinements.
- Expected n log n runtime, worst case quadratic runtime wrt. vertices +
- intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- polygon_set_view <b>operator</b>-(const T1& l, const T2& r)</font></td>
- <td>Boolean SUBTRACT operation (polygon set difference). Accepts
- two objects that model polygon_set or one of its refinements.
- Expected n log n runtime, worst case quadratic runtime wrt. vertices +
- intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- T1& <b>operator</b>|=(const T1& l, const T2& r)</font></td>
- <td>Same as operator|, but with self assignment, left operand must model
- polygon_set and not one of it's refinements. Expected n log n
- runtime, worst case quadratic runtime wrt. vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- T1& <b>operator</b>+=(T1& l, const T2& r)</font></td>
- <td>Same as operator+, but with self assignment, left operand must model
- polygon_set and not one of it's refinements. Expected n log n
- runtime, worst case quadratic runtime wrt. vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- T1& <b>operator</b>&=(const T1& l, const T2& r)</font></td>
- <td>Same as operator&, but with self assignment, left operand must model
- polygon_set and not one of it's refinements. Expected n log n
- runtime, worst case quadratic runtime wrt. vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- T1& <b>operator</b>*=(T1& l, const T2& r)</font></td>
- <td>Same as operator*, but with self assignment, left operand must model
- polygon_set and not one of it's refinements. Expected n log n
- runtime, worst case quadratic runtime wrt. vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- T1& <b>operator</b>^=(const T1& l, const T2& r)</font></td>
- <td>Same as operator^, but with self assignment, left operand must model
- polygon_set and not one of it's refinements. Expected n log n
- runtime, worst case quadratic runtime wrt. vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- T1& <b>operator</b>-=(T1& l, const T2& r)</font></td>
- <td>Same as operator-, but with self assignment, left operand must model
- polygon_set and not one of it's refinements. Expected n log n
- runtime, worst case quadratic runtime wrt. vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1><br />
- T1 <b>operator</b>+(const T1&, coordinate_type bloating)</font></td>
- <td>Performs resize operation, inflating by bloating ammount. If
- negative the result is a shrink instead of bloat. Note: returns
- result by value. Expected n log n runtime, worst case quadratic
- runtime wrt. vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- T1 <b>operator</b>-(const T1&, coordinate_type shrinking)</font></td>
- <td>Performs resize operation, deflating by bloating ammount. If
- negative the result is a bloat instead of shrink. Note: returns
- result by value. Expected n log n runtime, worst case quadratic
- runtime wrt. vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- T1& <b>operator</b>+=(const T1&, coordinate_type bloating)</font></td>
- <td>Performs resize operation, inflating by bloating ammount. If
- negative the result is a shrink instead of bloat. Returns
- reference to modified argument. Expected n log n runtime, worst
- case quadratic runtime wrt. vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- T1& <b>operator</b>-=(const T1&, coordinate_type shrinking)</font></td>
- <td>Performs resize operation, deflating by bloating ammount. If
- negative the result is a bloat instead of shrink. Returns
- reference to modified argument. Expected n log n runtime, worst
- case quadratic runtime wrt. vertices + intersections.</td>
- </tr>
- </tbody></table>
-<h2>Functions</h2>
-<table id="table6" border="1" width="100%">
- <tbody><tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- T1& <b>assign</b>(T1& lvalue, const T2& rvalue)</font></td>
- <td>Eliminates overlaps in geometry and copies from an object that
- models polygon_set or any of its refinements into an object that
- models polygon_set. Expected n log n runtime, worst case quadratic
- runtime wrt. vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- bool <b>equivalence</b>(const T1& lvalue, const T2& rvalue) </font></td>
- <td>Returns true if an object that models polygon_set or one of its
- refinements covers the exact same geometric regions as another object
- that models polygon_set or one of its refinements. For example:
- two of polygon objects. Expected n log n runtime, worst case
- quadratic runtime wrt. vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename
- output_container_type, typename T><br />
- void <b>get_trapezoids</b>(output_container_type& output, <br />
-
- const T& polygon_set)</font></td>
- <td>Output container is expected to be a standard container.
- Slices geometry of an object that models polygon_set or one of its
- refinements into non overlapping trapezoids along a vertical slicing
- orientation and appends them to the
- output, which must have a value type that models polygon or polygon_with_holes.
- Expected n log n runtime, worst case quadratic runtime wrt. vertices +
- intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename
- output_container_type, typename T><br />
- void <b>get_trapezoids</b>(output_container_type& output, <br />
-
- const T& polygon_set,<br />
+ <p>The return value of <font face="Courier New">view_as<>()</font>
+can be passed into any interface that expects an object of the
+conceptual type specified in its template parameter. Polygon sets
+cannot be viewed as single polygons or rectangles since it generally
+cannot be known whether a polygon set contains only a single polygon
+without converting to polygons.</p>
+ <h2>Operators</h2>
+ <p>The return type of some operators is the <font
+ face="Courier New">polygon_set_view</font> operator template
+type. This type is itself a model of the polygon 90 set concept,
+but furthermore can be used as an argument to the <font
+ face="Courier New">polygon_set_data</font> constructor and assignment
+operator. The operator template exists to eliminate temp copies
+of intermediate results when Boolean operators are chained together.</p>
+ <p>Operators are declared inside the namespace <font
+ face="Courier New">boost::polygon::operators</font>.</p>
+ <table id="table5" border="1" width="100%">
+ <tbody>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+polygon_set_view <b>operator</b>|(const T1& l, const T2& r)</font></td>
+ <td>Boolean OR operation (polygon set union). Accepts
+two objects that model polygon_set or one of its refinements.
+Returns an operator template that performs the operation on demand when
+chained or or nested in a library function call such as assign().
+Expected n log n runtime, worst case quadratic runtime wrt. vertices +
+intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+polygon_set_view <b>operator</b>+(const T1& l, const T2& r)</font></td>
+ <td>Same as operator|. The plus sign is also used for
+OR operations in Boolean logic expressions. Expected n log n
+runtime, worst case quadratic runtime wrt. vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+polygon_set_view <b>operator</b>&(const T1& l, const T2& r)</font></td>
+ <td>Boolean AND operation (polygon set intersection).
+Accepts two objects that model polygon_set or one of its
+refinements. Expected n log n runtime, worst case quadratic
+runtime wrt. vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+polygon_set_view <b>operator</b>*(const T1& l, const T2& r)</font></td>
+ <td>Same as operator&. The multiplication symbol
+is also used for AND operations in Boolean logic expressions.
+Expected n log n runtime, worst case quadratic runtime wrt. vertices +
+intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+polygon_set_view <b>operator</b>^(const T1& l, const T2& r)</font></td>
+ <td>Boolean XOR operation (polygon set
+disjoint-union). Accepts two objects that model polygon_set or
+one of its refinements. Expected n log n runtime, worst case
+quadratic runtime wrt. vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+polygon_set_view <b>operator</b>-(const T1& l, const T2& r)</font></td>
+ <td>Boolean SUBTRACT operation (polygon set
+difference). Accepts two objects that model polygon_set or one of
+its refinements. Expected n log n runtime, worst case quadratic
+runtime wrt. vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+T1& <b>operator</b>|=(const T1& l, const T2& r)</font></td>
+ <td>Same as operator|, but with self assignment, left
+operand must model polygon_set and not one of it's refinements.
+Expected n log n runtime, worst case quadratic runtime wrt. vertices +
+intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+T1& <b>operator</b>+=(T1& l, const T2& r)</font></td>
+ <td>Same as operator+, but with self assignment, left
+operand must model polygon_set and not one of it's refinements.
+Expected n log n runtime, worst case quadratic runtime wrt. vertices +
+intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+T1& <b>operator</b>&=(const T1& l, const T2& r)</font></td>
+ <td>Same as operator&, but with self assignment, left
+operand must model polygon_set and not one of it's refinements.
+Expected n log n runtime, worst case quadratic runtime wrt. vertices +
+intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+T1& <b>operator</b>*=(T1& l, const T2& r)</font></td>
+ <td>Same as operator*, but with self assignment, left
+operand must model polygon_set and not one of it's refinements.
+Expected n log n runtime, worst case quadratic runtime wrt. vertices +
+intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+T1& <b>operator</b>^=(const T1& l, const T2& r)</font></td>
+ <td>Same as operator^, but with self assignment, left
+operand must model polygon_set and not one of it's refinements.
+Expected n log n runtime, worst case quadratic runtime wrt. vertices +
+intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+T1& <b>operator</b>-=(T1& l, const T2& r)</font></td>
+ <td>Same as operator-, but with self assignment, left
+operand must model polygon_set and not one of it's refinements.
+Expected n log n runtime, worst case quadratic runtime wrt. vertices +
+intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1><br />
+T1 <b>operator</b>+(const T1&, coordinate_type bloating)</font></td>
+ <td>Performs resize operation, inflating by bloating
+ammount. If negative the result is a shrink instead of
+bloat. Note: returns result by value. Expected n log n
+runtime, worst case quadratic runtime wrt. vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+T1 <b>operator</b>-(const T1&, coordinate_type shrinking)</font></td>
+ <td>Performs resize operation, deflating by bloating
+ammount. If negative the result is a bloat instead of
+shrink. Note: returns result by value. Expected n log n
+runtime, worst case quadratic runtime wrt. vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+T1& <b>operator</b>+=(const T1&, coordinate_type bloating)</font></td>
+ <td>Performs resize operation, inflating by bloating
+ammount. If negative the result is a shrink instead of
+bloat. Returns reference to modified argument. Expected n
+log n runtime, worst case quadratic runtime wrt. vertices +
+intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+T1& <b>operator</b>-=(const T1&, coordinate_type shrinking)</font></td>
+ <td>Performs resize operation, deflating by bloating
+ammount. If negative the result is a bloat instead of
+shrink. Returns reference to modified argument. Expected n
+log n runtime, worst case quadratic runtime wrt. vertices +
+intersections.</td>
+ </tr>
+ </tbody>
+ </table>
+ <h2>Functions</h2>
+ <table id="table6" border="1" width="100%">
+ <tbody>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+T1& <b>assign</b>(T1& lvalue, const T2& rvalue)</font></td>
+ <td>Eliminates overlaps in geometry and copies from an
+object that models polygon_set or any of its refinements into an object
+that models polygon_set. Expected n log n runtime, worst case
+quadratic runtime wrt. vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+bool <b>equivalence</b>(const T1& lvalue, const T2& rvalue) </font></td>
+ <td>Returns true if an object that models polygon_set or
+one of its refinements covers the exact same geometric regions as
+another object that models polygon_set or one of its refinements.
+For example: two of polygon objects. Expected n log n runtime,
+worst case quadratic runtime wrt. vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename output_container_type, typename T><br />
+void <b>get_trapezoids</b>(output_container_type& output, <br />
+
+const T& polygon_set)</font></td>
+ <td>Output container is expected to be a standard
+container. Slices geometry of an object that models polygon_set
+or one of its refinements into non overlapping trapezoids along a
+vertical slicing orientation and appends them to the output, which must
+have a value type that models polygon or polygon_with_holes.
+Expected n log n runtime, worst case quadratic runtime wrt. vertices +
+intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename output_container_type, typename T><br />
+void <b>get_trapezoids</b>(output_container_type& output, <br />
+
+const T& polygon_set,<br />
orientation_2d orient)</font></td>
- <td>Output container is expected to be a standard container.
- Slices geometry of an object that models polygon_set or one of its
- refinements into non overlapping trapezoids along a the specified slicing
- orientation and appends them to the
- output, which must have a value type that models polygon or polygon_with_holes.
- Expected n log n runtime, worst case quadratic runtime wrt. vertices +
- intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename
- polygon_set_type><br />
- void <b>clear</b>(polygon_set_type& polygon_set)</font></td>
- <td>Makes the object empty of geometry.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename
- polygon_set_type><br />
- bool <b>empty</b>(const polygon_set_type& polygon_set)</font></td>
- <td>Checks whether the object is empty of geometry. Polygons that
- are completely covered by holes will result in empty returning true.
- Expected n log n runtime, worst case quadratic runtime wrt. vertices +
- intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T, typename
- rectangle_type><br />
- bool <b>extents</b>(rectangle_type& extents_rectangle, <br />
- const
- T& polygon_set)</font></td>
- <td>Computes bounding box of an object that models polygon_set and
- stores it in an object that models rectangle. If the polygon set
- is empty returns false. If there are holes outside of shells they
- do not contribute to the extents of the polygon set. Expected n
- log n runtime, worst case quadratic runtime wrt. vertices +
- intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- area_type <b>area</b>(const T& polygon_set)</font></td>
- <td>Computes the area covered by geometry in an object that models
- polygon_set. Expected n log n runtime, worst case quadratic
- runtime wrt. vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- T& <b>bloat</b>(T& polygon_set, unsigned_area_type bloating)</font></td>
- <td>Same as getting all the polygons, bloating them and putting them
- back. Expected n log n runtime, worst case quadratic runtime wrt.
- vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- T& <b>shrink</b>(T& polygon_set, unsigned_area_type shrinking)</font></td>
- <td>Same as getting all the polygons, shrinking them and overwriting
- the polygon set with the resulting regions. Expected n log n
- runtime, worst case quadratic runtime wrt. vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T, typename
- coord_type><br />
- T& <b>resize</b>(T& polygon_set, coord_type resizing,<br />
-
- bool corner_fill_arc = false, <br />
- unsigned int num_circle_segments = 0)</font></td>
- <td>Same as bloat if resizing is positive, same as shrink if resizing is
- negative. Original topology at acute angle vertices is preserved
- by default, segmented circular arcs are inserted if corner_fill_arc is
- true. num_circle_segments specifies number of segments to
- introduce on a full circle when filling acute angle corners with
- circular arcs. Expected n log n runtime, worst case quadratic
- runtime wrt. vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
+ <td>Output container is expected to be a standard
+container. Slices geometry of an object that models polygon_set
+or one of its refinements into non overlapping trapezoids along a the
+specified slicing orientation and appends them to the output, which
+must have a value type that models polygon or polygon_with_holes.
+Expected n log n runtime, worst case quadratic runtime wrt. vertices +
+intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename polygon_set_type><br />
+void <b>clear</b>(polygon_set_type& polygon_set)</font></td>
+ <td>Makes the object empty of geometry.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename polygon_set_type><br />
+bool <b>empty</b>(const polygon_set_type& polygon_set)</font></td>
+ <td>Checks whether the object is empty of geometry.
+Polygons that are completely covered by holes will result in empty
+returning true. Expected n log n runtime, worst case quadratic
+runtime wrt. vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename rectangle_type><br />
+bool <b>extents</b>(rectangle_type& extents_rectangle, <br />
+
+const T& polygon_set)</font></td>
+ <td>Computes bounding box of an object that models
+polygon_set and stores it in an object that models rectangle. If
+the polygon set is empty returns false. If there are holes
+outside of shells they do not contribute to the extents of the polygon
+set. Expected n log n runtime, worst case quadratic runtime wrt.
+vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+area_type <b>area</b>(const T& polygon_set)</font></td>
+ <td>Computes the area covered by geometry in an object that
+models polygon_set. Expected n log n runtime, worst case
+quadratic runtime wrt. vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+T& <b>bloat</b>(T& polygon_set, unsigned_area_type bloating)</font></td>
+ <td>Same as getting all the polygons, bloating them and
+putting them back. Expected n log n runtime, worst case quadratic
+runtime wrt. vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+T& <b>shrink</b>(T& polygon_set, unsigned_area_type shrinking)</font></td>
+ <td>Same as getting all the polygons, shrinking them and
+overwriting the polygon set with the resulting regions. Expected
+n log n runtime, worst case quadratic runtime wrt. vertices +
+intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename coord_type><br />
+T& <b>resize</b>(T& polygon_set, coord_type resizing,<br />
+ bool
+corner_fill_arc = false, <br />
+ unsigned int
+num_circle_segments = 0)</font></td>
+ <td>Same as bloat if resizing is positive, same as shrink
+if resizing is negative. Original topology at acute angle
+vertices is preserved by default, segmented circular arcs are inserted
+if corner_fill_arc is true. num_circle_segments specifies number
+of segments to introduce on a full circle when filling acute angle
+corners with circular arcs. Expected n log n runtime, worst case
+quadratic runtime wrt. vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
T& <b>scale_up</b>(T& polygon_set, unsigned_area_type factor)</font></td>
- <td>Scales geometry up by unsigned factor. Expected n log n
- runtime, worst case quadratic runtime wrt. vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
+ <td>Scales geometry up by unsigned factor. Expected n
+log n runtime, worst case quadratic runtime wrt. vertices +
+intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
T& <b>scale_down</b>(T& polygon_set, unsigned_area_type factor)</font></td>
- <td>Scales geometry down by unsigned factor. Expected n log n
- runtime, worst case quadratic runtime wrt. vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T, typename transformation_type><br />
+ <td>Scales geometry down by unsigned factor. Expected
+n log n runtime, worst case quadratic runtime wrt. vertices +
+intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename transformation_type><br />
T& <b>transform</b>(T& polygon_set,<br />
- const
-transformation_type& transformation)</font></td>
- <td>Applies transformation.transform() on all vertices. Expected n
- log n runtime, worst case quadratic runtime wrt. vertices +
- intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
+
+const transformation_type& transformation)</font></td>
+ <td>Applies transformation.transform() on all
+vertices. Expected n log n runtime, worst case quadratic runtime
+wrt. vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
T& <b>keep</b>(T& polygon_set, <br />
unsigned_area_type min_area,<br />
unsigned_area_type max_area,<br />
unsigned_area_type min_width,<br />
unsigned_area_type max_width,<br />
- unsigned_area_type min_height,<br />
- unsigned_area_type max_height)</font></td>
- <td>Retains only regions that satisfy the min/max criteria in the
- argument list. Note: useful for visualization to cull too small
- polygons. Expected n log n runtime, worst case quadratic runtime
- wrt. vertices + intersections.</td>
- </tr>
- </tbody></table>
- <h1>Polygon Set Data Object</h1>
-
-<p>
-</p><p>The polygon set data type encapsulates the internal data format that
-serves as the input to the sweep-line algorithm that implements polygon-clipping
-Boolean operations. It also internally keeps track of whether that data
-has been sorted or scanned and maintains the invariant that when its flags
-indicate that the data is sorted or scanned the data has not been changed to
-violate that assumption. Using the Polygon Set Data type directly can
-be more efficient than using lists and vectors of polygons in the functions
-above because of the invariants it can enforce which provide the opportunity to
-maintain the data is sorted form rather than going all the way out to polygons
-then resorting those vertices for a subsequent operation.</p>
-<p>The declaration of Polygon Set Data is the following:</p>
-<p><font face="Courier New">template <typename T><br />
+ unsigned_area_type
+min_height,<br />
+ unsigned_area_type
+max_height)</font></td>
+ <td>Retains only regions that satisfy the min/max criteria
+in the argument list. Note: useful for visualization to cull too
+small polygons. Expected n log n runtime, worst case quadratic
+runtime wrt. vertices + intersections.</td>
+ </tr>
+ </tbody>
+ </table>
+ <h1>Polygon Set Data Object</h1>
+ <p> </p>
+ <p>The polygon set data type encapsulates the internal data
+format that serves as the input to the sweep-line algorithm that
+implements polygon-clipping Boolean operations. It also
+internally keeps track of whether that data has been sorted or scanned
+and maintains the invariant that when its flags indicate that the data
+is sorted or scanned the data has not been changed to violate that
+assumption. Using the Polygon Set Data type directly can be more
+efficient than using lists and vectors of polygons in the functions
+above because of the invariants it can enforce which provide the
+opportunity to maintain the data is sorted form rather than going all
+the way out to polygons then resorting those vertices for a subsequent
+operation.</p>
+ <p>The declaration of Polygon Set Data is the following:</p>
+ <p><font face="Courier New">template <typename T><br />
class polygon_set_data;</font></p>
-<p>The class is parameterized on the coordinate data type. Algorithms that
-benefit from knowledge of the invariants enforced by the class are implemented
-as member functions to provide them access to information about those
-invariants. </p>
-<p>Example code polygon_set_usage.cpp
-demonstrates using
- the library provided polygon set data types and functions</p>
-<h2>Member Functions</h2>
-<table id="table7" border="1" width="100%">
- <tbody><tr>
- <td width="586"><font face="Courier New"><b>polygon_set_data</b>()</font></td>
- <td>Default constructor. </td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename iT><br />
- <b>polygon_set_data</b>(iT input_begin, iT
- input_end)</font></td>
- <td>Construct with scanning orientation from an iterator range of
- insertable objects.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">
- <b>polygon_set_data</b>(const polygon_set_data& that)</font></td>
- <td>Copy construct.</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">template <typename l, typename r, typename op><br />
-<b>polygon_set_data</b>(const polygon_set_view<l,r,op>&
-t)</font></td>
- <td>Copy construct from a Boolean operator template.</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">polygon_set_data& <br /><b>operator=</b>(const polygon_set_data& that)</font></td>
- <td>Assignment from another polygon set, may change scanning
- orientation.</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">template <typename l, typename r, typename op><br />
-polygon_set_data& <br /><b>operator=</b>(const polygon_set_view<l, r,
+ <p>The class is parameterized on the coordinate data type.
+Algorithms that benefit from knowledge of the invariants enforced by
+the class are implemented as member functions to provide them access to
+information about those invariants. </p>
+ <p>Example code polygon_set_usage.cpp
+demonstrates using the library provided polygon set data types and
+functions</p>
+ <h2>Member Functions</h2>
+ <table id="table7" border="1" width="100%">
+ <tbody>
+ <tr>
+ <td width="586"><font face="Courier New"><b>polygon_set_data</b>()</font></td>
+ <td>Default constructor. </td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename iT><br />
+ <b>polygon_set_data</b>(iT input_begin, iT input_end)</font></td>
+ <td>Construct with scanning orientation from an iterator
+range of insertable objects.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New"> <b>polygon_set_data</b>(const
+polygon_set_data& that)</font></td>
+ <td>Copy construct.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename l, typename r, typename op><br />
+ <b>polygon_set_data</b>(const
+polygon_set_view<l,r,op>& t)</font></td>
+ <td>Copy construct from a Boolean operator template.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">polygon_set_data&
+ <br />
+ <b>operator=</b>(const polygon_set_data& that)</font></td>
+ <td>Assignment from another polygon set, may change
+scanning orientation.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename l, typename r, typename op><br />
+polygon_set_data& <br />
+ <b>operator=</b>(const polygon_set_view<l, r,
op>& that)</font></td>
- <td>Assignment from a Boolean operator template.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename geometry_object><br />
+ <td>Assignment from a Boolean operator template.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename geometry_object><br />
polygon_set_data& <b>operator=</b>(const geometry_object& geo)</font></td>
- <td>Assignment from an insertable object.</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">
+ <td>Assignment from an insertable object.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">
template <typename iT><br />
void <b>insert</b>(iT input_begin, iT input_end)</font></td>
- <td>Insert objects of an iterator range. Linear wrt vertices
- inserted.</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">
+ <td>Insert objects of an iterator range. Linear wrt
+vertices inserted.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">
void <b>insert</b>(const polygon_set_data& polygon_set)</font></td>
- <td>Insert a polygon set. Linear wrt vertices inserted.</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">
+ <td>Insert a polygon set. Linear wrt vertices
+inserted.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">
template <typename geometry_type><br />
-void <b>insert</b>(const geometry_type& geometry_object, <br /> bool is_hole
-= false)</font></td>
- <td>Insert a geometry object, if is_hole is true then the inserted
- region is subtractive rather than additive. Linear wrt vertices
- inserted.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">
-template <typename output_container><br />
+void <b>insert</b>(const geometry_type& geometry_object, <br />
+ bool
+is_hole = false)</font></td>
+ <td>Insert a geometry object, if is_hole is true then the
+inserted region is subtractive rather than additive. Linear wrt
+vertices inserted.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename output_container><br />
void <b>get</b>(output_container& output) const</font></td>
- <td>Expects a standard container of polygons objects. Will scan
- and eliminate overlaps. Converts polygon set geometry to objects
- of the polygon type and appends them to the container. Polygons
- will be output with counterclockwise winding, hole polygons will be
- output with clockwise winding. The last vertex of an output
- polygon is the duplicate of the first, and the number of points is equal
- to the number of edges plus 1. If required by the output data
- type, polygons will have holes fractured out to the outer boundary along
- the positive y direction and off grid intersections on the outer
- boundary introduced by this fracture will be truncated downward.
- Expected n log n runtime, worst case quadratic runtime wrt. vertices +
- intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">
-template <typename output_container><br />
+ <td>Expects a standard container of polygons objects.
+Will scan and eliminate overlaps. Converts polygon set geometry
+to objects of the polygon type and appends them to the container.
+Polygons will be output with counterclockwise winding, hole polygons
+will be output with clockwise winding. The last vertex of an
+output polygon is the duplicate of the first, and the number of points
+is equal to the number of edges plus 1. If required by the output
+data type, polygons will have holes fractured out to the outer boundary
+along the positive y direction and off grid intersections on the outer
+boundary introduced by this fracture will be truncated downward.
+Expected n log n runtime, worst case quadratic runtime wrt. vertices +
+intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename output_container><br />
void <b>get_trapezoids</b>(output_container& output) const</font></td>
- <td>Expects a standard container of polygon objects. Will scan
- and eliminate overlaps. Slices polygon set geometry to trapezoids
- vertically and appends them to the container. Expected n log n
- runtime, worst case quadratic runtime wrt. vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">
+ <td>Expects a standard container of polygon objects.
+Will scan and eliminate overlaps. Slices polygon set geometry to
+trapezoids vertically and appends them to the container. Expected
+n log n runtime, worst case quadratic runtime wrt. vertices +
+intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">
template <typename output_container><br />
-void <b>get_trapezoids</b>(output_container& output, <br /> orientation_2d
-slicing_orientation) const </font>
- </td>
- <td>Expects a standard container of polygon objects. Will scan
- and eliminate overlaps. Slices polygon set geometry to trapezoids
- along the given orientation and appends them to the container.
- Expected n log n runtime, worst case quadratic runtime wrt. vertices +
- intersections.</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">
+void <b>get_trapezoids</b>(output_container& output, <br />
+ orientation_2d slicing_orientation) const </font> </td>
+ <td>Expects a standard container of polygon objects.
+Will scan and eliminate overlaps. Slices polygon set geometry to
+trapezoids along the given orientation and appends them to the
+container. Expected n log n runtime, worst case quadratic runtime
+wrt. vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">
bool <b>operator==</b>(const polygon_set_data& p) const</font></td>
- <td>Once scanned the data representation of geometry within a polygon
- set is in a mathematically canonical form. Comparison between two
- sets is therefore a linear time operation once they are in the scanned
- state. Will scan and eliminate overlaps in both polygon sets.
- Expected n log n runtime, worst case quadratic runtime wrt. vertices +
- intersections. </td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">
-bool <b>operator!=</b>(const polygon_set_data& p) const</font></td>
- <td>Inverse logic of equivalence operator.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">void <b>clear</b>()</font></td>
- <td>Make the polygon set empty. Note: does not de-allocate memory.
- Use shrink to fit idiom and assign default constructed polygon set to
- de-allocate.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">bool <b>empty</b>() const </font>
- </td>
- <td>Check whether the polygon set contains no geometry. Will scan
- and eliminate overlaps because subtractive regions might make the
- polygon set empty. Expected n log n runtime, worst case quadratic
- runtime wrt. vertices + intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">void <b>clean</b>() const</font></td>
- <td>Scan and eliminate overlaps. Expected n log n runtime, worst
- case quadratic runtime wrt. vertices + intersections the first time,
- constant time subsequently.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">
-template <typename input_iterator_type><br />
-void <b>set</b>(input_iterator_type input_begin, <br /> input_iterator_type input_end) </font>
- </td>
- <td>Overwrite geometry in polygon set with insertable objects in the
- iterator range. </td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">
-template <typename rectangle_type><br />
+ <td>Once scanned the data representation of geometry within
+a polygon set is in a mathematically canonical form. Comparison
+between two sets is therefore a linear time operation once they are in
+the scanned state. Will scan and eliminate overlaps in both polygon
+sets. Expected n log n runtime, worst case quadratic runtime wrt.
+vertices + intersections. </td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">bool <b>operator!=</b>(const
+polygon_set_data& p) const</font></td>
+ <td>Inverse logic of equivalence operator.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">void <b>clear</b>()</font></td>
+ <td>Make the polygon set empty. Note: does not
+de-allocate memory. Use shrink to fit idiom and assign default
+constructed polygon set to de-allocate.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">bool <b>empty</b>()
+const </font> </td>
+ <td>Check whether the polygon set contains no
+geometry. Will scan and eliminate overlaps because subtractive
+regions might make the polygon set empty. Expected n log n
+runtime, worst case quadratic runtime wrt. vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">void <b>clean</b>()
+const</font></td>
+ <td>Scan and eliminate overlaps. Expected n log n
+runtime, worst case quadratic runtime wrt. vertices + intersections the
+first time, constant time subsequently.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename input_iterator_type><br />
+void <b>set</b>(input_iterator_type input_begin, <br />
+ input_iterator_type
+input_end) </font> </td>
+ <td>Overwrite geometry in polygon set with insertable
+objects in the iterator range. </td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename rectangle_type><br />
bool <b>extents</b>(rectangle_type& extents_rectangle) const</font></td>
- <td>Given an object that models rectangle, scans and eliminates overlaps
- in the polygon set because subtractive regions may alter its extents
- then computes the bounding box and assigns it to extents_rectangle.
- Expected n log n runtime, worst case quadratic runtime wrt. vertices +
- intersections the first time, linear subsequently.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">
+ <td>Given an object that models rectangle, scans and
+eliminates overlaps in the polygon set because subtractive regions may
+alter its extents then computes the bounding box and assigns it to
+extents_rectangle. Expected n log n runtime, worst case quadratic
+runtime wrt. vertices + intersections the first time, linear
+subsequently.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">polygon_set_data&<br />
+ <b>resize</b>(coord_type resizing,<br />
+ bool corner_fill_arc = false, <br />
+ unsigned int num_circle_segments =
+0)&