|
Boost-Commit : |
Subject: [Boost-commit] svn:boost r83804 - trunk/libs/polygon/doc
From: sydorchuk.andriy_at_[hidden]
Date: 2013-04-07 19:23:50
Author: asydorchuk
Date: 2013-04-07 19:23:46 EDT (Sun, 07 Apr 2013)
New Revision: 83804
URL: http://svn.boost.org/trac/boost/changeset/83804
Log:
Polygon: Updating Voronoi documentation. Removing documentation for Voronoi predicates and robust fpt, as description is too general.
Removed:
trunk/libs/polygon/doc/voronoi_predicates.htm
trunk/libs/polygon/doc/voronoi_robust_fpt.htm
Text files modified:
trunk/libs/polygon/doc/analysis.htm | 296 +++---
trunk/libs/polygon/doc/gtl_connectivity_extraction.htm | 308 +++---
trunk/libs/polygon/doc/gtl_connectivity_extraction_45.htm | 308 +++---
trunk/libs/polygon/doc/gtl_connectivity_extraction_90.htm | 308 +++---
trunk/libs/polygon/doc/gtl_coordinate_concept.htm | 301 +++---
trunk/libs/polygon/doc/gtl_design_overview.htm | 398 ++++----
trunk/libs/polygon/doc/gtl_interval_concept.htm | 1076 ++++++++++++-----------
trunk/libs/polygon/doc/gtl_isotropy.htm | 1061 ++++++++++++-----------
trunk/libs/polygon/doc/gtl_point_concept.htm | 886 +++++++++++--------
trunk/libs/polygon/doc/gtl_polygon_45_concept.htm | 738 ++++++++-------
trunk/libs/polygon/doc/gtl_polygon_45_set_concept.htm | 1522 +++++++++++++++++----------------
trunk/libs/polygon/doc/gtl_polygon_45_with_holes_concept.htm | 820 +++++++++--------
trunk/libs/polygon/doc/gtl_polygon_90_concept.htm | 824 +++++++++--------
trunk/libs/polygon/doc/gtl_polygon_90_set_concept.htm | 1795 +++++++++++++++++++++------------------
trunk/libs/polygon/doc/gtl_polygon_90_with_holes_concept.htm | 924 ++++++++++---------
trunk/libs/polygon/doc/gtl_polygon_concept.htm | 741 ++++++++-------
trunk/libs/polygon/doc/gtl_polygon_set_concept.htm | 1324 +++++++++++++++--------------
trunk/libs/polygon/doc/gtl_polygon_with_holes_concept.htm | 817 +++++++++--------
trunk/libs/polygon/doc/gtl_property_merge.htm | 315 +++---
trunk/libs/polygon/doc/gtl_property_merge_45.htm | 314 +++---
trunk/libs/polygon/doc/gtl_property_merge_90.htm | 314 +++---
trunk/libs/polygon/doc/gtl_rectangle_concept.htm | 1548 ++++++++++++++++++----------------
trunk/libs/polygon/doc/gtl_segment_concept.htm | 735 ++++++++++-----
trunk/libs/polygon/doc/index.htm | 534 +++++-----
trunk/libs/polygon/doc/voronoi_benchmark.htm | 296 +++--
trunk/libs/polygon/doc/voronoi_builder.htm | 4
trunk/libs/polygon/doc/voronoi_diagram.htm | 2
trunk/libs/polygon/doc/voronoi_main.htm | 8
28 files changed, 9928 insertions(+), 8589 deletions(-)
Modified: trunk/libs/polygon/doc/analysis.htm
==============================================================================
--- trunk/libs/polygon/doc/analysis.htm (original)
+++ trunk/libs/polygon/doc/analysis.htm 2013-04-07 19:23:46 EDT (Sun, 07 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: trunk/libs/polygon/doc/gtl_connectivity_extraction.htm
==============================================================================
--- trunk/libs/polygon/doc/gtl_connectivity_extraction.htm (original)
+++ trunk/libs/polygon/doc/gtl_connectivity_extraction.htm 2013-04-07 19:23:46 EDT (Sun, 07 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: trunk/libs/polygon/doc/gtl_connectivity_extraction_45.htm
==============================================================================
--- trunk/libs/polygon/doc/gtl_connectivity_extraction_45.htm (original)
+++ trunk/libs/polygon/doc/gtl_connectivity_extraction_45.htm 2013-04-07 19:23:46 EDT (Sun, 07 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: trunk/libs/polygon/doc/gtl_connectivity_extraction_90.htm
==============================================================================
--- trunk/libs/polygon/doc/gtl_connectivity_extraction_90.htm (original)
+++ trunk/libs/polygon/doc/gtl_connectivity_extraction_90.htm 2013-04-07 19:23:46 EDT (Sun, 07 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: trunk/libs/polygon/doc/gtl_coordinate_concept.htm
==============================================================================
--- trunk/libs/polygon/doc/gtl_coordinate_concept.htm (original)
+++ trunk/libs/polygon/doc/gtl_coordinate_concept.htm 2013-04-07 19:23:46 EDT (Sun, 07 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: trunk/libs/polygon/doc/gtl_design_overview.htm
==============================================================================
--- trunk/libs/polygon/doc/gtl_design_overview.htm (original)
+++ trunk/libs/polygon/doc/gtl_design_overview.htm 2013-04-07 19:23:46 EDT (Sun, 07 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: trunk/libs/polygon/doc/gtl_interval_concept.htm
==============================================================================
--- trunk/libs/polygon/doc/gtl_interval_concept.htm (original)
+++ trunk/libs/polygon/doc/gtl_interval_concept.htm 2013-04-07 19:23:46 EDT (Sun, 07 Apr 2013)
@@ -1,558 +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><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 </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>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: trunk/libs/polygon/doc/gtl_isotropy.htm
==============================================================================
--- trunk/libs/polygon/doc/gtl_isotropy.htm (original)
+++ trunk/libs/polygon/doc/gtl_isotropy.htm 2013-04-07 19:23:46 EDT (Sun, 07 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: trunk/libs/polygon/doc/gtl_point_concept.htm
==============================================================================
--- trunk/libs/polygon/doc/gtl_point_concept.htm (original)
+++ trunk/libs/polygon/doc/gtl_point_concept.htm 2013-04-07 19:23:46 EDT (Sun, 07 Apr 2013)
@@ -1,415 +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 style="font-family: Courier New,Courier,monospace;">
-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 />
-
- 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 />
+ 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,<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 />
+ 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: trunk/libs/polygon/doc/gtl_polygon_45_concept.htm
==============================================================================
--- trunk/libs/polygon/doc/gtl_polygon_45_concept.htm (original)
+++ trunk/libs/polygon/doc/gtl_polygon_45_concept.htm 2013-04-07 19:23:46 EDT (Sun, 07 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: trunk/libs/polygon/doc/gtl_polygon_45_set_concept.htm
==============================================================================
--- trunk/libs/polygon/doc/gtl_polygon_45_set_concept.htm (original)
+++ trunk/libs/polygon/doc/gtl_polygon_45_set_concept.htm 2013-04-07 19:23:46 EDT (Sun, 07 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: trunk/libs/polygon/doc/gtl_polygon_45_with_holes_concept.htm
==============================================================================
--- trunk/libs/polygon/doc/gtl_polygon_45_with_holes_concept.htm (original)
+++ trunk/libs/polygon/doc/gtl_polygon_45_with_holes_concept.htm 2013-04-07 19:23:46 EDT (Sun, 07 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: trunk/libs/polygon/doc/gtl_polygon_90_concept.htm
==============================================================================
--- trunk/libs/polygon/doc/gtl_polygon_90_concept.htm (original)
+++ trunk/libs/polygon/doc/gtl_polygon_90_concept.htm 2013-04-07 19:23:46 EDT (Sun, 07 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: trunk/libs/polygon/doc/gtl_polygon_90_set_concept.htm
==============================================================================
--- trunk/libs/polygon/doc/gtl_polygon_90_set_concept.htm (original)
+++ trunk/libs/polygon/doc/gtl_polygon_90_set_concept.htm 2013-04-07 19:23:46 EDT (Sun, 07 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: trunk/libs/polygon/doc/gtl_polygon_90_with_holes_concept.htm
==============================================================================
--- trunk/libs/polygon/doc/gtl_polygon_90_with_holes_concept.htm (original)
+++ trunk/libs/polygon/doc/gtl_polygon_90_with_holes_concept.htm 2013-04-07 19:23:46 EDT (Sun, 07 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: trunk/libs/polygon/doc/gtl_polygon_concept.htm
==============================================================================
--- trunk/libs/polygon/doc/gtl_polygon_concept.htm (original)
+++ trunk/libs/polygon/doc/gtl_polygon_concept.htm 2013-04-07 19:23:46 EDT (Sun, 07 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: trunk/libs/polygon/doc/gtl_polygon_set_concept.htm
==============================================================================
--- trunk/libs/polygon/doc/gtl_polygon_set_concept.htm (original)
+++ trunk/libs/polygon/doc/gtl_polygon_set_concept.htm 2013-04-07 19:23:46 EDT (Sun, 07 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)</font></td>
+ <td>Inflates if resizing is positive, deflates 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. Specifying zero for num_circle_segments
+results in only a single segment being inserted at acute corners.
+Expected n log n runtime, worst case quadratic runtime wrt. vertices +
+intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename transformation_type><br />
+polygon_set_data& <br />
+ <b>transform</b>(const transformation_type&
+transformation) </font> </td>
+ <td>Applies transformation.transform() on vertices stored
+within 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">polygon_set_data&
+ <b>scale_up</b>(unsigned_area_type factor)</font></td>
+ <td>Scales vertices stored within the polygon set up by
+factor. Expected n log n runtime, worst case quadratic runtime
+wrt. vertices + intersections.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">polygon_set_data&
+ <b>scale_down</b>(unsigned_area_type factor)</font> </td>
+ <td>Scales vertices stored within the polygon set down by
+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 scaling_type><br />
polygon_set_data&<br />
-<b>resize</b>(coord_type resizing,<br />
- bool corner_fill_arc = false, <br />
- unsigned int num_circle_segments = 0)</font></td>
- <td>Inflates if resizing is positive, deflates 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. Specifying zero for num_circle_segments results in
- only a single segment being inserted at acute corners. Expected n
- log n runtime, worst case quadratic runtime wrt. vertices +
- intersections.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">
-template <typename transformation_type><br />
-polygon_set_data& <br /><b>transform</b>(const transformation_type& transformation) </font>
- </td>
- <td>Applies transformation.transform() on vertices stored within 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">
-polygon_set_data& <b>scale_up</b>(unsigned_area_type factor)</font></td>
- <td>Scales vertices stored within the polygon set up by factor.
- Expected n log n runtime, worst case quadratic runtime wrt. vertices +
- intersections.</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">polygon_set_data& <b>scale_down</b>(unsigned_area_type
-factor)</font> </td>
- <td>Scales vertices stored within the polygon set down by 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 scaling_type><br />
-polygon_set_data&<br /> <b>scale</b>(const scaling_type&
- f)</font></td>
- <td>Scales vertices stored within the polygon set by applying f.scale().
- Expected n log n runtime, worst case quadratic runtime 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="table8" 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 scaling_type& f)</font></td>
+ <td>Scales vertices stored within the polygon set by
+applying f.scale(). Expected n log n runtime, worst case
+quadratic runtime 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="table8" 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: trunk/libs/polygon/doc/gtl_polygon_with_holes_concept.htm
==============================================================================
--- trunk/libs/polygon/doc/gtl_polygon_with_holes_concept.htm (original)
+++ trunk/libs/polygon/doc/gtl_polygon_with_holes_concept.htm 2013-04-07 19:23:46 EDT (Sun, 07 Apr 2013)
@@ -1,411 +1,462 @@
<!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 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 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><a href="gtl_polygon_45_with_holes_concept.htm">Polygon 45
+With Holes Concept</a></li>
+ <li>Polygon Concept</li>
+ <li>Polygon With Holes Concept</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 With Holes Concept</h1>
-
-<p>
-</p><p>The polygon_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 With Holes Concept</h1>
+ <p> </p>
+ <p>The polygon_with_holes concept tag is <font face="Courier New">
polygon_with_holes_concept</font></p>
-<p>
-To register a user defined type as a model of
-<font face="Times New Roman">polygon_with_holes </font>concept, specialize the
-geometry concept meta-function for that type. In the example below
-CPolygonWithHoles is registered as a model of polygon<font face="Times New Roman">_with_holes </font> concept.</p><p>
-<font face="Courier New">template <><br />
-struct geometry_concept<CPolygonWithHoles> { typedef polygon_with_holes_concept type; };</font></p><p>
-<font face="Times New Roman">The semantic of a polygon_with_holes is a polygon
-that it can provide iterators over holes that are also polygon. A mutable
-polygon_with_holes must also be able to set its geometry based on an interator
-range over polygon 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. Note, these traits are used by all
-polygon with holes concepts.</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_with_holes </font>concept, specialize
+the geometry concept meta-function for that type. In the example
+below CPolygonWithHoles is registered as a model of polygon<font
+ face="Times New Roman">_with_holes </font> concept.</p>
+ <p> <font face="Courier New">template <><br />
+struct geometry_concept<CPolygonWithHoles> { typedef
+polygon_with_holes_concept type; };</font></p>
+ <p> <font face="Times New Roman">The semantic of a
+polygon_with_holes is a polygon that it can provide iterators over
+holes that are also polygon. A mutable polygon_with_holes must
+also be able to set its geometry based on an interator range over
+polygon 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.
+Note, these traits are used by all polygon with holes concepts.</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_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_with_holes_object)</font><br />
-<font face="Courier New">view_as<polygon_90_concept>(polygon_with_holes_object)</font><br />
-<font face="Courier New">view_as<polygon_90_with_holes_concept>(polygon_with_holes_object)</font><br />
-<font face="Courier New">view_as<polygon_45_concept>(polygon_with_holes_object)</font><br />
-<font face="Courier New">view_as<polygon_45_with_holes_concept>(polygon_with_holes_object)</font><br />
-<font face="Courier New">view_as<polygon_concept>(polygon_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_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_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_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_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_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_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_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_with_holes or one
- of its refinements into left object
- that models polygon_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_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_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_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_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_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, 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 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 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 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 .</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_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_with_holes_object)</font><br />
+ <font face="Courier New">view_as<polygon_90_concept>(polygon_with_holes_object)</font><br />
+ <font face="Courier New">view_as<polygon_90_with_holes_concept>(polygon_with_holes_object)</font><br />
+ <font face="Courier New">view_as<polygon_45_concept>(polygon_with_holes_object)</font><br />
+ <font face="Courier New">view_as<polygon_45_with_holes_concept>(polygon_with_holes_object)</font><br />
+ <font face="Courier New">view_as<polygon_concept>(polygon_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_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_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_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_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_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_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_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_with_holes or one of its refinements into left object that
+models polygon_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_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_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_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_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_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, 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 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 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 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 .</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_with_holes.</td>
- </tr>
- </tbody></table>
- <h1>Polygon With Holes Data</h1>
-
-<p>
-</p><p>The library provides a model of polygon with holes concept declared
-<font face="Courier New">
-template<typename T> polygon_with_holes_data </font>where T is the
-coordinate type.</p>
-<p>This data type is used internally when a 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_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_data<T>.</font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New"><b>polygon_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_with_holes_data</b>(const
- polygon_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_with_holes_data& <b>
- <br />operator=</b>(const polygon_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_with_holes_data&<b>
- <br /> operator=</b>(const T2& that) const</font></td>
- <td>Assign from an object that is a model of polygon 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. </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_data or
- polygon_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_with_holes.</td>
+ </tr>
+ </tbody>
+ </table>
+ <h1>Polygon With Holes Data</h1>
+ <p> </p>
+ <p>The library provides a model of polygon with holes concept
+declared
+ <font face="Courier New">template<typename T>
+polygon_with_holes_data </font>where T is the coordinate type.</p>
+ <p>This data type is used internally when a 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_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_data<T>.</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New"><b>polygon_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_with_holes_data</b>(const
+polygon_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_with_holes_data&
+ <b> <br />
+operator=</b>(const polygon_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_with_holes_data&<b> <br />
+operator=</b>(const T2& that) const</font></td>
+ <td>Assign from an object that is a model of polygon 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. </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_data or polygon_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: trunk/libs/polygon/doc/gtl_property_merge.htm
==============================================================================
--- trunk/libs/polygon/doc/gtl_property_merge.htm (original)
+++ trunk/libs/polygon/doc/gtl_property_merge.htm 2013-04-07 19:23:46 EDT (Sun, 07 Apr 2013)
@@ -1,163 +1,186 @@
<!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: Property Merge</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: Property Merge</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>Property Merge</h1>
-
-<p>
-</p><p>The following is the declaration of the property merge algorithm.</p><p>
-<font face="Courier New">template <typename coordinate_type, typename
-property_type><br />
-class property_merge;</font></p><p>The property algorithm computes the n-layer
-map overlay of input polygon sets. Each input geometry is inserted along
-with a property value. The property type can be anything suitable for use
-as an element of a std::set. Multiple geometry objects can be separately
-inserted with the same property value. To store the result of this
-operation a fairly complex container is required. Resulting geometries are
-associated with unique subsets of property values of the input geometry.
-Two suitable containers for storing the result of a property merge operation
-are:</p><p><font face="Courier New">std::map<std::set<property_type>, polygon_set_data<coordinate_type>
-><br />
-std::map<std::vector<property_type>, polygon_set_data<coordinate_type> ></font></p><p>
-Example code property_merge_usage.cpp
- demonstrates using the n-layer map-overlay algorithm on polygon data.</p><h2>Member Functions</h2>
-<table id="table1" border="1" width="100%">
- <tbody><tr>
- <td width="586"><b><font face="Courier New">property_merge</font></b><font face="Courier New">()</font></td>
- <td>Default constructor. </td>
- </tr>
- <tr>
- <td width="586"><b><font face="Courier New">property_merge</font></b><font face="Courier New">(const
- property_merge& that)</font></td>
- <td>Copy construct.</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">void <br /><b>insert</b>(const polygon_set_data<coordinate_type>& ps,<br />
-
-const property_type& property)</font></td>
- <td>I<font face="Times New Roman">nsert a polygon set with an associated
- property.</font> Linear wrt vertices inserted.</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>Property Merge</h1>
+ <p> </p>
+ <p>The following is the declaration of the property merge
+algorithm.</p>
+ <p><font face="Courier New">template <typename
+coordinate_type, typename property_type><br />
+class property_merge;</font></p>
+ <p>The property algorithm computes the n-layer map overlay of
+input polygon sets. Each input geometry is inserted along with a
+property value. The property type can be anything suitable for
+use as an element of a std::set. Multiple geometry objects can be
+separately inserted with the same property value. To store the
+result of this operation a fairly complex container is required.
+Resulting geometries are associated with unique subsets of property
+values of the input geometry. Two suitable containers for storing
+the result of a property merge operation are:</p>
+ <p><font face="Courier New">std::map<std::set<property_type>,
+polygon_set_data<coordinate_type> ><br />
+std::map<std::vector<property_type>,
+polygon_set_data<coordinate_type> ></font></p>
+ <p>Example code property_merge_usage.cpp
+demonstrates using the n-layer map-overlay algorithm on polygon data.</p>
+ <h2>Member Functions</h2>
+ <table id="table1" border="1" width="100%">
+ <tbody>
+ <tr>
+ <td width="586"><b><font face="Courier New">property_merge</font></b><font
+ face="Courier New">()</font></td>
+ <td>Default constructor. </td>
+ </tr>
+ <tr>
+ <td width="586"><b><font face="Courier New">property_merge</font></b><font
+ face="Courier New">(const property_merge& that)</font></td>
+ <td>Copy construct.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">void <br />
+ <b>insert</b>(const
+polygon_set_data<coordinate_type>& ps,<br />
+ const property_type& property)</font></td>
+ <td>I<font face="Times New Roman">nsert a polygon set with
+an associated property.</font> Linear wrt vertices inserted.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">
template <class GeoObjT><br />
-void <b>insert</b>(const GeoObjT& geoObj,<br />
-
-const property_type& property)</font></td>
- <td>Insert a geometry object that is a refinement of polygon set with an
- associated property. Linear wrt vertices inserted.</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">
+void <b>insert</b>(const GeoObjT& geoObj,<br />
+ const property_type& property)</font></td>
+ <td>Insert a geometry object that is a refinement of
+polygon set with an associated property. Linear wrt vertices
+inserted.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">
template <typename result_type><br />
void <b>merge</b>(result_type& result)</font></td>
- <td>Accepts a container object that conforms to the expectations defined
- above. Performs property merge and populates the container
- object. Expected n log n runtime, worst case quadratic runtime 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="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 container object that conforms to the
+expectations defined above. Performs property merge and populates
+the container object. Expected n log n runtime, worst case
+quadratic runtime 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="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: trunk/libs/polygon/doc/gtl_property_merge_45.htm
==============================================================================
--- trunk/libs/polygon/doc/gtl_property_merge_45.htm (original)
+++ trunk/libs/polygon/doc/gtl_property_merge_45.htm 2013-04-07 19:23:46 EDT (Sun, 07 Apr 2013)
@@ -1,162 +1,186 @@
<!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: Property Merge 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: Property Merge 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><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>Property Merge 45</h1>
-
-<p>
-</p><p>The following is the declaration of the property merge algorithm.</p><p>
-<font face="Courier New">template <typename coordinate_type, typename
-property_type><br />
-class property_merge_45;</font></p><p>The property algorithm computes the n-layer
-map overlay of input polygon sets. Each input geometry is inserted along
-with a property value. The property type can be anything suitable for use
-as an element of a std::set. Multiple geometry objects can be separately
-inserted with the same property value. To store the result of this
-operation a fairly complex container is required. Resulting geometries are
-associated with unique subsets of property values of the input geometry.
-Two suitable containers for storing the result of a property merge operation
-are:</p><p><font face="Courier New">std::map<std::set<property_type>, polygon_45_set_data<coordinate_type>
-><br />
-std::map<std::vector<property_type>, polygon_45_set_data<coordinate_type> ></font></p><p>
-Example code property_merge_usage.cpp
- demonstrates using the n-layer map-overlay algorithm on polygon 90 data.</p><h2>Member Functions</h2>
-<table id="table1" border="1" width="100%">
- <tbody><tr>
- <td width="586"><b><font face="Courier New">property_merge_45</font></b><font face="Courier New">()</font></td>
- <td>Default constructor. </td>
- </tr>
- <tr>
- <td width="586"><b><font face="Courier New">property_merge_45</font></b><font face="Courier New">(const
- property_merge_45& that)</font></td>
- <td>Copy construct.</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">void <br /><b>insert</b>(const polygon_45_set_data<coordinate_type>& ps,<br />
-
-const property_type& property)</font></td>
- <td>I<font face="Times New Roman">nsert a polygon set with an associated
- property.</font> Linear wrt vertices inserted.</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>Property Merge 45</h1>
+ <p> </p>
+ <p>The following is the declaration of the property merge
+algorithm.</p>
+ <p><font face="Courier New">template <typename
+coordinate_type, typename property_type><br />
+class property_merge_45;</font></p>
+ <p>The property algorithm computes the n-layer map overlay of
+input polygon sets. Each input geometry is inserted along with a
+property value. The property type can be anything suitable for
+use as an element of a std::set. Multiple geometry objects can be
+separately inserted with the same property value. To store the
+result of this operation a fairly complex container is required.
+Resulting geometries are associated with unique subsets of property
+values of the input geometry. Two suitable containers for storing
+the result of a property merge operation are:</p>
+ <p><font face="Courier New">std::map<std::set<property_type>,
+polygon_45_set_data<coordinate_type> ><br />
+std::map<std::vector<property_type>,
+polygon_45_set_data<coordinate_type> ></font></p>
+ <p>Example code property_merge_usage.cpp
+demonstrates using the n-layer map-overlay algorithm on polygon 90 data.</p>
+ <h2>Member Functions</h2>
+ <table id="table1" border="1" width="100%">
+ <tbody>
+ <tr>
+ <td width="586"><b><font face="Courier New">property_merge_45</font></b><font
+ face="Courier New">()</font></td>
+ <td>Default constructor. </td>
+ </tr>
+ <tr>
+ <td width="586"><b><font face="Courier New">property_merge_45</font></b><font
+ face="Courier New">(const property_merge_45& that)</font></td>
+ <td>Copy construct.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">void <br />
+ <b>insert</b>(const
+polygon_45_set_data<coordinate_type>& ps,<br />
+ const property_type& property)</font></td>
+ <td>I<font face="Times New Roman">nsert a polygon set with
+an associated property.</font> Linear wrt vertices inserted.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">
template <class GeoObjT><br />
-void <b>insert</b>(const GeoObjT& geoObj,<br />
-
-const property_type& property)</font></td>
- <td>Insert a geometry object that is a refinement of polygon 45 set with
- an associated property. Linear wrt vertices inserted.</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">
+void <b>insert</b>(const GeoObjT& geoObj,<br />
+ const property_type& property)</font></td>
+ <td>Insert a geometry object that is a refinement of
+polygon 45 set with an associated property. Linear wrt vertices
+inserted.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">
template <typename result_type><br />
void <b>merge</b>(result_type& result)</font></td>
- <td>Accepts a container object that conforms to the expectations defined
- above. Performs property merge and populates the container
- object. O(n log n) runtime 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="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 container object that conforms to the
+expectations defined above. Performs property merge and populates
+the container object. O(n log n) runtime 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="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: trunk/libs/polygon/doc/gtl_property_merge_90.htm
==============================================================================
--- trunk/libs/polygon/doc/gtl_property_merge_90.htm (original)
+++ trunk/libs/polygon/doc/gtl_property_merge_90.htm 2013-04-07 19:23:46 EDT (Sun, 07 Apr 2013)
@@ -1,162 +1,186 @@
<!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: Property Merge 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: Property Merge 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><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>Property Merge 90</h1>
-
-<p>
-</p><p>The following is the declaration of the property merge algorithm.</p><p>
-<font face="Courier New">template <typename coordinate_type, typename
-property_type><br />
-class property_merge_90;</font></p><p>The property algorithm computes the n-layer
-map overlay of input polygon sets. Each input geometry is inserted along
-with a property value. The property type can be anything suitable for use
-as an element of a std::set. Multiple geometry objects can be separately
-inserted with the same property value. To store the result of this
-operation a fairly complex container is required. Resulting geometries are
-associated with unique subsets of property values of the input geometry.
-Two suitable containers for storing the result of a property merge operation
-are:</p><p><font face="Courier New">std::map<std::set<property_type>, polygon_90_set_data<coordinate_type>
-><br />
-std::map<std::vector<property_type>, polygon_90_set_data<coordinate_type> ></font></p><p>
-Example code property_merge_usage.cpp
- demonstrates using the n-layer map-overlay algorithm on polygon 90 data.</p><h2>Member Functions</h2>
-<table id="table1" border="1" width="100%">
- <tbody><tr>
- <td width="586"><b><font face="Courier New">property_merge_90</font></b><font face="Courier New">()</font></td>
- <td>Default constructor. </td>
- </tr>
- <tr>
- <td width="586"><b><font face="Courier New">property_merge_90</font></b><font face="Courier New">(const
- property_merge_90& that)</font></td>
- <td>Copy construct.</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">void <br /><b>insert</b>(const polygon_90_set_data<coordinate_type>& ps,<br />
-
-const property_type& property)</font></td>
- <td>I<font face="Times New Roman">nsert a polygon set with an associated
- property.</font> Linear wrt vertices inserted.</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>Property Merge 90</h1>
+ <p> </p>
+ <p>The following is the declaration of the property merge
+algorithm.</p>
+ <p><font face="Courier New">template <typename
+coordinate_type, typename property_type><br />
+class property_merge_90;</font></p>
+ <p>The property algorithm computes the n-layer map overlay of
+input polygon sets. Each input geometry is inserted along with a
+property value. The property type can be anything suitable for
+use as an element of a std::set. Multiple geometry objects can be
+separately inserted with the same property value. To store the
+result of this operation a fairly complex container is required.
+Resulting geometries are associated with unique subsets of property
+values of the input geometry. Two suitable containers for storing
+the result of a property merge operation are:</p>
+ <p><font face="Courier New">std::map<std::set<property_type>,
+polygon_90_set_data<coordinate_type> ><br />
+std::map<std::vector<property_type>,
+polygon_90_set_data<coordinate_type> ></font></p>
+ <p>Example code property_merge_usage.cpp
+demonstrates using the n-layer map-overlay algorithm on polygon 90 data.</p>
+ <h2>Member Functions</h2>
+ <table id="table1" border="1" width="100%">
+ <tbody>
+ <tr>
+ <td width="586"><b><font face="Courier New">property_merge_90</font></b><font
+ face="Courier New">()</font></td>
+ <td>Default constructor. </td>
+ </tr>
+ <tr>
+ <td width="586"><b><font face="Courier New">property_merge_90</font></b><font
+ face="Courier New">(const property_merge_90& that)</font></td>
+ <td>Copy construct.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">void <br />
+ <b>insert</b>(const
+polygon_90_set_data<coordinate_type>& ps,<br />
+ const property_type& property)</font></td>
+ <td>I<font face="Times New Roman">nsert a polygon set with
+an associated property.</font> Linear wrt vertices inserted.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">
template <class GeoObjT><br />
-void <b>insert</b>(const GeoObjT& geoObj,<br />
-
-const property_type& property)</font></td>
- <td>Insert a geometry object that is a refinement of polygon 90 set with
- an associated property. Linear wrt vertices inserted.</td>
- </tr>
- <tr>
- <td width="586">
-<font face="Courier New">
+void <b>insert</b>(const GeoObjT& geoObj,<br />
+ const property_type& property)</font></td>
+ <td>Insert a geometry object that is a refinement of
+polygon 90 set with an associated property. Linear wrt vertices
+inserted.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">
template <typename result_type><br />
void <b>merge</b>(result_type& result)</font></td>
- <td>Accepts a container object that conforms to the expectations defined
- above. Performs property merge and populates the container
- object. O(n log n) runtime 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="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 container object that conforms to the
+expectations defined above. Performs property merge and populates
+the container object. O(n log n) runtime 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="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: trunk/libs/polygon/doc/gtl_rectangle_concept.htm
==============================================================================
--- trunk/libs/polygon/doc/gtl_rectangle_concept.htm (original)
+++ trunk/libs/polygon/doc/gtl_rectangle_concept.htm 2013-04-07 19:23:46 EDT (Sun, 07 Apr 2013)
@@ -1,775 +1,859 @@
<!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: Rectangle 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: Rectangle 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>Rectangle Concept</h1>
-
-<p>
-</p><p>The rectangle 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>Rectangle Concept</h1>
+ <p> </p>
+ <p>The rectangle concept tag is <font face="Courier New">
rectangle_concept</font></p>
-<p>
-To register a user defined type as a model of
-<font face="Times New Roman">rectangle </font>concept, specialize the
-geometry concept meta-function for that type. In the example below CRectangle is registered as a model of
-rectangle concept.</p><p>
-<font face="Courier New">template <><br />
-struct geometry_concept<CRectangle> { typedef rectangle_concept type; };</font></p><p>
-<font face="Times New Roman">The semantic of a rectangle is that it has an x and
-a y interval and these intervals conform to the semantic of an interval
-including its invariant. This invariant on the intervals of a rectangle is enforced by the generic library functions that
-operate on rectangles, and is not expected of the data type itself or the concept
-mapping of that data type to the rectangle concept through its traits. In
-this way a boost::tuple<int, int, int, int> or boost::array<int, 4>
-could be made models of rectangle by simply providing indirect access to their
-elements through traits.</font></p><p>
-<font face="Times New Roman">Below is shown the default rectangle traits.
-Specialization of these traits is required for types that don't conform to the
-default behavior. The interested reader will note SFINAE is used on the
-traits to allow only an object that provides a member type definition of
-interval_type to work with the default read only traits. This becomes
-necessary when refinements of concepts are used and it is undesirable to attempt
-to match default traits to non-rectangle types at compile time.
-Specializing rectangle_traits can be done easily by simply providing gtl_yes as
-the enable parameter.</font></p><p>
-<font face="Courier New">template <typename T, typename enable = gtl_yes><br />
-struct rectangle_traits {};</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">rectangle </font>concept, specialize the
+geometry concept meta-function for that type. In the example
+below CRectangle is registered as a model of rectangle concept.</p>
+ <p> <font face="Courier New">template <><br />
+struct geometry_concept<CRectangle> { typedef rectangle_concept
+type; };</font></p>
+ <p> <font face="Times New Roman">The semantic of a rectangle is
+that it has an x and a y interval and these intervals conform to the
+semantic of an interval including its invariant. This invariant
+on the intervals of a rectangle is enforced by the generic library
+functions that operate on rectangles, and is not expected of the data
+type itself or the concept mapping of that data type to the rectangle
+concept through its traits. In this way a boost::tuple<int,
+int, int, int> or boost::array<int, 4> could be made models of
+rectangle by simply providing indirect access to their elements through
+traits.</font></p>
+ <p> <font face="Times New Roman">Below is shown the default
+rectangle traits. Specialization of these traits is required for
+types that don't conform to the default behavior. The interested
+reader will note SFINAE is used on the traits to allow only an object
+that provides a member type definition of interval_type to work with
+the default read only traits. This becomes necessary when
+refinements of concepts are used and it is undesirable to attempt to
+match default traits to non-rectangle types at compile time.
+Specializing rectangle_traits can be done easily by simply providing
+gtl_yes as the enable parameter.</font></p>
+ <p> <font face="Courier New">template <typename T, typename
+enable = gtl_yes><br />
+struct rectangle_traits {};</font></p>
+ <p> <font face="Courier New">template <typename T><br />
struct rectangle_traits<T, gtl_no> {};<br />
-<br />
+ <br />
template <typename T><br />
-struct rectangle_traits<T, typename gtl_same_type<typename T::interval_type,
-typename T::interval_type>::type> {<br />
- typedef typename T::coordinate_type coordinate_type;<br />
- typedef typename T::interval_type interval_type;<br />
- static inline interval_type get(const T& rectangle,
-orientation_2d orient) {<br />
- return
+struct rectangle_traits<T, typename gtl_same_type<typename
+T::interval_type, typename T::interval_type>::type> {<br />
+ typedef typename T::coordinate_type
+coordinate_type;<br />
+ typedef typename T::interval_type
+interval_type;<br />
+ static inline interval_type get(const T&
+rectangle, orientation_2d orient) {<br />
+ return
rectangle.get(orient); }<br />
};<br />
-<br />
+ <br />
template <typename T><br />
struct rectangle_mutable_traits {<br />
template <typename T2><br />
- static inline void set(T& rectangle, orientation_2d
-orient, const T2& interval) {<br />
- rectangle.set(orient,
-interval); }<br />
+ static inline void set(T& rectangle,
+orientation_2d orient, const T2& interval) {<br />
+
+rectangle.set(orient, interval); }<br />
template <typename T2, typename T3><br />
- static inline T construct(const T2& interval_horizontal,
-const T3& interval_vertical) {<br />
- return
+ static inline T construct(const T2&
+interval_horizontal, const T3& interval_vertical) {<br />
+ return
T(interval_horizontal, interval_vertical); }<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 />
- interval_type <b>get</b>(const T& rectangle, orientation_2d)</font></td>
- <td><font face="Times New Roman">Expects a model of rectangle.
- Returns the x interval or y interval of the rectangle, depending on the
- orientation_2d 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 />
+interval_type <b>get</b>(const T& rectangle, orientation_2d)</font></td>
+ <td><font face="Times New Roman">Expects a model of
+rectangle. Returns the x interval or y interval of the rectangle,
+depending on the orientation_2d 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& rectangle, orientation_2d, coordinate_type)</font></td>
- <td><font face="Times New Roman">Expects a model of rectangle.
- Sets the x interval or y interval of the rectangle to the
- coordinate, depending on the orientation_2d value.</font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- interval_type <b>get</b>(const T& rectangle, orientation_2d,
- <br /> direction_1d)</font></td>
- <td><font face="Times New Roman">Expects
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename coordinate_type><br />
+void <b>set</b>(T& rectangle, orientation_2d, coordinate_type)</font></td>
+ <td><font face="Times New Roman">Expects a model of
+rectangle. Sets the x interval or y interval of the
+rectangle to the coordinate, depending on the orientation_2d value.</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+interval_type <b>get</b>(const T& rectangle, orientation_2d, <br />
+
+direction_1d)</font></td>
+ <td><font face="Times New Roman">Expects
a model of rectangle. Returns the coordinate specificed by the
direction_1d value of the x interval or y interval of the rectangle,
depending on the orientation_2d 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& rectangle, orientation_2d, direction_1d, <br /> coordinate_type)</font></td>
- <td><font face="Times New Roman">Expects a model of rectangle.
- Sets the coordinate specified by the direction_1d value of the x interval or y interval of the rectangle to the
- coordinate, depending on the orientation_2d value.</font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T, typename
- T2><br />
- T <b>construct</b>(const T2& h, const T2& v)</font></td>
- <td>Construct an object that is a model of rectangle given x interval
- and y intervals.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T, typename
- T2><br />
- T <b>construct</b>(coordinate_type xl, coordinate_type yl, <br /> coordinate_type
- xh, coordinate_type yh)</font></td>
- <td>Construct an object that is a model of rectangle given four 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 rectangle into left object
- that models rectangle.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T, typename
- T2><br />
- bool <b>equivalence</b>(const T& rectangle1, </font>
- <br /><font face="Courier New"> const T2& rectangle2)</font></td>
- <td>Given two objects that model rectangle, compares and returns true if
- their x and y intervals are respectively equivalent.</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 rectangle and an object that models
- point, returns true
- if the rectangle contains the point. If the consider_touch
- flag is true will return true if the point lies along the boundary of
- the rectangle.</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 rectangle a contains both intervals of
- model of rectangle b. If the consider_touch flag is true will
- consider rectangle b contained even if it touches the boundary of a.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- interval_type <b>horizontal</b>(const T& rectangle)</font></td>
- <td>Returns the x interval of an object that models rectangle.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- interval_type <b>vertical</b>(const T& rectangle)</font></td>
- <td>Returns the y interval of an object that models rectangle.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- coordinate_type <b>xl</b>(const T& rectangle)</font></td>
- <td>Returns the west coordinate of an object that models rectangle.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- coordinate_type <b>xh</b>(const T& rectangle)</font></td>
- <td>Returns the east coordinate of an object that models rectangle.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- coordinate_type <b>yl</b>(const T& rectangle)</font></td>
- <td>Returns the south coordinate of an object that models rectangle.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- coordinate_type <b>yh</b>(const T& rectangle)</font></td>
- <td>Returns the north coordinate of an object that models rectangle.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- point_type <b>ll</b>(const T& rectangle)</font></td>
- <td>Returns the lower left corner point of an object that models rectangle.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- point_type <b>lr</b>(const T& rectangle)</font></td>
- <td>Returns the lower right corner point of an object that models rectangle.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- point_type <b>ul</b>(const T& rectangle)</font></td>
- <td>Returns the upper left corner point of an object that models rectangle.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- point_type <b>ur</b>(const T& rectangle)</font></td>
- <td>Returns the upper right corner point of an object that models rectangle.</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& rectangle)</font></td>
- <td>Sets object that models point to the center point of an object that models rectangle.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T,
- typename interval_type><br />
- void <b>horizontal</b>(T& rectangle, const interval_type& i)</font></td>
- <td>Sets the x interval of the object that models rectangle to be equal
- to the value of an object that models interval.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T,
- typename interval_type><br />
- void <b>vertical</b>(T& rectangle, const interval_type& i )</font></td>
- <td>Sets the y interval of the object that models rectangle to be equal
- to the value of an object that models interval.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename
- rectangle_type><br />
- void <b>xl</b>(rectangle_type& rectangle, coordinate_type )</font></td>
- <td>Sets the west coordinate of the object that models rectangle to be equal
- to the coordinate value.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename
- rectangle_type><br />
- void <b>xh</b>(rectangle_type& rectangle, coordinate_type )</font></td>
- <td>Sets the east coordinate of the object that models rectangle to be equal
- to the coordinate value.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename
- rectangle_type><br />
- void <b>yl</b>(rectangle_type& rectangle, coordinate_type )</font></td>
- <td>Sets the south coordinate of the object that models rectangle to be equal
- to the coordinate value.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename
- rectangle_type><br />
- void <b>yh</b>(rectangle_type& rectangle, coordinate_type )</font></td>
- <td>Sets the north coordinate of the object that models rectangle to be equal
- to the coordinate value.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T,
- typename T1, typename T2><br />
- T& <b>set_points</b>(T& rectangle, const T1& p1, const T2& p2)</font></td>
- <td>Sets the rectangle to the rectangle fully described by the points p1
- and p2.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- coordinate_difference <b>delta</b>(const T& rectangle,
- <br />
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename coordinate_type><br />
+void <b>set</b>(T& rectangle, orientation_2d, direction_1d, <br />
+ coordinate_type)</font></td>
+ <td><font face="Times New Roman">Expects a model of
+rectangle. Sets the coordinate specified by the
+direction_1d value of the x interval or y interval of the rectangle to
+the coordinate, depending on the orientation_2d value.</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename T2><br />
+T <b>construct</b>(const T2& h, const T2& v)</font></td>
+ <td>Construct an object that is a model of rectangle given
+x interval and y intervals.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename T2><br />
+T <b>construct</b>(coordinate_type xl, coordinate_type yl, <br />
+
+coordinate_type xh, coordinate_type yh)</font></td>
+ <td>Construct an object that is a model of rectangle given
+four 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 rectangle
+into left object that models rectangle.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename T2><br />
+bool <b>equivalence</b>(const T& rectangle1, </font> <br />
+ <font face="Courier New">
+const T2& rectangle2)</font></td>
+ <td>Given two objects that model rectangle, compares and
+returns true if their x and y intervals are respectively equivalent.</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 rectangle and an object
+that models point, returns true if the rectangle contains the
+point. If the consider_touch flag is true will return true if the
+point lies along the boundary of the rectangle.</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 rectangle a contains both
+intervals of model of rectangle b. If the consider_touch flag is
+true will consider rectangle b contained even if it touches the
+boundary of a.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+interval_type <b>horizontal</b>(const T& rectangle)</font></td>
+ <td>Returns the x interval of an object that models
+rectangle.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+interval_type <b>vertical</b>(const T& rectangle)</font></td>
+ <td>Returns the y interval of an object that models
+rectangle.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+coordinate_type <b>xl</b>(const T& rectangle)</font></td>
+ <td>Returns the west coordinate of an object that models
+rectangle.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+coordinate_type <b>xh</b>(const T& rectangle)</font></td>
+ <td>Returns the east coordinate of an object that models
+rectangle.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+coordinate_type <b>yl</b>(const T& rectangle)</font></td>
+ <td>Returns the south coordinate of an object that models
+rectangle.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+coordinate_type <b>yh</b>(const T& rectangle)</font></td>
+ <td>Returns the north coordinate of an object that models
+rectangle.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+point_type <b>ll</b>(const T& rectangle)</font></td>
+ <td>Returns the lower left corner point of an object that
+models rectangle.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+point_type <b>lr</b>(const T& rectangle)</font></td>
+ <td>Returns the lower right corner point of an object that
+models rectangle.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+point_type <b>ul</b>(const T& rectangle)</font></td>
+ <td>Returns the upper left corner point of an object that
+models rectangle.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+point_type <b>ur</b>(const T& rectangle)</font></td>
+ <td>Returns the upper right corner point of an object that
+models rectangle.</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& rectangle)</font></td>
+ <td>Sets object that models point to the center point of an
+object that models rectangle.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename interval_type><br />
+void <b>horizontal</b>(T& rectangle, const interval_type& i)</font></td>
+ <td>Sets the x interval of the object that models rectangle
+to be equal to the value of an object that models interval.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename interval_type><br />
+void <b>vertical</b>(T& rectangle, const interval_type& i )</font></td>
+ <td>Sets the y interval of the object that models rectangle
+to be equal to the value of an object that models interval.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename rectangle_type><br />
+void <b>xl</b>(rectangle_type& rectangle, coordinate_type )</font></td>
+ <td>Sets the west coordinate of the object that models
+rectangle to be equal to the coordinate value.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename rectangle_type><br />
+void <b>xh</b>(rectangle_type& rectangle, coordinate_type )</font></td>
+ <td>Sets the east coordinate of the object that models
+rectangle to be equal to the coordinate value.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename rectangle_type><br />
+void <b>yl</b>(rectangle_type& rectangle, coordinate_type )</font></td>
+ <td>Sets the south coordinate of the object that models
+rectangle to be equal to the coordinate value.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename rectangle_type><br />
+void <b>yh</b>(rectangle_type& rectangle, coordinate_type )</font></td>
+ <td>Sets the north coordinate of the object that models
+rectangle to be equal to the coordinate value.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename T1, typename T2><br />
+T& <b>set_points</b>(T& rectangle, const T1& p1, const
+T2& p2)</font></td>
+ <td>Sets the rectangle to the rectangle fully described by
+the points p1 and p2.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+coordinate_difference <b>delta</b>(const T& rectangle, <br />
+
orientation_2d)</font></td>
- <td>Returns the delta of the interval specified by orientation_2d of an object
- that models rectangle.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- manhattan_area_type <b>area</b>(const T& rectangle)</font></td>
- <td>Returns the area of an object
- that models rectangle.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- coordinate_difference <b>half_perimeter</b>(const T& rectangle)</font></td>
- <td>Returns the length plus width of an object
- that models rectangle.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- coordinate_difference <b>perimeter</b>(const T& rectangle)</font></td>
- <td>Returns the perimeter length of an object
- that models rectangle.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- orientation_2d <b>quess_orientation</b>(const T& rectangle)</font></td>
- <td>Returns the orientation in which the rectangle has a longer delta.
- Returns HORIZONTAL if the rectangle is a square.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename
- rectangle_type><br />
- rectangle_type& <b>transform</b>(rectangle_type& rectangle,<br />
+ <td>Returns the delta of the interval specified by
+orientation_2d of an object that models rectangle.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+manhattan_area_type <b>area</b>(const T& rectangle)</font></td>
+ <td>Returns the area of an object that models rectangle.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+coordinate_difference <b>half_perimeter</b>(const T& rectangle)</font></td>
+ <td>Returns the length plus width of an object that models
+rectangle.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+coordinate_difference <b>perimeter</b>(const T& rectangle)</font></td>
+ <td>Returns the perimeter length of an object that models
+rectangle.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+orientation_2d <b>quess_orientation</b>(const T& rectangle)</font></td>
+ <td>Returns the orientation in which the rectangle has a
+longer delta. Returns HORIZONTAL if the rectangle is a square.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename rectangle_type><br />
+rectangle_type& <b>transform</b>(rectangle_type& rectangle,<br />
coordinate_type axis = 0)</font></td>
- <td>Applies transform() on the two points that fully describe the
- rectangle and sets the rectangle to that described by the result of
- transforming those points.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename
- rectangle_type><br />
- rectangle_type& <b>scale_up</b>(rectangle_type& rectangle, <br />
+ <td>Applies transform() on the two points that fully
+describe the rectangle and sets the rectangle to that described by the
+result of transforming those points.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename rectangle_type><br />
+rectangle_type& <b>scale_up</b>(rectangle_type& rectangle, <br />
unsigned_area_type factor)</font></td>
- <td>Scales up x interval and y interval of an object that models
- rectangle by unsigned factor.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename
- rectangle_type><br />
- rectangle_type& <b>scale_down</b>(rectangle_type& rectangle, <br />
+ <td>Scales up x interval and y interval of an object
+that models rectangle by unsigned factor.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename rectangle_type><br />
+rectangle_type& <b>scale_down</b>(rectangle_type& rectangle, <br />
unsigned_area_type factor)</font></td>
- <td>Scales down x interval and y interval of an object that models
- rectangle by unsigned factor.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename
- rectangle_type, scaling_type><br />
- rectangle_type& <b>scale</b>(rectangle_type& rectangle,<br />
-
- const scaling_type& scaling) </font></td>
- <td>Applies scale() on the two points that fully describe the rectangle
- and sets the rectangle to that described by the result of transforming
- those points.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- T& <b>move</b>(T& rectangle, orientation_2d,<br />
- coordinate_difference displacement)</font></td>
- <td>Adds displacement value to interval indicated by orientation_2d of an
- object that models rectangle.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename
- rectangle_type, typename point_type><br />
- rectangle_type& <b>convolve</b>(rectangle_type& rectangle,<br />
+ <td>Scales down x interval and y interval of an
+object that models rectangle by unsigned factor.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename rectangle_type, scaling_type><br />
+rectangle_type& <b>scale</b>(rectangle_type& rectangle,<br />
+
+const scaling_type& scaling) </font></td>
+ <td>Applies scale() on the two points that fully describe
+the rectangle and sets the rectangle to that described by the result of
+transforming those points.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+T& <b>move</b>(T& rectangle, orientation_2d,<br />
+ coordinate_difference
+displacement)</font></td>
+ <td>Adds displacement value to interval indicated by
+orientation_2d of an object that models rectangle.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename rectangle_type, typename point_type><br />
+rectangle_type& <b>convolve</b>(rectangle_type& rectangle,<br />
const point_type& point)</font></td>
- <td>Convolves coordinate values of point with x interval and y interval of an
- object that models rectangle.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename
- rectangle_type, typename point_type><br />
- rectangle_type& <b>deconvolve</b>(rectangle_type& rectangle,<br />
+ <td>Convolves coordinate values of point with x interval
+and y interval of an object that models rectangle.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename rectangle_type, typename point_type><br />
+rectangle_type& <b>deconvolve</b>(rectangle_type& rectangle,<br />
const point_type& point)</font></td>
- <td>Deconvolves coordinate values of point withx interval and y interval of
- an object that models rectangle.</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>Convolves x interval of b with x interval of a and
- convolves y
- interval of b with y interval 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>Deconvolves x interval of b with x interval of a and
- deconvolves y interval of b with y interval 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>Reflected convolves y interval of b with x interval of a and
- reflected convolves x
- interval of b with y interval 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>Reflected deconvolves y interval of b with x interval of a and
- reflected deconvolves x interval of b with y interval of a.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T,
- typename point_type><br />
- coordinate_difference <b>euclidean_distance</b>(const T&,<br />
- const point_type& point,
- orienation_2d)</font></td>
- <td>Returns the distance from an object that models rectangle to an
- object that models point along the given orientation. Returns zero
- if the point is contained within the rectangle along that orientation.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1,
- typename T2><br />
- coordinate_difference <b>euclidean_distance</b>(const T1& a,<br />
- const T2& b, orienation_2d)</font></td>
- <td>Returns the distance from an object that models rectangle to an
- object that models rectangle along the given orientation. Returns
- zero if the intervals of the rectangles overlap along that orientation.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T,
- typename point_type><br />
- coordinate_difference <b>square_euclidean_distance</b>(const T&,<br />
- const point_type& point)</font></td>
- <td>Returns the square of the Euclidean distance between a point and a
- rectangle. Returns zero if the point is contained within the
- rectangle.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1,
- typename T2><br />
- coordinate_difference <b>square_euclidean_distance</b><br />
- (const T1& a, const T2& b)</font></td>
- <td>Returns the square of the Euclidean distance between rectangles a
- and b. Returns zero if the rectangles intersect.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T,
- typename point_type><br />
- coordinate_difference <b>manhattan_distance</b>(const T&,<br />
- const point_type& point)</font></td>
- <td>Returns the Manhattan distance between a point and a rectangle.
- Returns zero if the point is contained within the rectangle.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1,
- typename T2><br />
- coordinate_difference <b>manhattan_distance</b>(const T1& a, <br />
+ <td>Deconvolves coordinate values of point withx interval
+and y interval of an object that models rectangle.</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>Convolves x interval of b with x interval
+of a and convolves y interval of b with y interval 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>Deconvolves x interval of b with x interval
+of a and deconvolves y interval of b with y interval 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>Reflected convolves y interval of b with x
+interval of a and reflected convolves x interval of b with
+y interval 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>Reflected deconvolves y interval of b with x
+interval of a and reflected deconvolves x interval of b
+with y interval of a.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename point_type><br />
+coordinate_difference <b>euclidean_distance</b>(const T&,<br />
+ const point_type& point,
+orienation_2d)</font></td>
+ <td>Returns the distance from an object that models
+rectangle to an object that models point along the given
+orientation. Returns zero if the point is contained within the
+rectangle along that orientation.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+coordinate_difference <b>euclidean_distance</b>(const T1& a,<br />
+ const T2& b, orienation_2d)</font></td>
+ <td>Returns the distance from an object that models
+rectangle to an object that models rectangle along the given
+orientation. Returns zero if the intervals of the rectangles
+overlap along that orientation.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename point_type><br />
+coordinate_difference <b>square_euclidean_distance</b>(const T&,<br />
+ const point_type& point)</font></td>
+ <td>Returns the square of the Euclidean distance between a
+point and a rectangle. Returns zero if the point is contained
+within the rectangle.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+coordinate_difference <b>square_euclidean_distance</b><br />
+ (const T1& a, const T2& b)</font></td>
+ <td>Returns the square of the Euclidean distance between
+rectangles a and b. Returns zero if the rectangles intersect.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename point_type><br />
+coordinate_difference <b>manhattan_distance</b>(const T&,<br />
+ const point_type& point)</font></td>
+ <td>Returns the Manhattan distance between a point and a
+rectangle. Returns zero if the point is contained within the
+rectangle.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+coordinate_difference <b>manhattan_distance</b>(const T1& a, <br />
const T2& b)</font></td>
- <td>Returns the Manhattan distance between rectangles a and b.
- Returns zero if the rectangles intersect.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T,
- typename point_type><br />
- coordinate_distance <b>euclidean_distance</b>(const T&,<br />
- const point_type& point)</font></td>
- <td>Returns the Euclidean distance between a point and a rectangle.
- Returns zero if the point is contained within the rectangle.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1,
- typename T2><br />
- coordinate_distance <b>euclidean_distance</b>(const T1& a, <br />
+ <td>Returns the Manhattan distance between rectangles a and
+b. Returns zero if the rectangles intersect.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename point_type><br />
+coordinate_distance <b>euclidean_distance</b>(const T&,<br />
+ const point_type& point)</font></td>
+ <td>Returns the Euclidean distance between a point and a
+rectangle. Returns zero if the point is contained within the
+rectangle.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+coordinate_distance <b>euclidean_distance</b>(const T1& a, <br />
const T2& b)</font></td>
- <td>Returns the Euclidean distance between rectangles a and b.
- Returns zero if the rectangles intersect.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><br />
- bool <b>intersects</b>(const T1& a, const T2& b, <br />
-
- bool consider_touch = true)</font></td>
- <td>Returns true if two objects that model rectangle overlap. If
- the consider_touch flag is true touching at the sides or corners 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& a, const T2& b, <br />
+ <td>Returns the Euclidean distance between rectangles a and
+b. Returns zero if the rectangles intersect.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><br />
+bool <b>intersects</b>(const T1& a, const T2& b, <br />
+
+bool consider_touch = true)</font></td>
+ <td>Returns true if two objects that model rectangle
+overlap. If the consider_touch flag is true touching at the sides
+or corners 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& a, const T2& b, <br />
bool consider_touch = true)</font></td>
- <td>Returns true is two objects that model rectangle partially overlap
- such that one there is an intersection between the edges of the two
- rectangles If the consider_touch flag is true a coordinate is
- considered contained even if the two rectangles touch only along a side
- or corner.</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_2d dir)
- </font></td>
- <td>Returns true if rectangle b abuts but down not overlap rectangle a
- on the side of rectangle 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,<br />
- orientation_2d)
- </font></td>
- <td>Returns true if rectangle b abuts but down not overlap rectangle a
- on either side of rectangle a specified by the orientation_2d.</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 rectangle b abuts but down not overlap rectangle a
- on any side.</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, orientation_2d<br />
-
- bool consider_touch = true) </font></td>
- <td>Sets rectangle a to the intersection of rectangle a and interval b
- along the orientation_2d
- and returns true. If the does not intersect the interval, the
- rectangle 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 />
- bool <b>intersect</b>(T1& a, const T2& b,<br />
-
- bool consider_touch = true) </font></td>
- <td>Sets rectangle a to the intersection of rectangle a and rectangle b
- and return true. If the two rectangles do not intersect rectangle
- a is unchanged and the function returns false. If the flag
- consider_touch is true rectangles 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
- rectangle between a and b by applying generalized_intersect() on the
- intervals of the rectangles.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- T& <b>bloat</b>(T& rectangle, coordinate_type)</font></td>
- <td>Bloats x and y intervals of rectangle by coordinate value.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- T& <b>bloat</b>(T& rectangle, direction_2d, coordinate_type)</font></td>
- <td>Bloats side of rectangle specified by direction_2d by coordinate
- value.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- T& <b>bloat</b>(T& rectangle, orientation_2d, coordinate_type)</font></td>
- <td>Bloats interval of rectangle specified by orientation_2d by
- coordinate value.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- T& <b>shrink</b>(T& rectangle, coordinate_type)</font></td>
- <td>Shrinks x and y intervals of rectangle by coordinate value.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- T& <b>shrink</b>(T& rectangle, direction_2d, coordinate_type)</font></td>
- <td>Shrinks side of rectangle specified by direction_2d by coordinate
- value.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T><br />
- T& <b>shrink</b>(T& rectangle, orientation_2d, coordinate_type)</font></td>
- <td>Shrinks interval of rectangle specified by orientation_2d by
- coordinate value.</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>The x and y intervals of a are set to encompass the x and y
- intervals of b respectively.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T, typename
- point_type><br />
- bool <b>encompass</b>(T& rectangle, const point_type& point)</font></td>
- <td>The x and y intervals of rectangle are set to encompass the x and y
- coordinates of point respectively.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T, typename
- interval_type><br />
- bool <b>encompass</b>(T& rectangle, const interval_type& i,
- <br /> orientation_2d)</font></td>
- <td>The interval of rectangle specified by orientation_2d is set to encompass the
- interval i.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T, typename
- point_type><br />
- bool <b>get_corner</b>(point_type& point, const T& rectangle,
- <br />
- direction_2d, direction_1d)</font></td>
- <td>Sets point to the corner of the rectangle you reach if you look at
- its side specified by direction_2d from within the rectangle and turn in
- the direction_1d direction (low == left, high = right). Always
- returns true.</td>
- </tr>
-</tbody></table>
- <h1>Rectangle Data</h1>
-
-<p>
-</p><p>The library provides a model of rectangle concept declared
-<font face="Courier New">
-template<typename T> rectangle_data </font>where T is the coordinate type.</p>
-<p>This data type is used internally when a rectangle is needed and is available
-to the library user who finds it convenient to use a library rectangle 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">rectangle_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_type</b></font></td>
- <td><font face="Times New Roman">interval_data<T></font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New"><b>rectangle_data</b>(T xl, T
- yl, T xh, T yh)</font></td>
- <td><font face="Times New Roman">Constructs a rectangle with four
- coordinates.</font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T1, typename
- T2><b><br />
- rectangle_data</b>(const T1& horizontal_interval,<br />
-
- const T2& vertical_interval)</font></td>
- <td><font face="Times New Roman">Constructs a rectangle with two objects
- that model interval.</font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New"><b>rectangle_data</b>(const
- rectangle_data& that)</font></td>
- <td><font face="Times New Roman">Copy construct</font></td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">rectangle_data& <b>operator=</b>(const
- rectangle_data& that)</font></td>
- <td>Assignment operator.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T2><b>
- <br /> </b>rectangle_data& <b>
- operator=</b>(const T2& that) const</font></td>
- <td>Assign from an object that is a model of rectangle.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T2><b>
- <br /> </b>bool<b>
- operator==</b>(const T2& that) const</font></td>
- <td>Compare equality to an object that is a model of rectangle.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T2><b>
- <br /> </b>bool<b>
- operator!=</b>(const T2& that) const</font></td>
- <td>Compare inequality to an object that is a model of rectangle.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">interval_data<T> <b>get</b>(orientation_2d
- orient) const</font></td>
- <td>Get the interval in the given orientation.</td>
- </tr>
- <tr>
- <td width="586"><font face="Courier New">template <typename T2><br />
- void <b>set</b>(orientation_2d orient, const T2& value)</font></td>
- <td>Sets the interval in the given orientation to the value of an object
- that models interval.</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="table8" frame="void" rules="none">
- <colgroup>
- <col class="docinfo-name" /><col class="docinfo-content" />
- </colgroup>
- <tbody valign="top">
+ <td>Returns true is two objects that model rectangle
+partially overlap such that one there is an intersection between the
+edges of the two rectangles If the consider_touch flag is true a
+coordinate is considered contained even if the two rectangles touch
+only along a side or corner.</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_2d dir) </font></td>
+ <td>Returns true if rectangle b abuts but down not overlap
+rectangle a on the side of rectangle 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,<br />
+
+orientation_2d) </font></td>
+ <td>Returns true if rectangle b abuts but down not overlap
+rectangle a on either side of rectangle a specified by the
+orientation_2d.</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 rectangle b abuts but down not overlap
+rectangle a on any side.</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, orientation_2d<br />
+
+bool consider_touch = true) </font></td>
+ <td>Sets rectangle a to the intersection of rectangle a and
+interval b along the orientation_2d and returns true. If the does
+not intersect the interval, the rectangle 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 />
+bool <b>intersect</b>(T1& a, const T2& b,<br />
+
+bool consider_touch = true) </font></td>
+ <td>Sets rectangle a to the intersection of rectangle a and
+rectangle b and return true. If the two rectangles do not
+intersect rectangle a is unchanged and the function returns
+false. If the flag consider_touch is true rectangles 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 rectangle between a and b by applying generalized_intersect() on
+the intervals of the rectangles.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+T& <b>bloat</b>(T& rectangle, coordinate_type)</font></td>
+ <td>Bloats x and y intervals of rectangle by coordinate
+value.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+T& <b>bloat</b>(T& rectangle, direction_2d, coordinate_type)</font></td>
+ <td>Bloats side of rectangle specified by direction_2d by
+coordinate value.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+T& <b>bloat</b>(T& rectangle, orientation_2d, coordinate_type)</font></td>
+ <td>Bloats interval of rectangle specified by
+orientation_2d by coordinate value.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+T& <b>shrink</b>(T& rectangle, coordinate_type)</font></td>
+ <td>Shrinks x and y intervals of rectangle by coordinate
+value.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+T& <b>shrink</b>(T& rectangle, direction_2d, coordinate_type)</font></td>
+ <td>Shrinks side of rectangle specified by direction_2d by
+coordinate value.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T><br />
+T& <b>shrink</b>(T& rectangle, orientation_2d, coordinate_type)</font></td>
+ <td>Shrinks interval of rectangle specified by
+orientation_2d by coordinate value.</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>The x and y intervals of a are set to encompass the x
+and y intervals of b respectively.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename point_type><br />
+bool <b>encompass</b>(T& rectangle, const point_type& point)</font></td>
+ <td>The x and y intervals of rectangle are set to encompass
+the x and y coordinates of point respectively.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename interval_type><br />
+bool <b>encompass</b>(T& rectangle, const interval_type& i, <br />
+
+orientation_2d)</font></td>
+ <td>The interval of rectangle specified by orientation_2d
+is set to encompass the interval i.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T, typename point_type><br />
+bool <b>get_corner</b>(point_type& point, const T&
+rectangle, <br />
+
+direction_2d, direction_1d)</font></td>
+ <td>Sets point to the corner of the rectangle you reach if
+you look at its side specified by direction_2d from within the
+rectangle and turn in the direction_1d direction (low == left, high =
+right). Always returns true.</td>
+ </tr>
+ </tbody>
+ </table>
+ <h1>Rectangle Data</h1>
+ <p> </p>
+ <p>The library provides a model of rectangle concept declared
+ <font face="Courier New">template<typename T>
+rectangle_data </font>where T is the coordinate type.</p>
+ <p>This data type is used internally when a rectangle is needed
+and is available to the library user who finds it convenient to use a
+library rectangle 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">rectangle_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_type</b></font></td>
+ <td><font face="Times New Roman">interval_data<T></font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New"><b>rectangle_data</b>(T
+xl, T yl, T xh, T yh)</font></td>
+ <td><font face="Times New Roman">Constructs a rectangle
+with four coordinates.</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T1, typename T2><b><br />
+rectangle_data</b>(const T1& horizontal_interval,<br />
+
+const T2& vertical_interval)</font></td>
+ <td><font face="Times New Roman">Constructs a rectangle
+with two objects that model interval.</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New"><b>rectangle_data</b>(const
+rectangle_data& that)</font></td>
+ <td><font face="Times New Roman">Copy construct</font></td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">rectangle_data&
+ <b>operator=</b>(const rectangle_data& that)</font></td>
+ <td>Assignment operator.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T2><b> <br />
+ </b>rectangle_data& <b> operator=</b>(const T2&
+that) const</font></td>
+ <td>Assign from an object that is a model of rectangle.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T2><b> <br />
+ </b>bool<b> operator==</b>(const T2& that) const</font></td>
+ <td>Compare equality to an object that is a model of
+rectangle.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T2><b> <br />
+ </b>bool<b> operator!=</b>(const T2& that) const</font></td>
+ <td>Compare inequality to an object that is a model of
+rectangle.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">interval_data<T>
+ <b>get</b>(orientation_2d orient) const</font></td>
+ <td>Get the interval in the given orientation.</td>
+ </tr>
+ <tr>
+ <td width="586"><font face="Courier New">template
+<typename T2><br />
+void <b>set</b>(orientation_2d orient, const T2& value)</font></td>
+ <td>Sets the interval in the given orientation to the value
+of an object that models interval.</td>
+ </tr>
+ </tbody>
+ </table>
+ </td>
+ </tr>
<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 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="table8" 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: trunk/libs/polygon/doc/gtl_segment_concept.htm
==============================================================================
--- trunk/libs/polygon/doc/gtl_segment_concept.htm (original)
+++ trunk/libs/polygon/doc/gtl_segment_concept.htm 2013-04-07 19:23:46 EDT (Sun, 07 Apr 2013)
@@ -1,36 +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" 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: Segment 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">
-
+-->
+ <title>Boost Polygon Library: Segment 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>
+ <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>
@@ -71,12 +63,7 @@
<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>
-
+ <li>Voronoi Diagram</li>
</ul>
<h3 class="navbar">Other Resources</h3>
<ul>
@@ -92,9 +79,14 @@
</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>
+ <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 />
+ <td
+ style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;"
+ valign="top" width="100%"><!-- End Header --><br />
<p> </p>
<h1>Segment Concept</h1>
<p> </p>
@@ -103,14 +95,15 @@
concept, specialize the geometry concept meta-function for that
type. In the example below CSegment is registered as a model of
the segment concept.</p>
- <p style="font-family: Courier New,Courier,monospace;"> template <><br />
-
+ <p style="font-family: Courier New,Courier,monospace;"> template
+<><br />
struct geometry_concept<CSegment>
{ typedef segment_concept type; };</p>
<p> The semantic of a segment is
that it has a low and high point. A
std::pair<Point, Point>,
-boost::tuple<Point, Point> or boost::array<Point, 2> could all be made models of
+boost::tuple<Point, Point> or boost::array<Point, 2> could
+all be made models of
segment by simply providing indirect access to their elements through
traits, however, these objects cannot be made a model of both segment
and rectangle in the same compilation unit, for obvious reason that
@@ -120,92 +113,155 @@
<p> Below is shown the default
segment traits. Specialization of these traits is required for
types that don't conform to the default behavior.</p>
-
-
- <p><span style="font-family: Courier New,Courier,monospace;"><span style="font-family: Courier New,Courier,monospace;">template <typename Segment></span><br style="font-family: Courier New,Courier,monospace;" />
- <span style="font-family: Courier New,Courier,monospace;">struct segment_traits {</span><br style="font-family: Courier New,Courier,monospace;" />
- <span style="font-family: Courier New,Courier,monospace;"> typedef typename Segment::coordinate_type coordinate_type;</span><br style="font-family: Courier New,Courier,monospace;" />
- <span style="font-family: Courier New,Courier,monospace;"> typedef typename Segment::point_type point_type;</span><br style="font-family: Courier New,Courier,monospace;" />
+ <p><span style="font-family: Courier New,Courier,monospace;"><span
+ style="font-family: Courier New,Courier,monospace;">template
+<typename Segment></span><br
+ style="font-family: Courier New,Courier,monospace;" />
+ <span style="font-family: Courier New,Courier,monospace;">struct
+segment_traits {</span><br
+ style="font-family: Courier New,Courier,monospace;" />
+ <span style="font-family: Courier New,Courier,monospace;">
+typedef typename Segment::coordinate_type coordinate_type;</span><br
+ style="font-family: Courier New,Courier,monospace;" />
+ <span style="font-family: Courier New,Courier,monospace;">
+typedef typename Segment::point_type point_type;</span><br
+ style="font-family: Courier New,Courier,monospace;" />
<br style="font-family: Courier New,Courier,monospace;" />
- <span style="font-family: Courier New,Courier,monospace;"> static inline point_type get(const Segment& segment, direction_1d dir) {</span><br style="font-family: Courier New,Courier,monospace;" />
- <span style="font-family: Courier New,Courier,monospace;"> return segment.get(dir);</span><br style="font-family: Courier New,Courier,monospace;" />
- <span style="font-family: Courier New,Courier,monospace;"> }</span><br style="font-family: Courier New,Courier,monospace;" />
+ <span style="font-family: Courier New,Courier,monospace;">
+static inline point_type get(const Segment& segment, direction_1d
+dir) {</span><br style="font-family: Courier New,Courier,monospace;" />
+ <span style="font-family: Courier New,Courier,monospace;">
+return segment.get(dir);</span><br
+ style="font-family: Courier New,Courier,monospace;" />
+ <span style="font-family: Courier New,Courier,monospace;"> }</span><br
+ style="font-family: Courier New,Courier,monospace;" />
<span style="font-family: Courier New,Courier,monospace;">};</span><br />
- <br /><span style="font-family: Courier New,Courier,monospace;">template <typename Segment><br />
+ <br />
+ <span style="font-family: Courier New,Courier,monospace;">template
+<typename Segment><br />
struct segment_mutable_traits {<br />
- </span></span><span style="font-family: Courier New,Courier,monospace;"><span style="font-family: Courier New,Courier,monospace;">typedef typename segment_traits<Segment>::coordinate_type </span></span><span style="font-family: Courier New,Courier,monospace;"><span style="font-family: Courier New,Courier,monospace;">coordinate_type;</span></span><br />
- <span style="font-family: Courier New,Courier,monospace;"><span style="font-family: Courier New,Courier,monospace;">
- typedef typename segment_traits<Segment>::point_type point_type;<br />
-<br />
- static inline void set(Segment& segment, direction_1d dir, const point_type& point) {<br />
+ </span></span><span
+ style="font-family: Courier New,Courier,monospace;"><span
+ style="font-family: Courier New,Courier,monospace;">typedef typename
+segment_traits<Segment>::coordinate_type </span></span><span
+ style="font-family: Courier New,Courier,monospace;"><span
+ style="font-family: Courier New,Courier,monospace;">coordinate_type;</span></span><br />
+ <span style="font-family: Courier New,Courier,monospace;"><span
+ style="font-family: Courier New,Courier,monospace;"> typedef
+typename segment_traits<Segment>::point_type point_type;<br />
+ <br />
+ static inline void set(Segment& segment, direction_1d dir,
+const point_type& point) {<br />
segment.set(dir, p);<br />
}<br />
<br />
- static inline Segment construct(const point_type& low, const point_type& high) {<br />
+ static inline Segment construct(const point_type& low, const
+point_type& high) {<br />
return Segment(low, high);<br />
}<br />
-};</span></span></p><h2>Functions</h2>
+};</span></span></p>
+ <h2>Functions</h2>
<table style="width: 100%;" id="table1" border="1">
<tbody>
<tr>
<td width="586"><font face="Courier New">template
-<typename Segment><br />point_type <b>get</b>(const Segment& segment, direction_1d dir)</font></td>
- <td>Returns the low or high endpoint of an object that models segment, depending on
+<typename Segment><br />
+point_type <b>get</b>(const Segment& segment, direction_1d dir)</font></td>
+ <td>Returns the low or high endpoint of an object that
+models segment, depending on
the direction_1d value.<font face="Courier New"> </font></td>
</tr>
<tr>
<td width="586"><font face="Courier New">template
-<typename </font><font face="Courier New">Segment</font><font face="Courier New">, typename Point><br />
-void <b>set</b>(</font><font face="Courier New">Segment</font><font face="Courier New">& segment, direction_1d dir,<br />
- const Point& </font><span style="font-family: Courier New;">point</span><font face="Courier New">)</font></td>
+<typename </font><font face="Courier New">Segment</font><font
+ face="Courier New">, typename Point><br />
+void <b>set</b>(</font><font face="Courier New">Segment</font><font
+ face="Courier New">& segment, direction_1d dir,<br />
+ const Point& </font><span
+ style="font-family: Courier New;">point</span><font face="Courier New">)</font></td>
<td>Sets
the low or high endpoint of an object that models segment to an object
that models point, depending on the direction_1d value.</td>
</tr>
<tr>
- <td width="586"><font face="Courier New">template <typename Segment, typename Point1, typename Point2><br />
+ <td width="586"><font face="Courier New">template
+<typename Segment, typename Point1, typename Point2><br />
Segment<b> construct</b>(const Point1& low, const Point2& high)</font></td>
- <td>Constructs an object that is a model of segment given the two objects that are models of point.</td>
+ <td>Constructs an object that is a model of segment given
+the two objects that are models of point.</td>
</tr>
<tr>
- <td><font face="Courier New">template <typename Segment1, typename </font><font face="Courier New">Segment2</font><font face="Courier New">><br /></font><font face="Courier New">Segment1</font><font face="Courier New"> <span style="font-weight: bold;">copy_construct</span>(const </font><font face="Courier New">Segment2</font><font face="Courier New">& segment)</font></td>
- <td style="text-align: left;">Copy constructs an object that models segment given another segment.</td>
+ <td><font face="Courier New">template <typename
+Segment1, typename </font><font face="Courier New">Segment2</font><font
+ face="Courier New">><br />
+ </font><font face="Courier New">Segment1</font><font
+ face="Courier New"> <span style="font-weight: bold;">copy_construct</span>(const
+ </font><font face="Courier New">Segment2</font><font
+ face="Courier New">& segment)</font></td>
+ <td style="text-align: left;">Copy constructs an object
+that models segment given another segment.</td>
</tr>
-<tr>
+ <tr>
<td width="586"><font face="Courier New">template
-<typename </font><font face="Courier New">Segment1</font><font face="Courier New">, typename </font><font face="Courier New">Segment2></font><br />
- <font face="Courier New">Segment1</font><font face="Courier New">& <b>assign</b>(</font><font face="Courier New">Segment1</font><font face="Courier New">& segment1,<br />
- const </font><font face="Courier New">Segment2</font><font face="Courier New">& segment2)</font></td>
- <td>Copies data from the second object that models segment into
+<typename </font><font face="Courier New">Segment1</font><font
+ face="Courier New">, typename </font><font face="Courier New">Segment2></font><br />
+ <font face="Courier New">Segment1</font><font
+ face="Courier New">& <b>assign</b>(</font><font face="Courier New">Segment1</font><font
+ face="Courier New">& segment1,<br />
+
+const </font><font face="Courier New">Segment2</font><font
+ face="Courier New">& segment2)</font></td>
+ <td>Copies data from the second object that models segment
+into
the first object that models segment.</td>
</tr>
<tr>
<td width="586"><font face="Courier New">template
-<typename </font><font face="Courier New">Segment1</font><font face="Courier New">, typename </font><font face="Courier New">Segment1</font><font face="Courier New">><br />
-bool <b>equivalence</b>(const </font><font face="Courier New">Segment1</font><font face="Courier New">& segment1,<br />
- const </font><font face="Courier New">Segment1</font><font face="Courier New">& segment2)</font></td>
+<typename </font><font face="Courier New">Segment1</font><font
+ face="Courier New">, typename </font><font face="Courier New">Segment1</font><font
+ face="Courier New">><br />
+bool <b>equivalence</b>(const </font><font face="Courier New">Segment1</font><font
+ face="Courier New">& segment1,<br />
+
+const </font><font face="Courier New">Segment1</font><font
+ face="Courier New">& segment2)</font></td>
<td>Given two objects that model segment, compares and
returns true if their low and high values are respectively equal.</td>
</tr>
<tr>
- <td><span style="font-family: Courier New,Courier,monospace;">template <typename Segment, typename Point></span><br style="font-family: Courier New,Courier,monospace;" />
- <span style="font-family: Courier New,Courier,monospace;">int <b>orientation</b></span><span style="font-family: Courier New,Courier,monospace;">(const </span><span style="font-family: Courier New,Courier,monospace;">Segment</span><span style="font-family: Courier New,Courier,monospace;">& segment,</span><br style="font-family: Courier New,Courier,monospace;" />
- <span style="font-family: Courier New,Courier,monospace;"> const Point& point)</span><br />
+ <td><span
+ style="font-family: Courier New,Courier,monospace;">template
+<typename Segment, typename Point></span><br
+ style="font-family: Courier New,Courier,monospace;" />
+ <span style="font-family: Courier New,Courier,monospace;">int
+ <b>orientation</b></span><span
+ style="font-family: Courier New,Courier,monospace;">(const </span><span
+ style="font-family: Courier New,Courier,monospace;">Segment</span><span
+ style="font-family: Courier New,Courier,monospace;">& segment,</span><br
+ style="font-family: Courier New,Courier,monospace;" />
+ <span style="font-family: Courier New,Courier,monospace;">
+const Point& point)</span><br />
</td>
<td>Implements
a robust orientation test of two objects that model segment and point.
Returns 0, if the point is collinear to the segment.<br />
Returns 1, if the point lies to the left of the segment.<br />
Returns -1, if the point lies to the right of the segment.<br />
-
</td>
</tr>
<tr>
- <td><span style="font-family: Courier New,Courier,monospace;">template <typename Segment1, typename Segment2></span><br style="font-family: Courier New,Courier,monospace;" />
-
- <span style="font-family: Courier New,Courier,monospace;">int <b>orientation</b></span><span style="font-family: Courier New,Courier,monospace;">(const </span><span style="font-family: Courier New,Courier,monospace;">Segment1</span><span style="font-family: Courier New,Courier,monospace;">& segment1,</span><br style="font-family: Courier New,Courier,monospace;" />
-
- <span style="font-family: Courier New,Courier,monospace;"> const Segment2& segment2)</span></td>
+ <td><span
+ style="font-family: Courier New,Courier,monospace;">template
+<typename Segment1, typename Segment2></span><br
+ style="font-family: Courier New,Courier,monospace;" />
+ <span style="font-family: Courier New,Courier,monospace;">int
+ <b>orientation</b></span><span
+ style="font-family: Courier New,Courier,monospace;">(const </span><span
+ style="font-family: Courier New,Courier,monospace;">Segment1</span><span
+ style="font-family: Courier New,Courier,monospace;">& segment1,</span><br
+ style="font-family: Courier New,Courier,monospace;" />
+ <span style="font-family: Courier New,Courier,monospace;">
+const Segment2& segment2)</span></td>
<td>Implements a robust orientation test of two objects
that model segment. Note: segments are treated as math.
vectors.<br />
@@ -214,174 +270,295 @@
Returns -1, if the second segment is CW oriented to the first segment.<br />
</td>
</tr>
-<tr>
- <td><span style="font-family: Courier New,Courier,monospace;">template <typename </span><font face="Courier New">Segment, typename Point</font><span style="font-family: Courier New,Courier,monospace;">></span><br style="font-family: Courier New,Courier,monospace;" />
- <span style="font-family: Courier New,Courier,monospace;">bool </span><span style="font-weight: bold; font-family: Courier New,Courier,monospace;">contains</span><span style="font-family: Courier New,Courier,monospace;">(const </span><font face="Courier New">Segment</font><span style="font-family: Courier New,Courier,monospace;">& segment,</span><br style="font-family: Courier New,Courier,monospace;" />
- <span style="font-family: Courier New,Courier,monospace;"> const Point& value,</span><span style="font-family: Courier New,Courier,monospace;"> bool consider_touch)</span><br />
- </td>
- <td>Returns true if an object that models segment contains an object that models point, else false.<br />
- </td>
- </tr>
- <tr>
- <td><span style="font-family: Courier New,Courier,monospace;">template <typename Segment1, typename Segment2></span><br style="font-family: Courier New,Courier,monospace;" />
-
- <span style="font-family: Courier New,Courier,monospace;">bool </span><span style="font-weight: bold; font-family: Courier New,Courier,monospace;">contains</span><span style="font-family: Courier New,Courier,monospace;">(const </span><span style="font-family: Courier New,Courier,monospace;">Segment1</span><span style="font-family: Courier New,Courier,monospace;">& segment1,</span><br style="font-family: Courier New,Courier,monospace;" />
-
- <span style="font-family: Courier New,Courier,monospace;"> const </span><span style="font-family: Courier New,Courier,monospace;">Segment</span><span style="font-family: Courier New,Courier,monospace;">2& segment2,</span> <span style="font-family: Courier New,Courier,monospace;">bool consider_touch)</span></td>
- <td>Returns true if the first object contains the second one, else false. Both objects model segment.<br />
- </td>
- </tr>
- <tr>
- <td style="font-family: Courier New,Courier,monospace;">template <typename <span style="font-family: Courier New,Courier,monospace;">Segment</span>><br />
-point_type <span style="font-weight: bold;">low</span>(const <span style="font-family: Courier New,Courier,monospace;">Segment</span>& segment)<br />
- </td>
- <td>Returns the low endpoint of an object that models segment.<br />
- </td>
- </tr>
- <tr>
- <td style="font-family: Courier New,Courier,monospace;">template <typename <span style="font-family: Courier New,Courier,monospace;">Segment</span>><br />
-point_type <span style="font-weight: bold;">high</span>(const <span style="font-family: Courier New,Courier,monospace;">Segment</span>& segment)</td>
- <td>Returns the high endpoint of an object that models segment.<br />
- </td>
- </tr>
- <tr>
- <td style="font-family: Courier New,Courier,monospace;">template <typename <span style="font-family: Courier New,Courier,monospace;">Segment</span>><br />
-point_type <span style="font-weight: bold;">center</span>(const <span style="font-family: Courier New,Courier,monospace;">Segment</span>& segment)</td>
- <td>Returns the central point of an object that models segment.<br />
- </td>
- </tr>
<tr>
- <td style="font-family: Courier New,Courier,monospace;">template <typename <span style="font-family: Courier New,Courier,monospace;">Segment</span>, typename Point><br />void <span style="font-weight: bold;">low</span>(<span style="font-family: Courier New,Courier,monospace;">Segment</span>& segment, const Point& point)</td>
+ <td><span
+ style="font-family: Courier New,Courier,monospace;">template
+<typename </span><font face="Courier New">Segment, typename Point</font><span
+ style="font-family: Courier New,Courier,monospace;">></span><br
+ style="font-family: Courier New,Courier,monospace;" />
+ <span style="font-family: Courier New,Courier,monospace;">bool
+ </span><span
+ style="font-weight: bold; font-family: Courier New,Courier,monospace;">contains</span><span
+ style="font-family: Courier New,Courier,monospace;">(const </span><font
+ face="Courier New">Segment</font><span
+ style="font-family: Courier New,Courier,monospace;">& segment,</span><br
+ style="font-family: Courier New,Courier,monospace;" />
+ <span style="font-family: Courier New,Courier,monospace;">
+const Point& value,</span><span
+ style="font-family: Courier New,Courier,monospace;"> bool
+consider_touch)</span><br />
+ </td>
+ <td>Returns true if an object that models segment contains
+an object that models point, else false.<br />
+ </td>
+ </tr>
+ <tr>
+ <td><span
+ style="font-family: Courier New,Courier,monospace;">template
+<typename Segment1, typename Segment2></span><br
+ style="font-family: Courier New,Courier,monospace;" />
+ <span style="font-family: Courier New,Courier,monospace;">bool
+ </span><span
+ style="font-weight: bold; font-family: Courier New,Courier,monospace;">contains</span><span
+ style="font-family: Courier New,Courier,monospace;">(const </span><span
+ style="font-family: Courier New,Courier,monospace;">Segment1</span><span
+ style="font-family: Courier New,Courier,monospace;">& segment1,</span><br
+ style="font-family: Courier New,Courier,monospace;" />
+ <span style="font-family: Courier New,Courier,monospace;">
+const </span><span style="font-family: Courier New,Courier,monospace;">Segment</span><span
+ style="font-family: Courier New,Courier,monospace;">2& segment2,</span>
+ <span style="font-family: Courier New,Courier,monospace;">bool
+consider_touch)</span></td>
+ <td>Returns true if the first object contains the second
+one, else false. Both objects model segment.<br />
+ </td>
+ </tr>
+ <tr>
+ <td style="font-family: Courier New,Courier,monospace;">template
+<typename <span style="font-family: Courier New,Courier,monospace;">Segment</span>><br />
+point_type <span style="font-weight: bold;">low</span>(const <span
+ style="font-family: Courier New,Courier,monospace;">Segment</span>&
+segment)<br />
+ </td>
+ <td>Returns the low endpoint of an object that models
+segment.<br />
+ </td>
+ </tr>
+ <tr>
+ <td style="font-family: Courier New,Courier,monospace;">template
+<typename <span style="font-family: Courier New,Courier,monospace;">Segment</span>><br />
+point_type <span style="font-weight: bold;">high</span>(const <span
+ style="font-family: Courier New,Courier,monospace;">Segment</span>&
+segment)</td>
+ <td>Returns the high endpoint of an object that models
+segment.<br />
+ </td>
+ </tr>
+ <tr>
+ <td style="font-family: Courier New,Courier,monospace;">template
+<typename <span style="font-family: Courier New,Courier,monospace;">Segment</span>><br />
+point_type <span style="font-weight: bold;">center</span>(const <span
+ style="font-family: Courier New,Courier,monospace;">Segment</span>&
+segment)</td>
+ <td>Returns the central point of an object that models
+segment.<br />
+ </td>
+ </tr>
+ <tr>
+ <td style="font-family: Courier New,Courier,monospace;">template
+<typename <span style="font-family: Courier New,Courier,monospace;">Segment</span>,
+typename Point><br />
+void <span style="font-weight: bold;">low</span>(<span
+ style="font-family: Courier New,Courier,monospace;">Segment</span>&
+segment, const Point& point)</td>
<td>Sets the low endpoint of an object that models segment.<br />
</td>
</tr>
<tr>
- <td style="font-family: Courier New,Courier,monospace;">template <typename <span style="font-family: Courier New,Courier,monospace;">Segment, typename Point</span>><br />
-void <span style="font-weight: bold;">high</span>(<span style="font-family: Courier New,Courier,monospace;">Segment</span>& segment, const Point& point)</td>
- <td>Sets the high endpoint of an object that models of segment.<br />
+ <td style="font-family: Courier New,Courier,monospace;">template
+<typename <span style="font-family: Courier New,Courier,monospace;">Segment,
+typename Point</span>><br />
+void <span style="font-weight: bold;">high</span>(<span
+ style="font-family: Courier New,Courier,monospace;">Segment</span>&
+segment, const Point& point)</td>
+ <td>Sets the high endpoint of an object that models of
+segment.<br />
</td>
</tr>
<tr>
- <td><span style="font-family: Courier New,Courier,monospace;">template <typename </span><span style="font-family: Courier New,Courier,monospace;">Segment</span><span style="font-family: Courier New,Courier,monospace;">></span><br style="font-family: Courier New,Courier,monospace;" />
- <span style="font-family: Courier New,Courier,monospace;">distance_type <span style="font-weight: bold;">length</span>(const </span><span style="font-family: Courier New,Courier,monospace;">Segment</span><span style="font-family: Courier New,Courier,monospace;">& segment)</span><br />
+ <td><span
+ style="font-family: Courier New,Courier,monospace;">template
+<typename </span><span
+ style="font-family: Courier New,Courier,monospace;">Segment</span><span
+ style="font-family: Courier New,Courier,monospace;">></span><br
+ style="font-family: Courier New,Courier,monospace;" />
+ <span style="font-family: Courier New,Courier,monospace;">distance_type
+ <span style="font-weight: bold;">length</span>(const </span><span
+ style="font-family: Courier New,Courier,monospace;">Segment</span><span
+ style="font-family: Courier New,Courier,monospace;">& segment)</span><br />
</td>
<td>Returns length of an object that models segment.<br />
</td>
</tr>
-
-
-
-
<tr>
<td width="586"><font face="Courier New">template
-<typename </font><span style="font-family: Courier New,Courier,monospace;">Segment</span><font face="Courier New">><br /></font><span style="font-family: Courier New,Courier,monospace;">Segment</span><font face="Courier New">& <b>scale_up</b>(</font><span style="font-family: Courier New,Courier,monospace;">Segment</span><font face="Courier New">& </font><font face="Courier New">segment</font><font face="Courier New">, <br /> unsigned_area_type factor)</font></td>
- <td>Multiplies x and y coordinates of both endpoints of an object that models segment by unsigned factor.</td>
+<typename </font><span
+ style="font-family: Courier New,Courier,monospace;">Segment</span><font
+ face="Courier New">><br />
+ </font><span
+ style="font-family: Courier New,Courier,monospace;">Segment</span><font
+ face="Courier New">& <b>scale_up</b>(</font><span
+ style="font-family: Courier New,Courier,monospace;">Segment</span><font
+ face="Courier New">& </font><font face="Courier New">segment</font><font
+ face="Courier New">, <br />
+ unsigned_area_type factor)</font></td>
+ <td>Multiplies x and y coordinates of both endpoints of an
+object that models segment by unsigned factor.</td>
</tr>
<tr>
<td width="586"><font face="Courier New">template
-<typename </font><span style="font-family: Courier New,Courier,monospace;">Segment</span><font face="Courier New">><br />
- </font><span style="font-family: Courier New,Courier,monospace;">Segment</span><font face="Courier New">& <b>scale_down</b>(</font><span style="font-family: Courier New,Courier,monospace;">Segment</span><font face="Courier New">& </font><font face="Courier New">segment</font><font face="Courier New">, <br />
+<typename </font><span
+ style="font-family: Courier New,Courier,monospace;">Segment</span><font
+ face="Courier New">><br />
+ </font><span
+ style="font-family: Courier New,Courier,monospace;">Segment</span><font
+ face="Courier New">& <b>scale_down</b>(</font><span
+ style="font-family: Courier New,Courier,monospace;">Segment</span><font
+ face="Courier New">& </font><font face="Courier New">segment</font><font
+ face="Courier New">, <br />
unsigned_area_type factor)</font></td>
- <td>Divides x and y coordinates of both endpoints of an object that models segment by unsigned factor.</td>
+ <td>Divides x and y coordinates of both endpoints of an
+object that models segment by unsigned factor.</td>
</tr>
<tr>
<td width="586"><font face="Courier New">template
-<typename </font><span style="font-family: Courier New,Courier,monospace;">Segment</span><font face="Courier New">, typename Scale><br />
- </font><span style="font-family: Courier New,Courier,monospace;">Segment</span><font face="Courier New">& <b>scale</b>(</font><span style="font-family: Courier New,Courier,monospace;">Segment</span><font face="Courier New">& </font><font face="Courier New">segment</font><font face="Courier New">, const Scale& sc) </font></td>
+<typename </font><span
+ style="font-family: Courier New,Courier,monospace;">Segment</span><font
+ face="Courier New">, typename Scale><br />
+ </font><span
+ style="font-family: Courier New,Courier,monospace;">Segment</span><font
+ face="Courier New">& <b>scale</b>(</font><span
+ style="font-family: Courier New,Courier,monospace;">Segment</span><font
+ face="Courier New">& </font><font face="Courier New">segment</font><font
+ face="Courier New">, const Scale& sc) </font></td>
<td>Calls
-the scale member function of the scaling type on the low and high endpoint of
+the scale member function of the scaling type on the low and high
+endpoint of
an object that models segment and updates the segment with the
scaled endpoints.</td>
</tr>
<tr>
<td width="586"><font face="Courier New">template
-<typename </font><span style="font-family: Courier New,Courier,monospace;">Segment</span><font face="Courier New">, typename Transform><br /></font><span style="font-family: Courier New,Courier,monospace;">Segment</span><font face="Courier New">& <b>transform</b>(</font><span style="font-family: Courier New,Courier,monospace;">Segment</span><font face="Courier New">& segment, const </font><font face="Courier New">Transform</font><font face="Courier New">& tr) </font></td>
+<typename </font><span
+ style="font-family: Courier New,Courier,monospace;">Segment</span><font
+ face="Courier New">, typename Transform><br />
+ </font><span
+ style="font-family: Courier New,Courier,monospace;">Segment</span><font
+ face="Courier New">& <b>transform</b>(</font><span
+ style="font-family: Courier New,Courier,monospace;">Segment</span><font
+ face="Courier New">& segment, const </font><font
+ face="Courier New">Transform</font><font face="Courier New">& tr) </font></td>
<td>Calls the transform member function of transform type
-on the low and high endpoints of an object that models segment and updates the segment with the transformed endpoints.</td>
+on the low and high endpoints of an object that models segment and
+updates the segment with the transformed endpoints.</td>
</tr>
<tr>
<td width="586"><font face="Courier New">template
-<typename </font><span style="font-family: Courier New,Courier,monospace;">Segment</span><font face="Courier New">><br />
- </font><span style="font-family: Courier New,Courier,monospace;">Segment</span><font face="Courier New">& <b>move</b>(</font><span style="font-family: Courier New,Courier,monospace;">Segment</span><font face="Courier New">& segment, orientation_2d<br />
+<typename </font><span
+ style="font-family: Courier New,Courier,monospace;">Segment</span><font
+ face="Courier New">><br />
+ </font><span
+ style="font-family: Courier New,Courier,monospace;">Segment</span><font
+ face="Courier New">& <b>move</b>(</font><span
+ style="font-family: Courier New,Courier,monospace;">Segment</span><font
+ face="Courier New">& segment, orientation_2d<br />
coordinate_difference displacement)</font></td>
- <td>Adds displacement value to the x or y coordinates of both endpoints of an object
+ <td>Adds displacement value to the x or y coordinates of
+both endpoints of an object
that models segment indicated by the orientation_2d.</td>
</tr>
<tr>
<td width="586"><font face="Courier New">template
-<</font><span style="font-family: Courier New,Courier,monospace;">Segment, Point</span><font face="Courier New">><br />
- </font><span style="font-family: Courier New,Courier,monospace;">Segment</span><font face="Courier New">& <b>convolve</b>(</font><span style="font-family: Courier New,Courier,monospace;">Segment</span><font face="Courier New">& segment, const Point& point)</font></td>
- <td>Convolves both endpoints of an object that models segment with an object that models a point.<br />
-</td>
+<</font><span style="font-family: Courier New,Courier,monospace;">Segment,
+Point</span><font face="Courier New">><br />
+ </font><span
+ style="font-family: Courier New,Courier,monospace;">Segment</span><font
+ face="Courier New">& <b>convolve</b>(</font><span
+ style="font-family: Courier New,Courier,monospace;">Segment</span><font
+ face="Courier New">& segment, const Point& point)</font></td>
+ <td>Convolves both endpoints of an object that models
+segment with an object that models a point.<br />
+ </td>
</tr>
<tr>
<td width="586"><font face="Courier New">template
-<</font><span style="font-family: Courier New,Courier,monospace;">Segment, Point</span><font face="Courier New">><br />
- </font><span style="font-family: Courier New,Courier,monospace;">Segment</span><font face="Courier New">& <b>deconvolve</b>(</font><span style="font-family: Courier New,Courier,monospace;">Segment</span><font face="Courier New">& segment, const Point& point)</font></td>
- <td>Deconvolves both endpoints of an object that models segment with an object that models a point. </td>
- </tr>
- <tr>
- <td style="font-family: Courier New,Courier,monospace;">template <typename Segment1, typename Segment2><br />
-
-
-bool <span style="font-weight: bold;">abuts</span>(const Segment1& segment1,<br />
-
-
+<</font><span style="font-family: Courier New,Courier,monospace;">Segment,
+Point</span><font face="Courier New">><br />
+ </font><span
+ style="font-family: Courier New,Courier,monospace;">Segment</span><font
+ face="Courier New">& <b>deconvolve</b>(</font><span
+ style="font-family: Courier New,Courier,monospace;">Segment</span><font
+ face="Courier New">& segment, const Point& point)</font></td>
+ <td>Deconvolves both endpoints of an object that models
+segment with an object that models a point. </td>
+ </tr>
+ <tr>
+ <td style="font-family: Courier New,Courier,monospace;">template
+<typename Segment1, typename Segment2><br />
+bool <span style="font-weight: bold;">abuts</span>(const Segment1&
+segment1,<br />
const Segment2& segment2, direction_1d dir)</td>
- <td>Returns true if two objects that model segment abut, depending on the direction_1d value.</td>
- </tr>
- <tr>
- <td style="font-family: Courier New,Courier,monospace;">template <typename Segment1, typename Segment2><br />
-
-bool <span style="font-weight: bold;">abuts</span>(const Segment1& segment1,<br />
-
- const Segment2& segment2)</td>
- <td>Returns true if two objects that model segment abut: either the first one to the second one or vice versa.</td>
+ <td>Returns true if two objects that model segment abut,
+depending on the direction_1d value.</td>
</tr>
-
-
<tr>
- <td><span style="font-family: Courier New,Courier,monospace;">template <typename Segment1, typename Segment2></span><br style="font-family: Courier New,Courier,monospace;" />
- <span style="font-family: Courier New,Courier,monospace;">bool <span style="font-weight: bold;">intersects</span>(const Segment1& segment1,</span><br style="font-family: Courier New,Courier,monospace;" />
- <span style="font-family: Courier New,Courier,monospace;"> const Segment2& segment2,<br />
- bool consider_touch)</span><br />
- </td>
- <td>Returns true if two objects that model segment intersect, else false.<br />
+ <td style="font-family: Courier New,Courier,monospace;">template
+<typename Segment1, typename Segment2><br />
+bool <span style="font-weight: bold;">abuts</span>(const Segment1&
+segment1,<br />
+ const
+Segment2& segment2)</td>
+ <td>Returns true if two objects that model segment abut:
+either the first one to the second one or vice versa.</td>
+ </tr>
+ <tr>
+ <td><span
+ style="font-family: Courier New,Courier,monospace;">template
+<typename Segment1, typename Segment2></span><br
+ style="font-family: Courier New,Courier,monospace;" />
+ <span style="font-family: Courier New,Courier,monospace;">bool
+ <span style="font-weight: bold;">intersects</span>(const
+Segment1& segment1,</span><br
+ style="font-family: Courier New,Courier,monospace;" />
+ <span style="font-family: Courier New,Courier,monospace;">
+const Segment2& segment2,<br />
+
+bool consider_touch)</span><br />
+ </td>
+ <td>Returns true if two objects that model segment
+intersect, else false.<br />
</td>
</tr>
-
-
-<tr>
- <td style="font-family: Courier New,Courier,monospace;"><font face="Courier New">template
-<typename </font><span style="font-family: Courier New,Courier,monospace;">Segment, typename Point</span><font face="Courier New">><br />distance_type <b>euclidean_distance</b>(<br />
- const </font><span style="font-family: Courier New,Courier,monospace;">Segment</span><font face="Courier New">& segment, const Point& point)</font>
- </td>
+ <tr>
+ <td style="font-family: Courier New,Courier,monospace;"><font
+ face="Courier New">template
+<typename </font><span
+ style="font-family: Courier New,Courier,monospace;">Segment, typename
+Point</span><font face="Courier New">><br />
+distance_type <b>euclidean_distance</b>(<br />
+ const </font><span
+ style="font-family: Courier New,Courier,monospace;">Segment</span><font
+ face="Courier New">& segment, const Point& point)</font> </td>
<td>Returns distance from an object that models segment
-to an object that models point.
- </td>
+to an object that models point. </td>
</tr>
<tr>
- <td style="font-family: Courier New,Courier,monospace;"><font face="Courier New">template
-<typename Segment1, typename </font><font face="Courier New">Segment2</font><font face="Courier New">><br />distance_type <b>euclidean_distance</b>(<br />
- const </font><font face="Courier New">Segment1</font><font face="Courier New">& segment1, const </font><font face="Courier New">Segment2</font><font face="Courier New">& segment2)</font>
- </td>
- <td>Returns distance between two objects that model segment.
- </td>
+ <td style="font-family: Courier New,Courier,monospace;"><font
+ face="Courier New">template
+<typename Segment1, typename </font><font face="Courier New">Segment2</font><font
+ face="Courier New">><br />
+distance_type <b>euclidean_distance</b>(<br />
+ const </font><font face="Courier New">Segment1</font><font
+ face="Courier New">& segment1, const </font><font
+ face="Courier New">Segment2</font><font face="Courier New">&
+segment2)</font> </td>
+ <td>Returns distance between two objects that model
+segment. </td>
</tr>
-
-
-
-
</tbody>
</table>
<h1>Segment Data</h1>
<p> </p>
- <p>The library provides a model of the segment concept declared <font face="Courier New">template<typename T> segment_data</font>, where
+ <p>The library provides a model of the segment concept declared <font
+ face="Courier New">template<typename T> segment_data</font>,
+where
T is the coordinate type.</p>
<p>This data type is used internally when a segment is needed and
is available to the library user, who finds it convenient to use a
-library segment 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>
+library segment 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 style="width: 100%;" id="table2" border="1">
<tbody>
<tr>
@@ -397,124 +574,152 @@
<td>point_data<T><br />
</td>
</tr>
-<tr>
+ <tr>
<td width="586"><font face="Courier New"><b>segment_data</b>()</font></td>
<td>Default constructor.</td>
</tr>
<tr>
- <td width="586"><font face="Courier New"><b>segment_data</b>(const point_type& low,<br />
- const point_type& high)</font></td>
+ <td width="586"><font face="Courier New"><b>segment_data</b>(const
+point_type& low,<br />
+
+const point_type& high)</font></td>
<td>Constructs a segment from the given endpoints.</td>
</tr>
<tr>
- <td width="586"><font face="Courier New"><b>segment_data</b>(const segment_data& that)</font></td>
+ <td width="586"><font face="Courier New"><b>segment_data</b>(const
+segment_data& that)</font></td>
<td>Copy constructor.</td>
</tr>
<tr>
- <td width="586"><font face="Courier New">segment_data& <b>operator=</b>(const segment_data& that)</font></td>
+ <td width="586"><font face="Courier New">segment_data& <b>operator=</b>(const
+segment_data& that)</font></td>
<td>Assignment operator.</td>
</tr>
<tr>
<td width="586"><font face="Courier New">template
<typename SegmentType><b><br />
- </b>segment_data& <b>operator=</b>(const </font><font face="Courier New">SegmentType</font><font face="Courier New">& that)
+ </b>segment_data& <b>operator=</b>(const </font><font
+ face="Courier New">SegmentType</font><font face="Courier New">&
+that)
const</font></td>
<td>Assign from an object that is a model of segment.</td>
</tr>
<tr>
- <td width="586"><font face="Courier New">bool<b> operator==</b>(const segment_data& that) const</font></td>
+ <td width="586"><font face="Courier New">bool<b> operator==</b>(const
+segment_data& that) const</font></td>
<td>Equality operator overload.</td>
</tr>
<tr>
- <td width="586"><font face="Courier New"><b> </b>bool<b> operator!=</b>(const segment_data& that) const</font></td>
+ <td width="586"><font face="Courier New"><b> </b>bool<b>
+operator!=</b>(const segment_data& 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 segment_data& that) const</font></td>
- <td>Less operator overload. Compares low endpoints then high endpoints to break ties.<br />
-</td>
+ <td width="586"><font face="Courier New"><b> </b>bool<b>
+operator<</b>(const segment_data& that) const</font></td>
+ <td>Less operator overload. Compares low endpoints then
+high endpoints to break ties.<br />
+ </td>
</tr>
<tr>
- <td width="586"><font face="Courier New"><b> </b>bool<b> operator<=</b>(const segment_data& that) const</font></td>
- <td>Less or equal operator overload. Compares low endpoints then high endpoints to break ties.<br />
-</td>
+ <td width="586"><font face="Courier New"><b> </b>bool<b>
+operator<=</b>(const segment_data& that) const</font></td>
+ <td>Less or equal operator overload. Compares low endpoints
+then high endpoints to break ties.<br />
+ </td>
</tr>
<tr>
- <td width="586"><font face="Courier New"><b> </b>bool<b> operator></b>(const segment_data& that) const</font></td>
- <td>Greater operator overload. Compares low endpoints then high endpoints to break ties.<br />
-</td>
+ <td width="586"><font face="Courier New"><b> </b>bool<b>
+operator></b>(const segment_data& that) const</font></td>
+ <td>Greater operator overload. Compares low endpoints then
+high endpoints to break ties.<br />
+ </td>
</tr>
<tr>
- <td width="586"><font face="Courier New"><b> </b>bool<b> operator>=</b>(const segment_data& that) const</font></td>
- <td>Greater or equal operator overload. Compares low endpoints then high endpoints to break ties.<br />
-</td>
+ <td width="586"><font face="Courier New"><b> </b>bool<b>
+operator>=</b>(const segment_data& that) const</font></td>
+ <td>Greater or equal operator overload. Compares low
+endpoints then high endpoints to break ties.<br />
+ </td>
</tr>
<tr>
- <td width="586"><font face="Courier New">point_type <b>get</b>(direction_1d dir) const</font></td>
- <td>Retrieves the low/high endpoint considering direction value.</td>
+ <td width="586"><font face="Courier New">point_type <b>get</b>(direction_1d
+dir) const</font></td>
+ <td>Retrieves the low/high endpoint considering direction
+value.</td>
</tr>
<tr>
- <td width="586"><font face="Courier New">point_type <span style="font-weight: bold;">low</span>() const</font></td>
+ <td width="586"><font face="Courier New">point_type <span
+ style="font-weight: bold;">low</span>() const</font></td>
<td>Retrieves the low endpoint.</td>
</tr>
<tr>
- <td width="586"><font face="Courier New">point_type <span style="font-weight: bold;">high</span>() const</font></td>
+ <td width="586"><font face="Courier New">point_type <span
+ style="font-weight: bold;">high</span>() const</font></td>
<td>Retrieves the high endpoint.</td>
</tr>
<tr>
- <td width="586"><font face="Courier New">void <b>set</b></font><font face="Courier New">(direction_1d dir</font><font face="Courier New">, const point_type& point)</font></td>
+ <td width="586"><font face="Courier New">void <b>set</b></font><font
+ face="Courier New">(direction_1d dir</font><font face="Courier New">,
+const point_type& point)</font></td>
<td>Sets the endpoint in the given direction.</td>
</tr>
<tr>
- <td width="586"><font face="Courier New">segment_data& <span style="font-weight: bold;">low</span>(const point_type& point)</font></td>
+ <td width="586"><font face="Courier New">segment_data& <span
+ style="font-weight: bold;">low</span>(const point_type& point)</font></td>
<td>Sets the low endpoint.</td>
</tr>
<tr>
- <td width="586"><font face="Courier New">segment_data& <span style="font-weight: bold;">high(</span>const point_type& point)</font></td>
+ <td width="586"><font face="Courier New">segment_data& <span
+ style="font-weight: bold;">high(</span>const point_type& point)</font></td>
<td>Sets the high endpoint.</td>
</tr>
</tbody>
</table>
-
<h1>Segment Utils</h1>
<p> </p>
- <p>The library provides several algorithms for the manipulation of
- sets of segment data. In particular, the generalize line segment
- intersection algorithm used for polygon set operations is exposed
- through several interfaces to allow it to be used with any
- collection or sequence of objects that model the <font face="Courier New">segment_concept</font>.
- </p><h2>Functions</h2>
+ <p>The library provides several algorithms for the manipulation
+of sets of segment data. In particular, the generalize line segment
+intersection algorithm used for polygon set operations is exposed
+through several interfaces to allow it to be used with any collection
+or sequence of objects that model the <font face="Courier New">segment_concept</font>.
+ </p>
+ <h2>Functions</h2>
<table style="width: 100%;" id="table3" border="1">
<tbody>
-
-
<tr>
<td width="586"><font face="Courier New">template
-<</font><font face="Courier New">typename SegmentContainer</font><font face="Courier New">,</font><font face="Courier New"><br />
- typename SegmentIterator</font><font face="Courier New">><b><br />
+<</font><font face="Courier New">typename SegmentContainer</font><font
+ face="Courier New">,</font><font face="Courier New"><br />
+ typename
+SegmentIterator</font><font face="Courier New">><b><br />
</b>void <b>intersect_segments</b>(<br />
- </font><font face="Courier New">SegmentContainer* result,</font><br />
- <font face="Courier New">
- SegmentIterator first,<br />
- SegmentIterator last)
- </font></td>
+ </font><font face="Courier New">SegmentContainer*
+result,</font><br />
+ <font face="Courier New"> SegmentIterator
+first,<br />
+ SegmentIterator last) </font></td>
<td>Accumulates
the result of splitting the segments in the iterator range at their
intersection points into the result container. Preconditions: segment
-type used by all the input structures should model segment concept.Postconditions: no segments intersect except at their end
- points. Useful to satisfy the precondition of voronoi diagram
- construction.
- Expected n log n runtime, worst case quadratic runtime wrt. vertices + intersections.
- </td>
+type used by all the input structures should model segment
+concept.Postconditions: no segments intersect except at their end
+points. Useful to satisfy the precondition of voronoi diagram
+construction. Expected n log n runtime, worst case quadratic runtime
+wrt. vertices + intersections. </td>
</tr>
<tr>
<td width="586"><font face="Courier New">template
-<</font><font face="Courier New">typename Segment,</font><font face="Courier New"><br />
- </font><font face="Courier New">typename SegmentIterator</font><font face="Courier New">><b><br />
+<</font><font face="Courier New">typename Segment,</font><font
+ face="Courier New"><br />
+ </font><font
+ face="Courier New">typename SegmentIterator</font><font
+ face="Courier New">><b><br />
</b>void <b>intersect_segments</b>(<br />
- </font><font face="Courier New">vector<pair<size_t, Segment>* result,</font><br />
- <font face="Courier New">
- SegmentIterator first,<br />
+ </font><font face="Courier New">vector<pair<size_t,
+Segment>* result,</font><br />
+ <font face="Courier New"> SegmentIterator
+first,<br />
SegmentIterator last)</font></td>
<td>Accumulates
the result of splitting the segments in the iterator range at their
@@ -526,36 +731,36 @@
inputs segments. Expected n log n runtime, worst case quadratic runtime
wrt. vertices + intersections. </td>
</tr>
-
<tr>
<td width="586"><font face="Courier New">template
<</font><font face="Courier New">typename Rectangle,<br />
- </font><font face="Courier New">typename </font><font face="Courier New">SegmentIterator</font><font face="Courier New">><b><br />
+ </font><font
+ face="Courier New">typename </font><font face="Courier New">SegmentIterator</font><font
+ face="Courier New">><b><br />
</b>void <span style="font-weight: bold;">envelope_segments</span>(<br />
</font><font face="Courier New">Rectangle* rect,</font><br />
- <font face="Courier New">
- </font><font face="Courier New">SegmentIterator first,<br /> SegmentIterator last</font><font face="Courier New">)
- </font></td>
+ <font face="Courier New"> </font><font
+ face="Courier New">SegmentIterator first,<br />
+ SegmentIterator last</font><font face="Courier New">) </font></td>
<td>Computes
the bounding rectangle of the iterator range of line segments.
Preconditions: segment type and rectangle type used by the input
structures should model segment concept and rectangle concept
respectively. Linear runtime. </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%">
+ <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">
+ <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>
@@ -563,7 +768,10 @@
<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">
+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>
@@ -572,6 +780,5 @@
</tr>
</tbody>
</table>
-
-
-</body></html>
\ No newline at end of file
+</body>
+</html>
Modified: trunk/libs/polygon/doc/index.htm
==============================================================================
--- trunk/libs/polygon/doc/index.htm (original)
+++ trunk/libs/polygon/doc/index.htm 2013-04-07 19:23:46 EDT (Sun, 07 Apr 2013)
@@ -1,128 +1,132 @@
<!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: Main Page</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: Main Page</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 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>THE BOOST.POLYGON LIBRARY</h1>
-<p>The Boost.Polygon library provides algorithms focused on manipulating planar
-polygon geometry data. Specific algorithms provided are the polygon set
-operations (intersection, union, difference, disjoint-union) and related
-algorithms such as polygon connectivity graph extraction, offsetting and map-overlay.
-An example of the disjoint-union (XOR) of figure a and figure b is shown below
-in figure c.
-These so-called Boolean algorithms are of significant interest in GIS (Geospatial Information
-Systems), VLSI CAD as well all other fields of CAD, and many more application
-areas, and providing them is the primary focus of this library. The
-Boost.Polygon library is not intended to cover all of computational
-geometry in its scope, and provides a set of capabilities for working with
-coordinates, points, intervals and rectangles that are needed to support
-implementing and interacting with polygon data structures and algorithms. </p><img src="images/hand.png" border="0" height="277" width="837" /><p>
-One of the important features of the library is the implementation of
-the generic sweepline algorithm to construct Voronoi diagrams of points and linear segments in 2D (developed
+ <li>Voronoi Builder</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><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>THE BOOST.POLYGON LIBRARY</h1>
+ <p>The Boost.Polygon library provides algorithms focused on
+manipulating planar polygon geometry data. Specific algorithms
+provided are the polygon set operations (intersection, union,
+difference, disjoint-union) and related algorithms such as polygon
+connectivity graph extraction, offsetting and map-overlay. An
+example of the disjoint-union (XOR) of figure a and figure b is shown
+below in figure c. These so-called Boolean algorithms are of
+significant interest in GIS (Geospatial Information Systems), VLSI CAD
+as well all other fields of CAD, and many more application areas, and
+providing them is the primary focus of this library. The
+Boost.Polygon library is not intended to cover all of computational
+geometry in its scope, and provides a set of capabilities for working
+with coordinates, points, intervals and rectangles that are needed to
+support implementing and interacting with polygon data structures and
+algorithms. </p>
+ <img src="images/hand.png" border="0" height="277" width="837" />
+ <p>One of the important features of the library is the
+implementation of
+the generic sweepline algorithm to construct Voronoi diagrams of points
+and linear segments in 2D (developed
as part of the GSoC 2010 program). Voronoi diagram data structure has
applications in image segmentation, optical character recognition,
-nearest neighbor queries execution. It is closely related with the other
+nearest neighbor queries execution. It is closely related with the
+other
computational geometry concepts: Delaunay triangulation, medial axis,
straight skeleton, the largest empty circle. The Boost.Polygon library
provides interface to construct Voronoi diagram of points figure a and
line segments figure b (the last could be used to discretize any
-two-dimensional curve). Figure c contains the example of the medial axis of the
-non-convex polygon. The implementation outperforms most of the known
+two-dimensional curve). Figure c contains the example of the medial
+axis of the
+non-convex polygon. The implementation outperforms
+most of the known
commercial and non-commercial libraries in both efficiency and
-numerical robustness aspects. You may find more details on the topic at the Voronoi main page.<br />
-
-</p>
-<p><img src="images/voronoi.png" border="0" height="300" width="900" /></p>
-<p>The coordinate data type is a template parameter of all data types
+numerical robustness aspects. You may find more details on the topic at
+the Voronoi main page.<br />
+ </p>
+ <p><img src="images/voronoi.png" border="0" height="300"
+ width="900" /></p>
+ <p>The coordinate data type is a template parameter of all data
+types
and algorithms provided by the library, and is expected to be integral.
Floating point coordinate data types are not supported by the
algorithms implemented in the library due to the fact that the
@@ -131,161 +135,161 @@
point representations.
For additional detailed discussion of the library and its
implementation including benchmark comparisons with other open source
-alternatives please see the paper and
-presentation from
-boostcon 2009 as well as a detailed
-analysis of the runtime complexity of
+alternatives please see the paper
+and
+ presentation from
+ boostcon 2009 as well
+as a detailed
+ analysis of the runtime complexity of
the library's core algorithms. </p>
-<p>The design philosophy behind the polygon library was to create an API for
-invoking the library algorithms it provides on user geometry data types that is maximally
-intuitive, minimally error-prone and easy to integrate into pre-existing
-applications. C++-concepts based template meta-programming combined with
-generic operator overloading meets these design goals without sacrificing the
-runtime or memory efficiency of the underlying algorithms. The API is
-intended to demonstrate what could be achieved with ease by a C++-concepts based
-library interface, but is implemented based on current language features. This API makes
-the following code snippet that operates on non-library geometry types possible:</p>
-<p:colorscheme colors="#ffffff,#000000,#808080,#000000,#bbe0e3,#333399,#009999,#99cc00">
-
-</p:colorscheme><div v:shape="_x0000_s1026" class="O">
- <div style="text-align: justify;">
- <nobr>
- <span style="font-family: Courier New;">
- void foo(list<CPolygon>& result, const list<CPolygon>& a, </span></nobr><br />
- <span style="font-family: Courier New;">
- </span><nobr>
- <span style="font-family: Courier New;">
- const list<CPolygon>&
- b, int deflateValue) { </span></nobr></div>
- <div style="text-align: justify;">
- <nobr>
-<span style="font-family: Courier New;">
- CBoundingBox domainExtent; </span></nobr></div>
- <div style="text-align: justify;">
- <nobr>
- <span style="font-family: Courier New;">
- <span style=""> </span> using namespace boost::polygon::operators; </span></nobr></div>
- <div style="text-align: justify;">
- <nobr>
- <span style="font-family: Courier New;">
- <span style=""> </span>
- boost::polygon::extents(domainExtent, a); </span></nobr></div>
- <div style="text-align: justify;">
- <nobr>
- <span style="font-family: Courier New;">
- <span style=""> </span>result += (b &
- domainExtent) ^ (a - deflateValue); </span></nobr></div>
- <div style="text-align: justify;">
- <nobr>
- <span style="font-family: Courier New;">
- }</span></nobr></div>
-</div>
-<p>In the code snippet above the hypothetical polygon type CPolygon has been
-mapped to the library polygon concept and is used with library APIs to clip
-polygon list <i>b</i> against the bounding box of polygon list <i>a</i> and apply the
-disjoint-union of that with polygon list <i>a</i> deflated by some integer amount.
-The end result is accumulated into a list of polygons with a union operation.
-It is considerably more typing to describe this usage of the API than to code
-it, and the description is not much clearer than the code itself.
-A picture is worth a thousand words.</p>
-<p><img src="images/foo.PNG" border="0" height="371" width="432" /></p>
-<p>In Boost.Polygon operations such as those shown above are free
+ <p>The design philosophy behind the polygon library was to create
+an API for invoking the library algorithms it provides on user geometry
+data types that is maximally intuitive, minimally error-prone and easy
+to integrate into pre-existing applications. C++-concepts based
+template meta-programming combined with generic operator overloading
+meets these design goals without sacrificing the runtime or memory
+efficiency of the underlying algorithms. The API is intended to
+demonstrate what could be achieved with ease by a C++-concepts based
+library interface, but is implemented based on current language
+features. This API makes the following code snippet that operates
+on non-library geometry types possible:</p>
+ <p:colorscheme
+ colors="#ffffff,#000000,#808080,#000000,#bbe0e3,#333399,#009999,#99cc00">
+ </p:colorscheme>
+ <div v:shape="_x0000_s1026" class="O">
+ <div style="text-align: justify;"> <nobr> <span
+ style="font-family: Courier New;"> void foo(list<CPolygon>&
+result, const list<CPolygon>& a, </span></nobr><br />
+ <span style="font-family: Courier New;">
+ </span><nobr> <span style="font-family: Courier New;"> const
+list<CPolygon>& b, int deflateValue) { </span></nobr></div>
+ <div style="text-align: justify;"> <nobr><span
+ style="font-family: Courier New;">
+CBoundingBox domainExtent; </span></nobr></div>
+ <div style="text-align: justify;"> <nobr> <span
+ style="font-family: Courier New;"> <span style=""> </span>
+using namespace boost::polygon::operators; </span></nobr></div>
+ <div style="text-align: justify;"> <nobr> <span
+ style="font-family: Courier New;"> <span style=""> </span>
+boost::polygon::extents(domainExtent, a); </span></nobr></div>
+ <div style="text-align: justify;"> <nobr> <span
+ style="font-family: Courier New;"> <span style="">
+ </span>result += (b & domainExtent) ^ (a - deflateValue); </span></nobr></div>
+ <div style="text-align: justify;"> <nobr> <span
+ style="font-family: Courier New;"> }</span></nobr></div>
+ </div>
+ <p>In the code snippet above the hypothetical polygon type
+CPolygon has been mapped to the library polygon concept and is used
+with library APIs to clip polygon list <i>b</i> against the bounding
+box of polygon list <i>a</i> and apply the disjoint-union of that with
+polygon list <i>a</i> deflated by some integer amount. The end
+result is accumulated into a list of polygons with a union
+operation. It is considerably more typing to describe this usage
+of the API than to code it, and the description is not much clearer
+than the code itself. A picture is worth a thousand words.</p>
+ <p><img src="images/foo.PNG" border="0" height="371" width="432" /></p>
+ <p>In Boost.Polygon operations such as those shown above are free
functions named for what they do, or are overloads of C++ operators
that make it easy to infer from reading the code what to expect.
-Operators are contained in the namespace <font face="Courier New">boost::polygon::operators</font>
-so that they can be used outside the <font face="Courier New">boost::polygon</font>
-namespace without bringing in the entire <font face="Courier New">boost::polygon</font>
-namespace. Following the
-principle of least astonishment, the inferred behavior should generally match
-the actual behavior. Conventions such as argument ordering (output
-arguments come first) and consistently applying the same semantics across
-different functions (accumulate) reduces the learning curve for new users while reducing the
-need to memorize semantics and argument ordering of many different functions for
-advanced users.</p>
-<p>While the internal library code that implements this API is usually complex and
-cryptic due to heavy use of template meta-programming, the application of the library
-API in user code is usually simple and clear because it is free of any
-extraneous syntax. The one exception to this is the mapping of user types
-to library concepts, which necessitates that the user perform some simple
-template programming and understand some of the internals of how the library
-concept type system works. The examples below should aid the user in
-performing these programming tasks.</p>
-<ul>
-
-<li>Example files:
- <ul>
- <li>point_usage.cpp Using the
- library provided point data type and functions</li>
- <li>custom_point.cpp Mapping a
- user defined point class to the library point_concept</li>
- <li>polygon_usage.cpp Using
- the library provided polygon data types and functions</li>
- <li>custom_polygon.cpp Mapping a
- user defined polygon class to the library polygon_concept</li>
- <li>polygon_set_usage.cpp Using
- the library provided polygon set data types and functions</li>
- <li>custom_polygon_set.cpp
- Mapping a user defined class to the library polygon_set_concept</li>
- <li>connectivity_extraction_usage.cpp
- Using the connectivity extraction algorithm to build a connectivity
- graph on polygons</li>
-
- <li>property_merge_usage.cpp
- Using the n-layer map-overlay algorithm on polygon data</li>
-
- </ul>
-
-</li><li>Tutorials:
-<ul>
- <li>Layout Versus Schematic Learn how to
- apply Boost.Polygon capabilities to implement a simplified circuit
- extraction application</li>
- <li>Minkowski Sum Learn how to
- apply Boost.Polygon capabilities to implement Minkowski sum of polygon sets</li>
- <li>Voronoi Basic Tutorial Learn how
- to construct, traverse, visualize, associate data with Voronoi diagrams without digging into the library details.</li>
- <li>Voronoi Advanced Tutorial
- Learn how to configure the Voronoi builder and Voronoi diagram
- data structure with the user provided coordinate types. </li>
-</ul>
-
-</li></ul>
-
-
-<p>We would like to thank: Thomas Klimpel, Frank Mori Hess, Barend Gehrels,
-Andreas Fabri, Jeffrey Hellrung, Tim Keitt, Markus Werle, Paul A. Bristow,
-Robert Stewart, Mathias Gaunard, Michael Fawcett, Steven Watanabe, Joachim
-Faulhaber, John Bytheway, Sebastian Redl, Mika Heiskanen, John Phillips, Kai
-Benndorf, Hartmut Kaiser, Arash Partow, Maurizio Vitale, Brandon Kohn, David
-Abrahams, Gordon Woodhull, Daniel James, John Maddock, Tom Brinkman, Bo Persson,
-Mateusz Loskot, Christian Henning, Jean-Sebastien Stoezel, for providing
-feedback and or formal review of the library as part of the boost submission
-process and Fernando Cacciola for graciously serving as review manager.</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="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
+Operators are contained in the namespace <font face="Courier New">boost::polygon::operators</font>
+so that they can be used outside the <font face="Courier New">boost::polygon</font>
+namespace without bringing in the entire <font face="Courier New">boost::polygon</font>
+namespace. Following the principle of least astonishment, the
+inferred behavior should generally match the actual behavior.
+Conventions such as argument ordering (output arguments come first) and
+consistently applying the same semantics across different functions
+(accumulate) reduces the learning curve for new users while reducing
+the need to memorize semantics and argument ordering of many different
+functions for advanced users.</p>
+ <p>While the internal library code that implements this API is
+usually complex and cryptic due to heavy use of template
+meta-programming, the application of the library API in user code is
+usually simple and clear because it is free of any extraneous
+syntax. The one exception to this is the mapping of user types to
+library concepts, which necessitates that the user perform some simple
+template programming and understand some of the internals of how the
+library concept type system works. The examples below should aid
+the user in performing these programming tasks.</p>
+ <ul>
+ <li>Example files:
+ <ul>
+ <li>point_usage.cpp Using
+the library provided point data type and functions</li>
+ <li>custom_point.cpp
+Mapping a user defined point class to the library point_concept</li>
+ <li>polygon_usage.cpp
+Using the library provided polygon data types and functions</li>
+ <li>custom_polygon.cpp
+Mapping a user defined polygon class to the library polygon_concept</li>
+ <li>polygon_set_usage.cpp
+Using the library provided polygon set data types and functions</li>
+ <li>custom_polygon_set.cpp
+Mapping a user defined class to the library polygon_set_concept</li>
+ <li>connectivity_extraction_usage.cpp
+Using the connectivity extraction algorithm to build a connectivity
+graph on polygons</li>
+ <li>property_merge_usage.cpp
+Using the n-layer map-overlay algorithm on polygon data</li>
+ </ul>
+ </li>
+ <li>Tutorials:
+ <ul>
+ <li>Layout Versus Schematic
+Learn how to apply Boost.Polygon capabilities to implement a simplified
+circuit extraction application</li>
+ <li>Minkowski Sum
+Learn how to apply Boost.Polygon capabilities to implement Minkowski
+sum of polygon sets</li>
+ <li><a href="voronoi_basic_tutorial.htm">Voronoi Basic
+Tutorial</a> Learn how to construct, traverse, visualize, associate
+data with Voronoi diagrams without digging into the library details.</li>
+ <li><a href="voronoi_advanced_tutorial.htm">Voronoi
+Advanced Tutorial</a> Learn how to configure the Voronoi builder and
+Voronoi diagram data structure with the user provided coordinate types.
+ </li>
+ </ul>
+ </li>
+ </ul>
+ <p>We would like to thank: Thomas Klimpel, Frank Mori Hess,
+Barend Gehrels, Andreas Fabri, Jeffrey Hellrung, Tim Keitt, Markus
+Werle, Paul A. Bristow, Robert Stewart, Mathias Gaunard, Michael
+Fawcett, Steven Watanabe, Joachim Faulhaber, John Bytheway, Sebastian
+Redl, Mika Heiskanen, John Phillips, Kai Benndorf, Hartmut Kaiser,
+Arash Partow, Maurizio Vitale, Brandon Kohn, David Abrahams, Gordon
+Woodhull, Daniel James, John Maddock, Tom Brinkman, Bo Persson, Mateusz
+Loskot, Christian Henning, Jean-Sebastien Stoezel, for providing
+feedback and or formal review of the library as part of the boost
+submission process and Fernando Cacciola for graciously serving as
+review manager.</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="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: trunk/libs/polygon/doc/voronoi_benchmark.htm
==============================================================================
--- trunk/libs/polygon/doc/voronoi_benchmark.htm (original)
+++ trunk/libs/polygon/doc/voronoi_benchmark.htm 2013-04-07 19:23:46 EDT (Sun, 07 Apr 2013)
@@ -1,25 +1,22 @@
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
-<html><head>
-
-
-
-
-
-
-
-
-
-
+<html>
+<head>
<meta http-equiv="Content-Language" content="en-us">
-
-
- <meta http-equiv="Content-Type" content="text/html; charset=windows-1252"><title>Voronoi Benchmark</title></head><body>
-<table style="margin: 0pt; padding: 0pt; width: 100%;" border="0" cellpadding="0" cellspacing="0">
-
+ <meta http-equiv="Content-Type"
+ content="text/html; charset=windows-1252">
+ <title>Voronoi Benchmark</title>
+</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" tabindex="2" style="border: medium none ;" href="http://www.boost.org/"> </a></div>
+ <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" tabindex="2"
+ style="border: medium none ;" href="http://www.boost.org/"> </a></div>
<div style="margin: 5px;">
<h3 class="navbar">Contents</h3>
<ul>
@@ -30,7 +27,6 @@
<li>Interval Concept</li>
<li>Point Concept</li>
<li>Segment Concept</li>
-
<li>Rectangle Concept</li>
<li>Polygon 90 Concept</li>
<li><a href="gtl_polygon_90_with_holes_concept.htm">Polygon 90
@@ -60,12 +56,7 @@
<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>
-
+ <li>Voronoi Diagram</li>
</ul>
<h3 class="navbar">Other Resources</h3>
<ul>
@@ -81,46 +72,61 @@
</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" tabindex="2" style="border: medium none ;" href="http://www.adobe.com/"> </a></div>
+ <div style="padding: 5px;" align="center"> <img
+ src="images/intlogo.gif" border="0" height="51" width="127"><a
+ title="www.adobe.com home page" tabindex="2"
+ style="border: medium none ;" href="http://www.adobe.com/"> </a></div>
</td>
- <td style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;" valign="top" width="100%"><!-- End Header --> <br>
-
+ <td
+ style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;"
+ valign="top" width="100%"><!-- End Header --> <br>
<h1>Voronoi Benchmark</h1>
-There are not many known Voronoi libraries that are capable to satisfy the
+There are not many known Voronoi libraries that are capable to satisfy
+the
following set of conditions:<br>
<ul>
<li>could handle input data sets of points and segments<br>
-</li>
+ </li>
<li>give exact warranties about the algorithm robustness and
output topology<br>
</li>
- <li>compute coordinates of the output geometries within the fixed relative precision<br>
-</li>
- </ul>Below is the list of libraries included in this benchmark sorted by the number of conditions each of them satisfies:<br>
+ <li>compute coordinates of the output geometries within the
+fixed relative precision<br>
+ </li>
+ </ul>
+Below is the list of libraries included in this benchmark sorted by the
+number of conditions each of them satisfies:<br>
<ul>
- <li>Boost.Polygon Voronoi - satisfies all the conditions above, implements sweep-line algorithm.<br>
+ <li>Boost.Polygon Voronoi - satisfies all the conditions above,
+implements sweep-line algorithm.<br>
</li>
- <li>CGAL - satisfies the first two conditions, implements incremental algorithm. CGAL is a well-known
+ <li>CGAL - satisfies the first two conditions, implements
+incremental algorithm. CGAL is a well-known
library in the computational geometry area, especially for its
robustness.<br>
-</li>
+ </li>
<li>S-Hull
- doesn't satisfy any of the above conditions. S-Hull is a non-robust
implementation of the sweep-hull algorithm used to construct Delaunay
triangulation of a set of points.<br>
</li>
- </ul>At the moment this benchmark includes only two robust implementations:
+ </ul>
+At the moment this benchmark includes only two robust implementations:
Boost.Polygon Voronoi and CGAL. Thus we are considering comparison of
those two to be of the most interest. <br>
<br>
-Other libraries (OpenVoronoi, Triangle) would be added to this benchmark
+Other libraries (OpenVoronoi,
+ Triangle)
+would be added to this benchmark
incrementally (we are open for suggestions).<br>
<h2>Important<br>
- </h2>While results of this benchmark show complete dominance of
+ </h2>
+While results of this benchmark show complete dominance of
the Boost.Polygon Voronoi over the CGAL Delaunay Graph implementation,
we would like to make it clear
that both libraries use different approach to construct Voronoi
-diagram. Thus there are problems where the CGAL's incremental approach would
+diagram. Thus there are problems where the CGAL's incremental approach
+would
be still more vital than the sweep-line algorithm (e.g. input sites are
inserted as a live stream
data).<br>
@@ -128,11 +134,15 @@
</h2>
The benchmark consists of the two parts:<br>
<ul>
- <li>The first one constructs the Voronoi diagram of a set of random points (voronoi_benchmark_points.cpp)</li>
- <li>The second one constructs the Voronoi diagram of a set of random
+ <li>The first one constructs the Voronoi diagram of a set of
+random points (<a href="../benchmark/voronoi_benchmark_points.cpp"><span
+ style="text-decoration: underline;">voronoi_benchmark_points.cpp</span></a>)</li>
+ <li>The second one constructs the Voronoi diagram of a set of
+random
segments (voronoi_benchmark_segments.cpp)</li>
</ul>
-Below we list important benchmark details that should be considered while reviewing its results:<br>
+Below we list important benchmark details that should be considered
+while reviewing its results:<br>
<ul>
<li>We ensure that input data sets are the same for all
libraries by initializing random generator with the same seed</li>
@@ -142,11 +152,13 @@
properly, thus those are eliminated before the algorithm execution
explicitly (Boost.Polygon Voronoi and CGAL do that implicitly) <br>
</li>
-
- <li>There is no Voronoi diagram data structure in CGAL/S-Hull. That's why we use the segment Delaunay graph which is topologically
+ <li>There is no Voronoi diagram data structure in CGAL/S-Hull.
+That's why we use the segment Delaunay graph which is topologically
dual to the Voronoi diagram</li>
- <li>CGAL's and S-Hull's output Delaunay triangulation doesn't contain information
-about coordinates of the Voronoi vertices. We didn't include time to compute Voronoi vertices and memory
+ <li>CGAL's and S-Hull's output Delaunay triangulation doesn't
+contain information
+about coordinates of the Voronoi vertices. We didn't include time to
+compute Voronoi vertices and memory
storage required for those in this benchmark.<br>
</li>
<li>Both Boost.Polygon Voronoi and CGAL process each input
@@ -155,10 +167,7 @@
time and memory usage for Voronoi of segments would be at
least 3 times
slower than for Voronoi of points</li>
-
-
</ul>
-
The benchmark was executed on the following two system configurations:<br>
<br>
Hardware: Intel i5-7600 2.8 GHz, 4GiB RAM.<br>
@@ -171,12 +180,16 @@
patch.<br>
<h2>Voronoi Benchmark Results</h2>
<h3>Random Points Benchmark</h3>
- <table style="text-align: left; width: 100%; margin-left: auto; margin-right: auto;" border="1" cellpadding="2" cellspacing="2">
+ <table
+ style="text-align: left; width: 100%; margin-left: auto; margin-right: auto;"
+ border="1" cellpadding="2" cellspacing="2">
<tbody>
<tr>
- <td colspan="2" rowspan="1" style="vertical-align: top; text-align: center;">Test specification<br>
+ <td colspan="2" rowspan="1"
+ style="vertical-align: top; text-align: center;">Test specification<br>
</td>
- <td colspan="6" rowspan="1" style="vertical-align: top; text-align: center;">Average construction
+ <td colspan="6" rowspan="1"
+ style="vertical-align: top; text-align: center;">Average construction
time (in secs)<br>
</td>
</tr>
@@ -193,16 +206,18 @@
<td style="vertical-align: top; text-align: center;">CGAL
Win-32<br>
</td>
- <td style="vertical-align: top; text-align: center;">S-Hull Win-32<br>
+ <td style="vertical-align: top; text-align: center;">S-Hull
+Win-32<br>
</td>
-<td style="vertical-align: top; text-align: center;">Boost
+ <td style="vertical-align: top; text-align: center;">Boost
Linux-64<br>
</td>
<td style="vertical-align: top; text-align: center;">CGAL
Linux-64<br>
- </td><td style="vertical-align: top; text-align: center;">S-Hull Linux-64<br>
</td>
-
+ <td style="vertical-align: top; text-align: center;">S-Hull
+Linux-64<br>
+ </td>
</tr>
<tr>
<td style="vertical-align: top; text-align: right;">10<br>
@@ -215,12 +230,12 @@
</td>
<td style="vertical-align: top; text-align: right;">0.000043<br>
</td>
-<td style="vertical-align: top; text-align: right;">0.000013<br>
+ <td style="vertical-align: top; text-align: right;">0.000013<br>
</td>
<td style="vertical-align: top; text-align: right;">0.000052<br>
- </td><td style="vertical-align: top; text-align: right;">0.000012<br>
</td>
-
+ <td style="vertical-align: top; text-align: right;">0.000012<br>
+ </td>
</tr>
<tr>
<td style="vertical-align: top; text-align: right;">100<br>
@@ -233,12 +248,12 @@
</td>
<td style="vertical-align: top; text-align: right;">0.000521<br>
</td>
-<td style="vertical-align: top; text-align: right;">0.000192<br>
+ <td style="vertical-align: top; text-align: right;">0.000192<br>
</td>
<td style="vertical-align: top; text-align: right;"> 0.001150<br>
- </td><td style="vertical-align: top; text-align: right;">0.000139<br>
</td>
-
+ <td style="vertical-align: top; text-align: right;">0.000139<br>
+ </td>
</tr>
<tr>
<td style="vertical-align: top; text-align: right;">1000<br>
@@ -251,12 +266,12 @@
</td>
<td style="vertical-align: top; text-align: right;">0.007125<br>
</td>
-<td style="vertical-align: top; text-align: right;">0.002130<br>
+ <td style="vertical-align: top; text-align: right;">0.002130<br>
</td>
<td style="vertical-align: top; text-align: right;">0.016680<br>
- </td><td style="vertical-align: top; text-align: right;">0.002010<br>
</td>
-
+ <td style="vertical-align: top; text-align: right;">0.002010<br>
+ </td>
</tr>
<tr>
<td style="vertical-align: top; text-align: right;">10000<br>
@@ -269,12 +284,12 @@
</td>
<td style="vertical-align: top; text-align: right;">0.091640<br>
</td>
-<td style="vertical-align: top; text-align: right;">0.022900<br>
+ <td style="vertical-align: top; text-align: right;">0.022900<br>
</td>
<td style="vertical-align: top; text-align: right;">0.297900<br>
- </td><td style="vertical-align: top; text-align: right;">0.028300<br>
</td>
-
+ <td style="vertical-align: top; text-align: right;">0.028300<br>
+ </td>
</tr>
<tr>
<td style="vertical-align: top; text-align: right;">100000<br>
@@ -287,12 +302,12 @@
</td>
<td style="vertical-align: top; text-align: right;">1.218000<br>
</td>
-<td style="vertical-align: top; text-align: right;">0.274000<br>
+ <td style="vertical-align: top; text-align: right;">0.274000<br>
</td>
<td style="vertical-align: top; text-align: right;">8.047000<br>
- </td><td style="vertical-align: top; text-align: right;">0.432000<br>
</td>
-
+ <td style="vertical-align: top; text-align: right;">0.432000<br>
+ </td>
</tr>
<tr>
<td style="vertical-align: top; text-align: right;">1000000<br>
@@ -305,45 +320,65 @@
</td>
<td style="vertical-align: top; text-align: right;">15.394000<br>
</td>
-<td style="vertical-align: top; text-align: right;">3.290000<br>
+ <td style="vertical-align: top; text-align: right;">3.290000<br>
</td>
<td style="vertical-align: top; text-align: right;">315.740000<br>
- </td><td style="vertical-align: top; text-align: right;">6.350000<br>
</td>
-
+ <td style="vertical-align: top; text-align: right;">6.350000<br>
+ </td>
</tr>
</tbody>
</table>
<br>
- <table style="text-align: left;" border="1" cellpadding="2" cellspacing="2">
+ <table style="text-align: left;" border="1" cellpadding="2"
+ cellspacing="2">
<tbody>
<tr>
- <td style="vertical-align: top;"><img style="width: 500px; height: 300px;" alt="" src="images/benchmark_points_10.png"></td>
- <td style="vertical-align: top;"><img style="width: 500px; height: 300px;" alt="" src="images/benchmark_points_100.png"></td>
- </tr>
- <tr>
- <td style="vertical-align: top;"><img style="width: 500px; height: 300px;" alt="" src="images/benchmark_points_1000.png"></td>
- <td style="vertical-align: top;"><img style="width: 500px; height: 300px;" alt="" src="images/benchmark_points_10000.png"></td>
- </tr>
- <tr>
- <td style="vertical-align: top;"><img style="width: 500px; height: 300px;" alt="" src="images/benchmark_points_100000.png"></td>
- <td style="vertical-align: top;"><img style="width: 500px; height: 300px;" alt="" src="images/benchmark_points_1000000.png"></td>
- </tr>
- <tr>
- <td style="vertical-align: top;"><img style="width: 500px; height: 300px;" alt="" src="images/benchmark_points_memory.png"><br>
- </td>
- <td style="vertical-align: top;"><img style="width: 500px; height: 300px;" alt="" src="images/benchmark_points_all.png"><br>
+ <td style="vertical-align: top;"><img
+ style="width: 500px; height: 300px;" alt=""
+ src="images/benchmark_points_10.png"></td>
+ <td style="vertical-align: top;"><img
+ style="width: 500px; height: 300px;" alt=""
+ src="images/benchmark_points_100.png"></td>
+ </tr>
+ <tr>
+ <td style="vertical-align: top;"><img
+ style="width: 500px; height: 300px;" alt=""
+ src="images/benchmark_points_1000.png"></td>
+ <td style="vertical-align: top;"><img
+ style="width: 500px; height: 300px;" alt=""
+ src="images/benchmark_points_10000.png"></td>
+ </tr>
+ <tr>
+ <td style="vertical-align: top;"><img
+ style="width: 500px; height: 300px;" alt=""
+ src="images/benchmark_points_100000.png"></td>
+ <td style="vertical-align: top;"><img
+ style="width: 500px; height: 300px;" alt=""
+ src="images/benchmark_points_1000000.png"></td>
+ </tr>
+ <tr>
+ <td style="vertical-align: top;"><img
+ style="width: 500px; height: 300px;" alt=""
+ src="images/benchmark_points_memory.png"><br>
+ </td>
+ <td style="vertical-align: top;"><img
+ style="width: 500px; height: 300px;" alt=""
+ src="images/benchmark_points_all.png"><br>
</td>
</tr>
</tbody>
</table>
<h3>Random Segments Benchmark</h3>
- <table style="text-align: left; width: 100%;" border="1" cellpadding="2" cellspacing="2">
+ <table style="text-align: left; width: 100%;" border="1"
+ cellpadding="2" cellspacing="2">
<tbody>
<tr>
- <td colspan="2" rowspan="1" style="vertical-align: top; text-align: center;">Test specification<br>
+ <td colspan="2" rowspan="1"
+ style="vertical-align: top; text-align: center;">Test specification<br>
</td>
- <td colspan="4" rowspan="1" style="vertical-align: top; text-align: center;">Average construction
+ <td colspan="4" rowspan="1"
+ style="vertical-align: top; text-align: center;">Average construction
time (in secs)</td>
</tr>
<tr>
@@ -453,24 +488,41 @@
</tbody>
</table>
<br>
- <table style="text-align: left;" border="1" cellpadding="2" cellspacing="2">
+ <table style="text-align: left;" border="1" cellpadding="2"
+ cellspacing="2">
<tbody>
<tr>
- <td style="vertical-align: top;"><img style="width: 500px; height: 300px;" alt="" src="images/benchmark_segments_10.png"></td>
- <td style="vertical-align: top;"><img style="width: 500px; height: 300px;" alt="" src="images/benchmark_segments_100.png"></td>
- </tr>
- <tr>
- <td style="vertical-align: top;"><img style="width: 500px; height: 300px;" alt="" src="images/benchmark_segments_1000.png"></td>
- <td style="vertical-align: top;"><img style="width: 500px; height: 300px;" alt="" src="images/benchmark_segments_10000.png"></td>
- </tr>
- <tr>
- <td style="vertical-align: top;"><img style="width: 500px; height: 300px;" alt="" src="images/benchmark_segments_100000.png"></td>
- <td style="vertical-align: top;"><img style="width: 500px; height: 300px;" alt="" src="images/benchmark_segments_1000000.png"></td>
- </tr>
- <tr>
- <td style="vertical-align: top;"><img style="width: 500px; height: 300px;" alt="" src="images/benchmark_segments_memory.png"><br>
- </td>
- <td style="vertical-align: top;"><img style="width: 500px; height: 300px;" alt="" src="images/benchmark_segments_all.png"><br>
+ <td style="vertical-align: top;"><img
+ style="width: 500px; height: 300px;" alt=""
+ src="images/benchmark_segments_10.png"></td>
+ <td style="vertical-align: top;"><img
+ style="width: 500px; height: 300px;" alt=""
+ src="images/benchmark_segments_100.png"></td>
+ </tr>
+ <tr>
+ <td style="vertical-align: top;"><img
+ style="width: 500px; height: 300px;" alt=""
+ src="images/benchmark_segments_1000.png"></td>
+ <td style="vertical-align: top;"><img
+ style="width: 500px; height: 300px;" alt=""
+ src="images/benchmark_segments_10000.png"></td>
+ </tr>
+ <tr>
+ <td style="vertical-align: top;"><img
+ style="width: 500px; height: 300px;" alt=""
+ src="images/benchmark_segments_100000.png"></td>
+ <td style="vertical-align: top;"><img
+ style="width: 500px; height: 300px;" alt=""
+ src="images/benchmark_segments_1000000.png"></td>
+ </tr>
+ <tr>
+ <td style="vertical-align: top;"><img
+ style="width: 500px; height: 300px;" alt=""
+ src="images/benchmark_segments_memory.png"><br>
+ </td>
+ <td style="vertical-align: top;"><img
+ style="width: 500px; height: 300px;" alt=""
+ src="images/benchmark_segments_all.png"><br>
</td>
</tr>
</tbody>
@@ -486,8 +538,8 @@
the Boost.Polygon Voronoi is faster than non-robust of
S-Hull (except small input sets of around 100 points on Linux-64).<br>
</li>
-
- <li>Logarithmic execution time shows that Boost.Polygon Voronoi and S-Hull
+ <li>Logarithmic execution time shows that Boost.Polygon Voronoi
+and S-Hull
have clear N*log(N) complexity, while this doesn't seem to be true for
CGAL (at least for large input data sets).<br>
</li>
@@ -509,10 +561,14 @@
</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%">
+ <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">
+ <colgroup> <col class="docinfo-name"><col
+ class="docinfo-content"> </colgroup> <tbody valign="top">
<tr>
<th class="docinfo-name">Copyright:</th>
<td>Copyright © Andrii Sydorchuk 2010-2012.</td>
@@ -520,7 +576,10 @@
<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">
+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>
@@ -529,6 +588,5 @@
</tr>
</tbody>
</table>
-
-
-</body></html>
\ No newline at end of file
+</body>
+</html>
Modified: trunk/libs/polygon/doc/voronoi_builder.htm
==============================================================================
--- trunk/libs/polygon/doc/voronoi_builder.htm (original)
+++ trunk/libs/polygon/doc/voronoi_builder.htm 2013-04-07 19:23:46 EDT (Sun, 07 Apr 2013)
@@ -54,9 +54,7 @@
<li>Voronoi Main Page </li>
<li>Voronoi Benchmark </li>
<li>Voronoi Builder</li>
- <li>Voronoi Diagram </li>
- <li>Voronoi Predicates</li>
- <li>Voronoi Robust FPT </li>
+ <li>Voronoi Diagram</li>
</ul>
<h3 class="navbar">Other Resources</h3>
<ul>
Modified: trunk/libs/polygon/doc/voronoi_diagram.htm
==============================================================================
--- trunk/libs/polygon/doc/voronoi_diagram.htm (original)
+++ trunk/libs/polygon/doc/voronoi_diagram.htm 2013-04-07 19:23:46 EDT (Sun, 07 Apr 2013)
@@ -57,8 +57,6 @@
<li>Voronoi Benchmark</li>
<li>Voronoi Builder </li>
<li>Voronoi Diagram</li>
- <li>Voronoi Predicates</li>
- <li>Voronoi Robust FPT </li>
</ul>
<h3 class="navbar">Other Resources</h3>
<ul>
Modified: trunk/libs/polygon/doc/voronoi_main.htm
==============================================================================
--- trunk/libs/polygon/doc/voronoi_main.htm (original)
+++ trunk/libs/polygon/doc/voronoi_main.htm 2013-04-07 19:23:46 EDT (Sun, 07 Apr 2013)
@@ -59,8 +59,6 @@
<li>Voronoi Benchmark</li>
<li>Voronoi Builder </li>
<li>Voronoi Diagram</li>
- <li>Voronoi Predicates</li>
- <li>Voronoi Robust FPT </li>
</ul>
<h3 class="navbar">Other Resources</h3>
<ul>
@@ -139,9 +137,9 @@
computations in the 95% of the cases and
uses the efficient, floating-point based predicates. Such preciates
don't
-produce the correct result always, however the library embeds the <a
- href="voronoi_robust_fpt.htm">relative
-error arithmetic apparatus</a> to identify such situations and switch
+produce the correct result always, however the library embeds the
+relative
+error arithmetic apparatus to identify such situations and switch
to the
higher precision predicates when appropriate. As the result, the
implementation has a solid performance comparing to the other known
Deleted: trunk/libs/polygon/doc/voronoi_predicates.htm
==============================================================================
--- trunk/libs/polygon/doc/voronoi_predicates.htm 2013-04-07 19:23:46 EDT (Sun, 07 Apr 2013)
+++ (empty file)
@@ -1,251 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
-<html><head>
-
-
-
-
-
-
-
- <meta http-equiv="Content-Language" content="en-us">
-
-
- <meta http-equiv="Content-Type" content="text/html; charset=windows-1252"><title>Voronoi Predicates</title>
-
-
-
-
- <meta http-equiv="content-type" content="text/html; charset=utf-8">
-
-
- <meta http-equiv="content-type" content="text/html; charset=utf-8"></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" tabindex="2" style="border: medium none ;" href="http://www.boost.org/"> </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><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>
- <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>
- <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><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" tabindex="2" style="border: medium none ;" href="http://www.adobe.com/"> </a></div>
- </td>
- <td style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;" valign="top" width="100%"><!-- End Header --> <br>
-
-
- <h1>Voronoi Predicates<br>
- </h1>
-
-In mathematical theory predicate is an operator which returns true
-or false (e.g. it may answer a question: "is it sunny today?").<br>
-
-Voronoi predicates contain implementation of a set of the geometric
-predicates used by the Voronoi builder.
-Except of those they also provide
-functors that allow to compute the coordinates of the centers of the
-inscribed
-circles (those correspond to the Voronoi vertices) within the given
-relative error precision range (64 machine epsilons). This means that
-the more mantissa bits
-your floating point type has the better precision of the output
-geometries you'll get. This
-is a very handy functionality as it allows to improve output precision
-simply providing 3rd party IEEE-754 like floating-point types.<br>
-
-
- <h2>Geometric Predicates</h2>
-
-The main issues with the implementation of any complex geometric
-algorithm arise when dealing with the robustness of the geometric
-predicates.
-Usually this
-is also the point where the commercial projects stand strong against
-noncommercial implementations (it's not the case with our
-implementation).
-For the short example let's consider the following code snippet, that
-could
-be used to compute orientation of the three points:<br>
-
- <br>
-
- <span style="font-family: Courier New,Courier,monospace;">double
-cross_product(double dx1, double dy1, double dx2, double dy2) {</span><br style="font-family: Courier New,Courier,monospace;">
-
- <span style="font-family: Courier New,Courier,monospace;">
-return dx1 * dy2 - dx2 * dy1;</span><br style="font-family: Courier New,Courier,monospace;">
-
- <span style="font-family: Courier New,Courier,monospace;">}<br>
- <br>
-int main() {<br>
- int v = 1 << 30; // 2 ^ 30<br>
- double result = </span><span style="font-family: Courier New,Courier,monospace;">cross_product</span><span style="font-family: Courier New,Courier,monospace;">(v, v - 1, v + 1,
-v);<br>
- printf("%.3f", result);<br>
- return 0;<br>
-}<br>
- <br>
- </span>The
-output of this simple program will be "0.000", while
-the correct one is "1.000". In terms of the orientation test this means
-that points are collinear instead of being CCW oriented. This is one of
-the basic predicates used in any geometric algorithm and taking wrong
-output from it may influence the further algorithm execution:
-corrupting algorithm underlying structures or producing completely
-invalid output. Voronoi uses
-slightly more complex predicates. To insure that they are robust and
-efficient the approach that combines two known techniques (lazy
-arithmetic and multiple
-precision computations) is used.<br>
-
-
- <h2>Lazy Arithmetic</h2>
-
-Lazy
-arithmetic is based on the usage of IEEE-754 floating-point types to
-quickly evaluate the result of the expression. While this approach has
-a good speed
-performance it doesn't produce reliable results all the time (as in the
-example above). The way to solve the issue is apart from computing
-result of the expression compute the relative error of it as well. This
-will
-give us the range of values the evaluated result belongs to and based
-on that we can
-come up with two decisions: 1) output the value; 2) recompute the
-expression using multiprecision type. The way relative errors are
-evaluated is explained in the <a href="voronoi_robust_fpt.htm">Voronoi
-Robust FPT</a> section.<br>
-
-
- <h2>Multiple Precision Arithmetic</h2>
-
-In the vast majority of cases
-the lazy arithmetic approach produces correct result thus further
-processing is not required. In other cases the Voronoi library defined
-or user
-provided multiple precision types are used to produce correct result.
-However even that doesn't solve all the cases. Multiprecision geometric
-predicates could be divided onto two categories:<br>
-
- <br>
-
-1) mathematical transformation of the predicate exists that evaluates
-the exact result:<span style="font-family: Courier New,Courier,monospace;"><br>
- <br>
-Predicate: A/B + C/D ?< 0;<br>
-After math. transform: (A*D + B*C) / (B * D) ?< 0;<br>
- <br>
-Predicate: sqrt(A) ?< 1.2;<br>
-After math. transform: A ?< 1.44;<br>
- <br>
- </span>2) the correct result could be produced only by increasing
-precision of the multiprecision type and with defined relative error
-for the output type:<br>
-
- <br>
-
- <span style="font-family: Courier New,Courier,monospace;">Predicate:
-sqrt(A) + sqrt(B) + sqrt(C) + sqrt(D) + sqrt(E) ?< 1.2;<br>
-Imagine that value of the expression to the left is very close to 1.2;<br>
- </span><br>
-
- <span style="font-family: Courier New,Courier,monospace;">Predicate:
-sin(x) ?< 0.57;<br>
-Relative error of sin function should be known;<br>
- <br>
- </span>The Voronoi of points could be completely
-implemented using predicates of the first type, however the Voronoi of
-segments could not.
-The predicate that doesn't fall into the first category is responsible
-for comparison of the Voronoi circle events. However it appears that
-properly used
-this predicate can't corrupt algorithm internal structures and produces
-output technically the same as produced in case this predicate fell in
-the first category. The main reasons for this are: 1) algorithm
-operates with integer coordinate type of the input geometries; 2)
-closely
-situated Voronoi vertices are considered to be the same in the output
-data structure (this won't influence main targets algorithm is used
-for).<span style="font-family: Courier New,Courier,monospace;"></span><span style="font-family: Courier New,Courier,monospace;"></span><br>
-</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 © Andrii Sydorchuk 2010-2012.</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
Deleted: trunk/libs/polygon/doc/voronoi_robust_fpt.htm
==============================================================================
--- trunk/libs/polygon/doc/voronoi_robust_fpt.htm 2013-04-07 19:23:46 EDT (Sun, 07 Apr 2013)
+++ (empty file)
@@ -1,217 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
-<html>
-<head>
- <meta http-equiv="Content-Language" content="en-us">
- <meta http-equiv="Content-Type"
- content="text/html; charset=windows-1252">
- <title>Voronoi Robust FPT</title>
-</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" tabindex="2"
- style="border: medium none ;" href="http://www.boost.org/"> </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><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>Voronoi Main Page </li>
- <li>Voronoi Benchmark</li>
- <li>Voronoi Builder </li>
- <li>Voronoi Diagram</li>
- <li>Voronoi Predicates</li>
- <li>Voronoi Robust FPT </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><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" tabindex="2"
- style="border: medium none ;" href="http://www.adobe.com/"> </a></div>
- </td>
- <td
- style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;"
- valign="top" width="100%"><!-- End Header --> <br>
- <h1>Voronoi Robust FPT</h1>
-The Voronoi
-robust floating-point types are the set of hidden classes and tools,
-that
-allow to estimate relative error of the arithmetic expressions. It is
-assumed, that the other Boost libraries may find this unit
-functionality useful, as it can be used to implement robust and
-efficient
-arithmetic predicates or functors, that compute values within known
-relative error.<br>
- <h2>Robust Fpt Type</h2>
-The robust
-fpt type (robust floating-point type) represents the IEEE-754
-floating-point type wrapper that also
-contains
-information about the relative error of the underlying value. The
-implementation overloads 5 standard operations: +, -, *, /, sqrt and
-apart from the evaluating value of the expression also computes its
-relative
-error. Let's consider two values A and B, C - rounding error, re(X)
-- relative error of the X expression, then the following rules apply:<br>
- <br>
- <span style="font-family: Courier New,Courier,monospace;">re(A+B)
-<= max(re(A), re(B)) + C, if A * B >= 0;</span><br
- style="font-family: Courier New,Courier,monospace;">
- <span style="font-family: Courier New,Courier,monospace;">re(A-B)
-<= (B * re(A) + A * re(B)) / |A - B| + C, if A * B < 0;</span><br
- style="font-family: Courier New,Courier,monospace;">
- <span style="font-family: Courier New,Courier,monospace;">re(A*B)
-<= re(A) + re(B) + C;</span><br
- style="font-family: Courier New,Courier,monospace;">
- <span style="font-family: Courier New,Courier,monospace;">re(A/B)
-<= re(A) + re(B) + C;</span><br
- style="font-family: Courier New,Courier,monospace;">
- <span style="font-family: Courier New,Courier,monospace;">re(sqrt(A))
-<= re(A) * 0.5 + C;<br>
- </span>The constant C is equal to the rounding error,
-which for the above set of arithmetic operations in the IEEE-754
-floating-point implementation should be equal to 1 machine epsilon. <br>
- <h2>Robust Difference Type</h2>
-The robust
-difference type represents expression wrapper, that holds the positive
-and negative
-partial
-sums of the expression as separate values, in order to avoid
-any cancellation errors before evaluating the final difference.
-Following
-arithmetic operators are overloaded for the robust difference type: +,
--, *, / (division operator is not overloaded for the case were divisor
-has robust difference type).<br>
-Looking at the relative error formulas above one may notice a few facts:<br>
-1) all of the formulas evaluate upper bound of the relative error, the
-actual value can be a lot smaller;<br>
-2) relative error estimate for the expression depends on the order
-operations are evaluated;<br>
-3) relative error of the difference of the two positive numbers
-may
-be
-extremely large in case their values are close to each other (this is
-also known as the cancellation error).<br>
-To explain this a bit, consider the following expression (~ - stands
-for
-almost equal, << - many times larger than):<br>
- <br>
- <span style="font-family: Courier New,Courier,monospace;">A - B +
-C, where A ~ B and C << B.</span><br>
- <br>
-Computing the relative error of this expression from left to right will
-produce extremely large relative error:<br>
- <br>
- <span style="font-family: Courier New,Courier,monospace;">re(A-B+C)
-= max(re(A-B), re(C)) = re(A-B) = (B * re(A) + A * re(B)) / 0 = INF.<br>
- </span>While doing this from right to left will keep the relative
-error value small:<br>
- <br>
- <span style="font-family: Courier New,Courier,monospace;">re(A-B+C)
-= re(C-B+A) = max(re(C-B), re(A)) = max(re(A), re(B)).<br>
- </span>While both estimates are valid (they define upper bound of
-the relative error), of course the second one is preferable. The robust
-difference type splits expression onto positive and negative partial
-sums and
-evaluates the
-difference only when the result is required.<br>
- <h2>Robust Sqrt Expression Structure</h2>
-The robust square root expression structure allows to compute the
-result of
-the expression, that contains square roots, within known relative
-error.
-As an example, consider the following expression:<br>
- <br>
- <span style="font-family: Courier New,Courier,monospace;">A *
-sqrt(a) - B * sqrt(b), A * B > 0, a >= 0, b >= 0.</span><br>
- <br>
-Evaluating this expression directly may apply huge cancellation error,
-however it may be transformed to the next equivalent form:<br>
- <span style="font-family: Courier New,Courier,monospace;"><br>
-(A * A * a - B * B * b) / (A * sqrt(a) + B * sqrt(b)).</span><br>
- <br>
-The numerator and denominator of this expression can be computed
-directly, as those won't lead to any cancellation errors.<br>
- <br>
-In general case the robust sqrt expression structure allows to evaluate
-the following set of expressions:<br>
- <span style="font-family: Courier New,Courier,monospace;"><br>
-sum(A[i] * sqrt(a[i]), i = 1 .. N), N <= 4.</span> </td>
- </tr>
- <tr>
- <td style="background-color: rgb(238, 238, 238);" nowrap="1"> </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 © Andrii Sydorchuk 2010-2013</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>
Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk