geos_390_docs/classgeos_1_1simplify_1_1To...

254 lines
13 KiB
HTML

<!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">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.11"/>
<title>GEOS: geos::simplify::TopologyPreservingSimplifier Class Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
<tbody>
<tr style="height: 56px;">
<td id="projectalign" style="padding-left: 0.5em;">
<div id="projectname">GEOS
&#160;<span id="projectnumber">3.9.1dev</span>
</div>
</td>
</tr>
</tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.11 -->
<div id="navrow1" class="tabs">
<ul class="tablist">
<li><a href="index.html"><span>Main&#160;Page</span></a></li>
<li><a href="pages.html"><span>Related&#160;Pages</span></a></li>
<li><a href="namespaces.html"><span>Namespaces</span></a></li>
<li class="current"><a href="annotated.html"><span>Classes</span></a></li>
<li><a href="files.html"><span>Files</span></a></li>
</ul>
</div>
<div id="navrow2" class="tabs2">
<ul class="tablist">
<li><a href="annotated.html"><span>Class&#160;List</span></a></li>
<li><a href="inherits.html"><span>Class&#160;Hierarchy</span></a></li>
<li><a href="functions.html"><span>Class&#160;Members</span></a></li>
</ul>
</div>
<div id="nav-path" class="navpath">
<ul>
<li class="navelem"><a class="el" href="namespacegeos.html">geos</a></li><li class="navelem"><a class="el" href="namespacegeos_1_1simplify.html">simplify</a></li><li class="navelem"><a class="el" href="classgeos_1_1simplify_1_1TopologyPreservingSimplifier.html">TopologyPreservingSimplifier</a></li> </ul>
</div>
</div><!-- top -->
<div class="header">
<div class="summary">
<a href="#pub-methods">Public Member Functions</a> &#124;
<a href="#pub-static-methods">Static Public Member Functions</a> &#124;
<a href="#pri-attribs">Private Attributes</a> &#124;
<a href="classgeos_1_1simplify_1_1TopologyPreservingSimplifier-members.html">List of all members</a> </div>
<div class="headertitle">
<div class="title">geos::simplify::TopologyPreservingSimplifier Class Reference</div> </div>
</div><!--header-->
<div class="contents">
<p>Simplifies a geometry, ensuring that the result is a valid geometry having the same dimension and number of components as the input.
<a href="classgeos_1_1simplify_1_1TopologyPreservingSimplifier.html#details">More...</a></p>
<p><code>#include &lt;<a class="el" href="TopologyPreservingSimplifier_8h_source.html">TopologyPreservingSimplifier.h</a>&gt;</code></p>
<div class="dynheader">
Collaboration diagram for geos::simplify::TopologyPreservingSimplifier:</div>
<div class="dyncontent">
<div class="center"><div class="zoom"><iframe scrolling="no" frameborder="0" src="classgeos_1_1simplify_1_1TopologyPreservingSimplifier__coll__graph.svg" width="100%" height="431"><p><b>This browser is not able to show SVG: try Firefox, Chrome, Safari, or Opera instead.</b></p></iframe></div>
</div>
<center><span class="legend">[<a href="graph_legend.html">legend</a>]</span></center></div>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-methods"></a>
Public Member Functions</h2></td></tr>
<tr class="memitem:ac49755ec6f280635d1562a38567d74d4"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classgeos_1_1simplify_1_1TopologyPreservingSimplifier.html#ac49755ec6f280635d1562a38567d74d4">TopologyPreservingSimplifier</a> (const <a class="el" href="classgeos_1_1geom_1_1Geometry.html">geom::Geometry</a> *geom)</td></tr>
<tr class="separator:ac49755ec6f280635d1562a38567d74d4"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a9e387d4f27f7bf6284368484b3b5f23c"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classgeos_1_1simplify_1_1TopologyPreservingSimplifier.html#a9e387d4f27f7bf6284368484b3b5f23c">setDistanceTolerance</a> (double tolerance)</td></tr>
<tr class="memdesc:a9e387d4f27f7bf6284368484b3b5f23c"><td class="mdescLeft">&#160;</td><td class="mdescRight">Sets the distance tolerance for the simplification. <a href="#a9e387d4f27f7bf6284368484b3b5f23c">More...</a><br /></td></tr>
<tr class="separator:a9e387d4f27f7bf6284368484b3b5f23c"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a4a88ca1664b7c4955a30342f7a3cf349"><td class="memItemLeft" align="right" valign="top">std::unique_ptr&lt; <a class="el" href="classgeos_1_1geom_1_1Geometry.html">geom::Geometry</a> &gt;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classgeos_1_1simplify_1_1TopologyPreservingSimplifier.html#a4a88ca1664b7c4955a30342f7a3cf349">getResultGeometry</a> ()</td></tr>
<tr class="separator:a4a88ca1664b7c4955a30342f7a3cf349"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-static-methods"></a>
Static Public Member Functions</h2></td></tr>
<tr class="memitem:aee60d91e45049364f2431e60b43abfc9"><td class="memItemLeft" align="right" valign="top">static std::unique_ptr&lt; <a class="el" href="classgeos_1_1geom_1_1Geometry.html">geom::Geometry</a> &gt;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classgeos_1_1simplify_1_1TopologyPreservingSimplifier.html#aee60d91e45049364f2431e60b43abfc9">simplify</a> (const <a class="el" href="classgeos_1_1geom_1_1Geometry.html">geom::Geometry</a> *geom, double tolerance)</td></tr>
<tr class="separator:aee60d91e45049364f2431e60b43abfc9"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pri-attribs"></a>
Private Attributes</h2></td></tr>
<tr class="memitem:a95aa253921dff154fae7edc16ebd1eeb"><td class="memItemLeft" align="right" valign="top">const <a class="el" href="classgeos_1_1geom_1_1Geometry.html">geom::Geometry</a> *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classgeos_1_1simplify_1_1TopologyPreservingSimplifier.html#a95aa253921dff154fae7edc16ebd1eeb">inputGeom</a></td></tr>
<tr class="separator:a95aa253921dff154fae7edc16ebd1eeb"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a5f6cc23987ed05017c1f28830f173e18"><td class="memItemLeft" align="right" valign="top">std::unique_ptr&lt; <a class="el" href="classgeos_1_1simplify_1_1TaggedLinesSimplifier.html">TaggedLinesSimplifier</a> &gt;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classgeos_1_1simplify_1_1TopologyPreservingSimplifier.html#a5f6cc23987ed05017c1f28830f173e18">lineSimplifier</a></td></tr>
<tr class="separator:a5f6cc23987ed05017c1f28830f173e18"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<div class="textblock"><p>Simplifies a geometry, ensuring that the result is a valid geometry having the same dimension and number of components as the input. </p>
<p>The simplification uses a maximum distance difference algorithm similar to the one used in the Douglas-Peucker algorithm.</p>
<p>In particular, if the input is an areal geometry ( Polygon or MultiPolygon )</p>
<ul>
<li>The result has the same number of shells and holes (rings) as the input, in the same order</li>
<li>The result rings touch at <b>no more</b> than the number of touching point in the input (although they may touch at fewer points) </li>
</ul>
<p>Definition at line <a class="el" href="TopologyPreservingSimplifier_8h_source.html#l00057">57</a> of file <a class="el" href="TopologyPreservingSimplifier_8h_source.html">TopologyPreservingSimplifier.h</a>.</p>
</div><h2 class="groupheader">Constructor &amp; Destructor Documentation</h2>
<a class="anchor" id="ac49755ec6f280635d1562a38567d74d4"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">geos::simplify::TopologyPreservingSimplifier::TopologyPreservingSimplifier </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="classgeos_1_1geom_1_1Geometry.html">geom::Geometry</a> *&#160;</td>
<td class="paramname"><em>geom</em></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
</div>
</div>
<h2 class="groupheader">Member Function Documentation</h2>
<a class="anchor" id="a4a88ca1664b7c4955a30342f7a3cf349"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">std::unique_ptr&lt;<a class="el" href="classgeos_1_1geom_1_1Geometry.html">geom::Geometry</a>&gt; geos::simplify::TopologyPreservingSimplifier::getResultGeometry </td>
<td>(</td>
<td class="paramname"></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
</div>
</div>
<a class="anchor" id="a9e387d4f27f7bf6284368484b3b5f23c"></a>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void geos::simplify::TopologyPreservingSimplifier::setDistanceTolerance </td>
<td>(</td>
<td class="paramtype">double&#160;</td>
<td class="paramname"><em>tolerance</em></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Sets the distance tolerance for the simplification. </p>
<p>All vertices in the simplified geometry will be within this distance of the original geometry. The tolerance value must be non-negative. A tolerance value of zero is effectively a no-op.</p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">tolerance</td><td>the approximation tolerance to use </td></tr>
</table>
</dd>
</dl>
</div>
</div>
<a class="anchor" id="aee60d91e45049364f2431e60b43abfc9"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">static std::unique_ptr&lt;<a class="el" href="classgeos_1_1geom_1_1Geometry.html">geom::Geometry</a>&gt; geos::simplify::TopologyPreservingSimplifier::simplify </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="classgeos_1_1geom_1_1Geometry.html">geom::Geometry</a> *&#160;</td>
<td class="paramname"><em>geom</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">double&#160;</td>
<td class="paramname"><em>tolerance</em>&#160;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">static</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
</div>
</div>
<h2 class="groupheader">Member Data Documentation</h2>
<a class="anchor" id="a95aa253921dff154fae7edc16ebd1eeb"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">const <a class="el" href="classgeos_1_1geom_1_1Geometry.html">geom::Geometry</a>* geos::simplify::TopologyPreservingSimplifier::inputGeom</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Definition at line <a class="el" href="TopologyPreservingSimplifier_8h_source.html#l00083">83</a> of file <a class="el" href="TopologyPreservingSimplifier_8h_source.html">TopologyPreservingSimplifier.h</a>.</p>
</div>
</div>
<a class="anchor" id="a5f6cc23987ed05017c1f28830f173e18"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">std::unique_ptr&lt;<a class="el" href="classgeos_1_1simplify_1_1TaggedLinesSimplifier.html">TaggedLinesSimplifier</a>&gt; geos::simplify::TopologyPreservingSimplifier::lineSimplifier</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Definition at line <a class="el" href="TopologyPreservingSimplifier_8h_source.html#l00085">85</a> of file <a class="el" href="TopologyPreservingSimplifier_8h_source.html">TopologyPreservingSimplifier.h</a>.</p>
</div>
</div>
<hr/>The documentation for this class was generated from the following file:<ul>
<li><a class="el" href="TopologyPreservingSimplifier_8h_source.html">TopologyPreservingSimplifier.h</a></li>
</ul>
</div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated by &#160;<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/>
</a> 1.8.11
</small></address>
</body>
</html>