blob: cd5802378c66ce8bd3c27e57ec0d566eff985694 [file] [log] [blame]
<!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" 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"><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">
<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 border="0" src="images/boost.png" width="277" height="86"><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><a href="index.htm">Boost.Polygon Main Page</a></li>
<li><a href="gtl_design_overview.htm">Design Overview</a></li>
<li><a href="gtl_isotropy.htm">Isotropy</a></li>
<li><a href="gtl_coordinate_concept.htm">Coordinate Concept</a></li>
<li><a href="gtl_interval_concept.htm">Interval Concept</a></li>
<li><a href="gtl_point_concept.htm">Point Concept</a></li>
<li><a href="gtl_rectangle_concept.htm">Rectangle Concept</a></li>
<li><a href="gtl_polygon_90_concept.htm">Polygon 90 Concept</a></li>
<li><a href="gtl_polygon_90_with_holes_concept.htm">Polygon 90 With Holes Concept</a></li>
<li><a href="gtl_polygon_45_concept.htm">Polygon 45 Concept</a></li>
<li><a href="gtl_polygon_45_with_holes_concept.htm">Polygon 45 With Holes Concept</a></li>
<li><a href="gtl_polygon_concept.htm">Polygon Concept</a></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><a href="gtl_polygon_set_concept.htm">Polygon Set Concept</a></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><a href="gtl_property_merge_45.htm">Property Merge 45</a></li>
<li><a href="gtl_property_merge.htm">Property Merge</a></li>
</ul>
<h3 class="navbar">Other Resources</h3>
<ul>
<li><a href="GTL_boostcon2009.pdf">GTL Boostcon 2009 Paper</a></li>
<li><a href="GTL_boostcon_draft03.pdf">GTL Boostcon 2009
Presentation</a></li>
<li><a href="analysis.htm">Performance Analysis</a></li>
<li><a href="gtl_tutorial.htm">Layout Versus Schematic Tutorial</a></li>
<li><a href="gtl_minkowski_tutorial.htm">Minkowski Sum Tutorial</a></li>
</ul>
</div>
<h3 class="navbar">Polygon Sponsor</h3>
<div style="padding: 5px;" align="center">
<img border="0" src="images/intlogo.gif" width="127" height="51">
</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>The following is the declaration of the property merge algorithm.<p>
<font face="Courier New">template &lt;typename coordinate_type, typename
property_type&gt;<br>
class property_merge_90;</font><p>The property algorithm computes the n-layer
map overlay of input polygon sets.&nbsp; Each input geometry is inserted along
with a property value.&nbsp; The property type can be anything suitable for use
as an element of a std::set.&nbsp; Multiple geometry objects can be separately
inserted with the same property value.&nbsp; To store the result of this
operation a fairly complex container is required.&nbsp; Resulting geometries are
associated with unique subsets of property values of the input geometry.&nbsp;
Two suitable containers for storing the result of a property merge operation
are:<p><font face="Courier New">std::map&lt;std::set&lt;property_type&gt;, polygon_90_set_data&lt;coordinate_type&gt;
&gt;<br>
std::map&lt;std::vector&lt;property_type&gt;, polygon_90_set_data&lt;coordinate_type&gt; &gt;</font><p>
Example code <a href="gtl_property_merge_usage.htm">property_merge_usage.cpp</a>
demonstrates using the n-layer map-overlay algorithm on polygon 90 data.<h2>Member Functions</h2>
<table border="1" width="100%" id="table1">
<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&amp; 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&lt;coordinate_type&gt;&amp; ps,<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
const property_type&amp; property)</font></td>
<td>I<font face="Times New Roman">nsert a polygon set with an associated
property.</font>&nbsp; Linear wrt vertices inserted.</td>
</tr>
<tr>
<td width="586">
<font face="Courier New">
template &lt;class GeoObjT&gt;<br>
void <b>insert</b>(const GeoObjT&amp; geoObj,<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
const property_type&amp; property)</font></td>
<td>Insert a geometry object that is a refinement of polygon 90 set with
an associated property.&nbsp; Linear wrt vertices inserted.</td>
</tr>
<tr>
<td width="586">
<font face="Courier New">
template &lt;typename result_type&gt;<br>
void <b>merge</b>(result_type&amp; result)</font></td>
<td>Accepts a container object that conforms to the expectations defined
above.&nbsp; Performs property merge and populates the container
object.&nbsp; O(n log n) runtime wrt. vertices + intersections.</td>
</tr>
</table>
<tr>
<td style="background-color: rgb(238, 238, 238);" nowrap="1" valign="top">
&nbsp;</td>
<td style="padding-left: 10px; padding-right: 10px; padding-bottom: 10px;" valign="top" width="100%">
<table class="docinfo" rules="none" frame="void" id="table2">
<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</a>)</td>
</tr>
</table>
</html>