📄 classogrlinearring.html
字号:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"><html><head><meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1"><title>OGR: OGRLinearRing Class Reference</title><link href="doxygen.css" rel="stylesheet" type="text/css"><link href="tabs.css" rel="stylesheet" type="text/css"></head><body><!-- Generated by Doxygen 1.5.1 --><div class="tabs"> <ul> <li><a href="index.html"><span>Main Page</span></a></li> <li id="current"><a href="annotated.html"><span>Classes</span></a></li> <li><a href="files.html"><span>Files</span></a></li> <li><a href="dirs.html"><span>Directories</span></a></li> <li><a href="pages.html"><span>Related Pages</span></a></li> </ul></div><div class="tabs"> <ul> <li><a href="annotated.html"><span>Class List</span></a></li> <li><a href="hierarchy.html"><span>Class Hierarchy</span></a></li> <li><a href="functions.html"><span>Class Members</span></a></li> </ul></div><h1>OGRLinearRing Class Reference</h1><!-- doxytag: class="OGRLinearRing" --><!-- doxytag: inherits="OGRLineString" --><code>#include <<a class="el" href="ogr__geometry_8h-source.html">ogr_geometry.h</a>></code><p><p>Inheritance diagram for OGRLinearRing:<p><center><img src="classOGRLinearRing.png" usemap="#OGRLinearRing_map" border="0" alt=""></center><map name="OGRLinearRing_map"><area href="classOGRLineString.html" alt="OGRLineString" shape="rect" coords="0,112,100,136"><area href="classOGRCurve.html" alt="OGRCurve" shape="rect" coords="0,56,100,80"><area href="classOGRGeometry.html" alt="OGRGeometry" shape="rect" coords="0,0,100,24"></map><a href="classOGRLinearRing-members.html">List of all members.</a><table border="0" cellpadding="0" cellspacing="0"><tr><td></td></tr><tr><td colspan="2"><br><h2>Public Member Functions</h2></td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top">virtual const char * </td><td class="memItemRight" valign="bottom"><a class="el" href="classOGRLinearRing.html#4151980d064c7278112d3813583be6e7">getGeometryName</a> () const</td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top">virtual <a class="el" href="classOGRGeometry.html">OGRGeometry</a> * </td><td class="memItemRight" valign="bottom"><a class="el" href="classOGRLinearRing.html#33e70d13f0953a438417714ab8ebb299">clone</a> () const</td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top">virtual int </td><td class="memItemRight" valign="bottom"><a class="el" href="classOGRLinearRing.html#62f71db0ea1f0335b3bb497941ce3d61">isClockwise</a> () const</td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void </td><td class="memItemRight" valign="bottom"><a class="el" href="classOGRLinearRing.html#78d316c3e146dc8ee23a58336162d68a">closeRings</a> ()</td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top">virtual double </td><td class="memItemRight" valign="bottom"><a class="el" href="classOGRLinearRing.html#4b1f00a431791f40f5df4907d1233fe8">get_Area</a> () const</td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top">virtual int </td><td class="memItemRight" valign="bottom"><a class="el" href="classOGRLinearRing.html#bbcbb21f4655dab76dbdc40e264695a4">WkbSize</a> () const</td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top">virtual OGRErr </td><td class="memItemRight" valign="bottom"><a class="el" href="classOGRLinearRing.html#80fa5c79e98e92a1b58f30b9904c272c">importFromWkb</a> (unsigned char *, int=-1)</td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top">virtual OGRErr </td><td class="memItemRight" valign="bottom"><a class="el" href="classOGRLinearRing.html#770bb1ca2d82bbba5876923dd2dd3471">exportToWkb</a> (OGRwkbByteOrder, unsigned char *) const</td></tr><tr><td colspan="2"><br><h2>Friends</h2></td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="f507ab8a6499544e21f845f5a3d3e123"></a><!-- doxytag: member="OGRLinearRing::OGRPolygon" ref="f507ab8a6499544e21f845f5a3d3e123" args="" -->class </td><td class="memItemRight" valign="bottom"><a class="el" href="classOGRLinearRing.html#f507ab8a6499544e21f845f5a3d3e123">OGRPolygon</a></td></tr></table><hr><a name="_details"></a><h2>Detailed Description</h2>Concrete representation of a closed ring.<p>This class is functionally equivelent to an <a class="el" href="classOGRLineString.html">OGRLineString</a>, but has a separate identity to maintain alignment with the OpenGIS simple feature data model. It exists to serve as a component of an <a class="el" href="classOGRPolygon.html">OGRPolygon</a>. <p><hr><h2>Member Function Documentation</h2><a class="anchor" name="4151980d064c7278112d3813583be6e7"></a><!-- doxytag: member="OGRLinearRing::getGeometryName" ref="4151980d064c7278112d3813583be6e7" args="() const" --><div class="memitem"><div class="memproto"> <table class="memname"> <tr> <td class="memname">const char * OGRLinearRing::getGeometryName </td> <td>(</td> <td class="paramname"> </td> <td> ) </td> <td width="100%"> const<code> [virtual]</code></td> </tr> </table></div><div class="memdoc"><p>Fetch WKT name for geometry type.<p>There is no SFCOM analog to this method.<p>This method is the same as the C function <a class="el" href="ogr__api_8h.html#18121f835b2fb724a0c1a87beb1a437a">OGR_G_GetGeometryName()</a>.<p><dl class="return" compact><dt><b>Returns:</b></dt><dd>name used for this geometry type in well known text format. The returned pointer is to a static internal string and should not be modified or freed. </dd></dl><p>Reimplemented from <a class="el" href="classOGRLineString.html#5954c255e94fca6a3c002c00517cd0ef">OGRLineString</a>.</div></div><p><a class="anchor" name="33e70d13f0953a438417714ab8ebb299"></a><!-- doxytag: member="OGRLinearRing::clone" ref="33e70d13f0953a438417714ab8ebb299" args="() const" --><div class="memitem"><div class="memproto"> <table class="memname"> <tr> <td class="memname"><a class="el" href="classOGRGeometry.html">OGRGeometry</a> * OGRLinearRing::clone </td> <td>(</td> <td class="paramname"> </td> <td> ) </td> <td width="100%"> const<code> [virtual]</code></td> </tr> </table></div><div class="memdoc"><p>Make a copy of this object.<p>This method relates to the SFCOM IGeometry::clone() method.<p>This method is the same as the C function <a class="el" href="ogr__api_8h.html#1725918932da7d59f9ee72829ac171fa">OGR_G_Clone()</a>.<p><dl class="return" compact><dt><b>Returns:</b></dt><dd>a new object instance with the same geometry, and spatial reference system as the original. </dd></dl><p>Reimplemented from <a class="el" href="classOGRLineString.html#bda61341d48aff2d374403c1cce69c56">OGRLineString</a>.</div></div><p><a class="anchor" name="62f71db0ea1f0335b3bb497941ce3d61"></a><!-- doxytag: member="OGRLinearRing::isClockwise" ref="62f71db0ea1f0335b3bb497941ce3d61" args="() const" --><div class="memitem"><div class="memproto"> <table class="memname"> <tr> <td class="memname">int OGRLinearRing::isClockwise </td> <td>(</td> <td class="paramname"> </td> <td> ) </td> <td width="100%"> const<code> [virtual]</code></td> </tr> </table></div><div class="memdoc"><p>Returns TRUE if the ring has clockwise winding.<p><dl class="return" compact><dt><b>Returns:</b></dt><dd>TRUE if clockwise otherwise FALSE. </dd></dl></div></div><p><a class="anchor" name="78d316c3e146dc8ee23a58336162d68a"></a><!-- doxytag: member="OGRLinearRing::closeRings" ref="78d316c3e146dc8ee23a58336162d68a" args="()" --><div class="memitem"><div class="memproto"> <table class="memname"> <tr> <td class="memname">void OGRLinearRing::closeRings </td> <td>(</td> <td class="paramname"> </td> <td> ) </td> <td width="100%"><code> [virtual]</code></td> </tr> </table></div><div class="memdoc"><p>Force rings to be closed.<p>If this geometry, or any contained geometries has polygon rings that are not closed, they will be closed by adding the starting point at the end. <p>Reimplemented from <a class="el" href="classOGRGeometry.html#eb6cf249316b3046e0d4f77ec400e844">OGRGeometry</a>.</div></div><p><a class="anchor" name="4b1f00a431791f40f5df4907d1233fe8"></a><!-- doxytag: member="OGRLinearRing::get_Area" ref="4b1f00a431791f40f5df4907d1233fe8" args="() const" --><div class="memitem"><div class="memproto"> <table class="memname"> <tr> <td class="memname">double OGRLinearRing::get_Area </td> <td>(</td> <td class="paramname"> </td> <td> ) </td> <td width="100%"> const<code> [virtual]</code></td> </tr> </table></div><div class="memdoc"><p>Compute area of ring.<p>The area is computed according to Green's Theorem:<p>Area is "Sum(x(i)*y(i+1) - x(i+1)*y(i))/2" for i = 0 to pointCount-1, assuming the last point is a duplicate of the first.<p><dl class="return" compact><dt><b>Returns:</b></dt><dd>computed area. </dd></dl></div></div><p><a class="anchor" name="bbcbb21f4655dab76dbdc40e264695a4"></a><!-- doxytag: member="OGRLinearRing::WkbSize" ref="bbcbb21f4655dab76dbdc40e264695a4" args="() const" --><div class="memitem"><div class="memproto"> <table class="memname"> <tr> <td class="memname">int OGRLinearRing::WkbSize </td> <td>(</td> <td class="paramname"> </td> <td> ) </td> <td width="100%"> const<code> [virtual]</code></td> </tr> </table></div><div class="memdoc"><p>Returns size of related binary representation.<p>This method returns the exact number of bytes required to hold the well known binary representation of this geometry object. Its computation may be slightly expensive for complex geometries.<p>This method relates to the SFCOM IWks::WkbSize() method.<p>This method is the same as the C function <a class="el" href="ogr__api_8h.html#5f7035a933b957a9d453184c154c237c">OGR_G_WkbSize()</a>.<p><dl class="return" compact><dt><b>Returns:</b></dt><dd>size of binary representation in bytes. </dd></dl><p>Reimplemented from <a class="el" href="classOGRLineString.html#9cd71578349ee3e6fec3d65dc6f17a0e">OGRLineString</a>.</div></div><p><a class="anchor" name="80fa5c79e98e92a1b58f30b9904c272c"></a><!-- doxytag: member="OGRLinearRing::importFromWkb" ref="80fa5c79e98e92a1b58f30b9904c272c" args="(unsigned char *, int=-1)" --><div class="memitem"><div class="memproto"> <table class="memname"> <tr> <td class="memname">OGRErr OGRLinearRing::importFromWkb </td> <td>(</td> <td class="paramtype">unsigned char * </td> <td class="paramname"> <em>pabyData</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">int </td> <td class="paramname"> <em>nSize</em> = <code>-1</code></td><td> </td> </tr> <tr> <td></td> <td>)</td> <td></td><td></td><td width="100%"><code> [virtual]</code></td> </tr> </table></div><div class="memdoc"><p>Assign geometry from well known binary data.<p>The object must have already been instantiated as the correct derived type of geometry object to match the binaries type. This method is used by the <a class="el" href="classOGRGeometryFactory.html">OGRGeometryFactory</a> class, but not normally called by application code.<p>This method relates to the SFCOM IWks::ImportFromWKB() method.<p>This method is the same as the C function <a class="el" href="ogr__api_8h.html#fa5a9173aa3b10a4db09ed696a92ba4a">OGR_G_ImportFromWkb()</a>.<p><dl compact><dt><b>Parameters:</b></dt><dd> <table border="0" cellspacing="2" cellpadding="0"> <tr><td valign="top"></td><td valign="top"><em>pabyData</em> </td><td>the binary input data. </td></tr> <tr><td valign="top"></td><td valign="top"><em>nSize</em> </td><td>the size of pabyData in bytes, or zero if not known.</td></tr> </table></dl><dl class="return" compact><dt><b>Returns:</b></dt><dd>OGRERR_NONE if all goes well, otherwise any of OGRERR_NOT_ENOUGH_DATA, OGRERR_UNSUPPORTED_GEOMETRY_TYPE, or OGRERR_CORRUPT_DATA may be returned. </dd></dl><p>Reimplemented from <a class="el" href="classOGRLineString.html#e594aeb14deec56cf957ce54a9f299a7">OGRLineString</a>.</div></div><p><a class="anchor" name="770bb1ca2d82bbba5876923dd2dd3471"></a><!-- doxytag: member="OGRLinearRing::exportToWkb" ref="770bb1ca2d82bbba5876923dd2dd3471" args="(OGRwkbByteOrder, unsigned char *) const" --><div class="memitem"><div class="memproto"> <table class="memname"> <tr> <td class="memname">OGRErr OGRLinearRing::exportToWkb </td> <td>(</td> <td class="paramtype">OGRwkbByteOrder </td> <td class="paramname"> <em>eByteOrder</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">unsigned char * </td> <td class="paramname"> <em>pabyData</em></td><td> </td> </tr> <tr> <td></td> <td>)</td> <td></td><td></td><td width="100%"> const<code> [virtual]</code></td> </tr> </table></div><div class="memdoc"><p>Convert a geometry into well known binary format.<p>This method relates to the SFCOM IWks::ExportToWKB() method.<p>This method is the same as the C function <a class="el" href="ogr__api_8h.html#d5c94ae76c09774dba8725c24daeefd6">OGR_G_ExportToWkb()</a>.<p><dl compact><dt><b>Parameters:</b></dt><dd> <table border="0" cellspacing="2" cellpadding="0"> <tr><td valign="top"></td><td valign="top"><em>eByteOrder</em> </td><td>One of wkbXDR or wkbNDR indicating MSB or LSB byte order respectively. </td></tr> <tr><td valign="top"></td><td valign="top"><em>pabyData</em> </td><td>a buffer into which the binary representation is written. This buffer must be at least <a class="el" href="classOGRGeometry.html#68215bd90d675b7627a798b162c54ab1">OGRGeometry::WkbSize()</a> byte in size.</td></tr> </table></dl><dl class="return" compact><dt><b>Returns:</b></dt><dd>Currently OGRERR_NONE is always returned. </dd></dl><p>Reimplemented from <a class="el" href="classOGRLineString.html#260edbc73c2bd4bde55d759cbc804040">OGRLineString</a>.</div></div><p><hr>The documentation for this class was generated from the following files:<ul><li><a class="el" href="ogr__geometry_8h-source.html">ogr_geometry.h</a><li>ogrlinearring.cpp</ul><hr>Generated for GDAL by <a href="http://www.doxygen.org/index.html"><img src="doxygen.png" alt="doxygen" align="middle" border="0"></a> 1.5.1.</body></html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -