[postgis-tickets] [SCM] PostGIS branch master updated. 3.1.0alpha3-27-g2193689

git at osgeo.org git at osgeo.org
Sun Dec 6 15:01:59 PST 2020


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "PostGIS".

The branch, master has been updated
       via  219368993d12c21a14555df16ec2814b4a2daedd (commit)
      from  9abc7eabd179e61dce85b543f25a9a3f9de61cc7 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 219368993d12c21a14555df16ec2814b4a2daedd
Author: Martin Davis <mtnclimb at gmail.com>
Date:   Sun Dec 6 15:01:53 2020 -0800

    Move Doc Ref functions to better sections

diff --git a/doc/reference_editor.xml b/doc/reference_editor.xml
index ddb0de9..671235b 100644
--- a/doc/reference_editor.xml
+++ b/doc/reference_editor.xml
@@ -1,5 +1,12 @@
 <?xml version="1.0" encoding="UTF-8"?>
   <sect1 id="Geometry_Editors">
+     <sect1info>
+        <abstract>
+        <para>These functions create modified geometries by changing type, structure or vertices.
+        </para>
+        </abstract>
+    </sect1info>
+
 	  <title>Geometry Editors</title>
 
 		<refentry id="ST_AddPoint">
@@ -194,6 +201,203 @@ MULTILINESTRING((0 0, 1 1), (2 2, 3 3))
 			</refsection>
 		</refentry>
 
+    <refentry id="ST_CurveToLine">
+      <refnamediv>
+        <refname>ST_CurveToLine</refname>
+
+        <refpurpose>Converts a geometry containing curves to a linear geometry.</refpurpose>
+      </refnamediv>
+
+      <refsynopsisdiv>
+        <funcsynopsis>
+          <funcprototype>
+            <funcdef>geometry <function>ST_CurveToLine</function></funcdef>
+            <paramdef><type>geometry</type> <parameter>curveGeom</parameter></paramdef>
+            <paramdef><type>float</type> <parameter>tolerance</parameter></paramdef>
+            <paramdef choice="opt"><type>integer</type> <parameter>tolerance_type</parameter></paramdef>
+            <paramdef choice="opt"><type>integer</type> <parameter>flags</parameter></paramdef>
+          </funcprototype>
+        </funcsynopsis>
+      </refsynopsisdiv>
+
+      <refsection>
+        <title>Description</title>
+
+        <para>Converts a CIRCULAR STRING to regular LINESTRING or CURVEPOLYGON to POLYGON or MULTISURFACE to MULTIPOLYGON. Useful for outputting to devices that can't support CIRCULARSTRING geometry types</para>
+
+        <para>Converts a given geometry to a linear geometry.
+        Each curved geometry or segment is converted into a linear
+approximation using the given `tolerance` and options (32 segments per
+quadrant and no options by default).</para>
+
+    <para>
+The 'tolerance_type' argument determines interpretation of the
+`tolerance` argument. It can take the following values:
+      <itemizedlist>
+        <listitem>
+          <para>0 (default): Tolerance is max segments per quadrant.</para>
+        </listitem>
+        <listitem>
+          <para>1: Tolerance is max-deviation of line from curve, in source units.</para>
+        </listitem>
+        <listitem>
+          <para>2: Tolerance is max-angle, in radians, between generating radii.</para>
+        </listitem>
+      </itemizedlist>
+    </para>
+
+    <para>
+The 'flags' argument is a bitfield. 0 by default.
+Supported bits are:
+      <itemizedlist>
+        <listitem>
+          <para>1: Symmetric (orientation idependent) output.</para>
+        </listitem>
+        <listitem>
+          <para>2: Retain angle, avoids reducing angles (segment lengths) when producing symmetric output. Has no effect when Symmetric flag is off.</para>
+        </listitem>
+      </itemizedlist>
+    </para>
+
+        <para>Availability: 1.3.0</para>
+    <para>Enhanced: 2.4.0 added support for max-deviation and max-angle tolerance, and for symmetric output.</para>
+    <para>Enhanced: 3.0.0 implemented a minimum number of segments per linearized arc to prevent topological collapse.</para>
+
+        <para>&sfs_compliant;</para>
+        <para>&sqlmm_compliant; SQL-MM 3: 7.1.7</para>
+        <para>&Z_support;</para>
+        <para>&curve_support;</para>
+      </refsection>
+
+
+      <refsection>
+        <title>Examples</title>
+
+        <programlisting>SELECT ST_AsText(ST_CurveToLine(ST_GeomFromText('CIRCULARSTRING(220268 150415,220227 150505,220227 150406)')));
+
+--Result --
+ LINESTRING(220268 150415,220269.95064912 150416.539364228,220271.823415575 150418.17258804,220273.613787707 150419.895736857,
+ 220275.317452352 150421.704659462,220276.930305234 150423.594998003,220278.448460847 150425.562198489,
+ 220279.868261823 150427.60152176,220281.186287736 150429.708054909,220282.399363347 150431.876723113,
+ 220283.50456625 150434.10230186,220284.499233914 150436.379429536,220285.380970099 150438.702620341,220286.147650624 150441.066277505,
+ 220286.797428488 150443.464706771,220287.328738321 150445.892130112,220287.740300149 150448.342699654,
+ 220288.031122486 150450.810511759,220288.200504713 150453.289621251,220288.248038775 150455.77405574,
+ 220288.173610157 150458.257830005,220287.977398166 150460.734960415,220287.659875492 150463.199479347,
+ 220287.221807076 150465.64544956,220286.664248262 150468.066978495,220285.988542259 150470.458232479,220285.196316903 150472.81345077,
+ 220284.289480732 150475.126959442,220283.270218395 150477.39318505,220282.140985384 150479.606668057,
+ 220280.90450212 150481.762075989,220279.5637474 150483.85421628,220278.12195122 150485.87804878,
+ 220276.582586992 150487.828697901,220274.949363179 150489.701464356,220273.226214362 150491.491836488,
+ 220271.417291757 150493.195501133,220269.526953216 150494.808354014,220267.559752731 150496.326509628,
+ 220265.520429459 150497.746310603,220263.41389631 150499.064336517,220261.245228106 150500.277412127,
+ 220259.019649359 150501.38261503,220256.742521683 150502.377282695,220254.419330878 150503.259018879,
+ 220252.055673714 150504.025699404,220249.657244448 150504.675477269,220247.229821107 150505.206787101,
+ 220244.779251566 150505.61834893,220242.311439461 150505.909171266,220239.832329968 150506.078553494,
+ 220237.347895479 150506.126087555,220234.864121215 150506.051658938,220232.386990804 150505.855446946,
+ 220229.922471872 150505.537924272,220227.47650166 150505.099855856,220225.054972724 150504.542297043,
+ 220222.663718741 150503.86659104,220220.308500449 150503.074365683,
+ 220217.994991777 150502.167529512,220215.72876617 150501.148267175,
+ 220213.515283163 150500.019034164,220211.35987523 150498.7825509,
+ 220209.267734939 150497.441796181,220207.243902439 150496,
+ 220205.293253319 150494.460635772,220203.420486864 150492.82741196,220201.630114732 150491.104263143,
+ 220199.926450087 150489.295340538,220198.313597205 150487.405001997,220196.795441592 150485.437801511,
+ 220195.375640616 150483.39847824,220194.057614703 150481.291945091,220192.844539092 150479.123276887,220191.739336189 150476.89769814,
+ 220190.744668525 150474.620570464,220189.86293234 150472.297379659,220189.096251815 150469.933722495,
+ 220188.446473951 150467.535293229,220187.915164118 150465.107869888,220187.50360229 150462.657300346,
+ 220187.212779953 150460.189488241,220187.043397726 150457.710378749,220186.995863664 150455.22594426,
+ 220187.070292282 150452.742169995,220187.266504273 150450.265039585,220187.584026947 150447.800520653,
+ 220188.022095363 150445.35455044,220188.579654177 150442.933021505,220189.25536018 150440.541767521,
+ 220190.047585536 150438.18654923,220190.954421707 150435.873040558,220191.973684044 150433.60681495,
+ 220193.102917055 150431.393331943,220194.339400319 150429.237924011,220195.680155039 150427.14578372,220197.12195122 150425.12195122,
+ 220198.661315447 150423.171302099,220200.29453926 150421.298535644,220202.017688077 150419.508163512,220203.826610682 150417.804498867,
+ 220205.716949223 150416.191645986,220207.684149708 150414.673490372,220209.72347298 150413.253689397,220211.830006129 150411.935663483,
+ 220213.998674333 150410.722587873,220216.22425308 150409.61738497,220218.501380756 150408.622717305,220220.824571561 150407.740981121,
+ 220223.188228725 150406.974300596,220225.586657991 150406.324522731,220227 150406)
+
+--3d example
+SELECT ST_AsEWKT(ST_CurveToLine(ST_GeomFromEWKT('CIRCULARSTRING(220268 150415 1,220227 150505 2,220227 150406 3)')));
+Output
+------
+ LINESTRING(220268 150415 1,220269.95064912 150416.539364228 1.0181172856673,
+ 220271.823415575 150418.17258804 1.03623457133459,220273.613787707 150419.895736857 1.05435185700189,....AD INFINITUM ....
+    220225.586657991 150406.324522731 1.32611114201132,220227 150406 3)
+
+--use only 2 segments to approximate quarter circle
+SELECT ST_AsText(ST_CurveToLine(ST_GeomFromText('CIRCULARSTRING(220268 150415,220227 150505,220227 150406)'),2));
+st_astext
+------------------------------
+ LINESTRING(220268 150415,220287.740300149 150448.342699654,220278.12195122 150485.87804878,
+ 220244.779251566 150505.61834893,220207.243902439 150496,220187.50360229 150462.657300346,
+ 220197.12195122 150425.12195122,220227 150406)
+
+-- Ensure approximated line is no further than 20 units away from
+-- original curve, and make the result direction-neutral
+SELECT ST_AsText(ST_CurveToLine(
+ 'CIRCULARSTRING(0 0,100 -100,200 0)'::geometry,
+    20, -- Tolerance
+    1, -- Above is max distance between curve and line
+    1  -- Symmetric flag
+));
+st_astext
+-------------------------------------------------------------------------------------------
+ LINESTRING(0 0,50 -86.6025403784438,150 -86.6025403784439,200 -1.1331077795296e-13,200 0)
+
+
+        </programlisting>
+      </refsection>
+
+      <!-- Optionally add a "See Also" section -->
+      <refsection>
+        <title>See Also</title>
+
+        <para><xref linkend="ST_LineToCurve" /></para>
+      </refsection>
+    </refentry>
+
+    <refentry id="ST_FlipCoordinates">
+      <refnamediv>
+        <refname>ST_FlipCoordinates</refname>
+        <refpurpose>Returns a version of a geometry with X and Y axis flipped. </refpurpose>
+      </refnamediv>
+
+      <refsynopsisdiv>
+        <funcsynopsis>
+          <funcprototype>
+            <funcdef>geometry <function>ST_FlipCoordinates</function></funcdef>
+            <paramdef><type>geometry</type> <parameter>geom</parameter></paramdef>
+          </funcprototype>
+        </funcsynopsis>
+      </refsynopsisdiv>
+
+      <refsection>
+        <title>Description</title>
+        <para>Returns a version of the given geometry with X and Y axis flipped.
+        Useful for fixing geometries which contain coordinates expressed as latitude/longitude (Y,X).</para>
+        <para>Availability: 2.0.0</para>
+        <para>&curve_support;</para>
+        <para>&Z_support;</para>
+        <para>&M_support;</para>
+        <para>&P_support;</para>
+        <para>&T_support;</para>
+      </refsection>
+
+      <refsection>
+        <title>Example</title>
+        <programlisting><![CDATA[
+SELECT ST_AsEWKT(ST_FlipCoordinates(GeomFromEWKT('POINT(1 2)')));
+ st_asewkt
+------------
+POINT(2 1)
+         ]]></programlisting>
+      </refsection>
+
+      <!-- Optionally add a "See Also" section -->
+      <refsection>
+        <title>See Also</title>
+        <para> <xref linkend="ST_SwapOrdinates" /> </para>
+      </refsection>
+
+    </refentry>
+
 	<refentry id="ST_Force2D">
 	  <refnamediv>
 		<refname>ST_Force2D</refname>
@@ -881,6 +1085,75 @@ LINESTRING Z (-30 -29.7 5,-29 -27 11,-30 -29.7 10,-36 -31 5,-45 -33 1,-46 -32 11
 		</refsection>
 	</refentry>
 
+    <refentry id="ST_LineToCurve">
+      <refnamediv>
+        <refname>ST_LineToCurve</refname>
+
+        <refpurpose>Converts a linear geometry to a curved geometry.</refpurpose>
+      </refnamediv>
+
+      <refsynopsisdiv>
+        <funcsynopsis>
+          <funcprototype>
+            <funcdef>geometry <function>ST_LineToCurve</function></funcdef>
+            <paramdef><type>geometry </type> <parameter>geomANoncircular</parameter></paramdef>
+          </funcprototype>
+        </funcsynopsis>
+      </refsynopsisdiv>
+
+      <refsection>
+        <title>Description</title>
+
+        <para>Converts plain LINESTRING/POLYGON to CIRCULAR STRINGs and Curved Polygons.  Note much fewer points are needed to describe the curved equivalent.</para>
+        <note><para>If the input LINESTRING/POLYGON is not curved enough to clearly represent a curve, the function will return the same input geometry.</para></note>
+        <para>Availability: 1.3.0</para>
+        <para>&Z_support;</para>
+        <para>&curve_support;</para>
+      </refsection>
+
+
+      <refsection>
+        <title>Examples</title>
+
+        <programlisting> -- 2D Example
+SELECT ST_AsText(ST_LineToCurve(foo.the_geom)) As curvedastext,ST_AsText(foo.the_geom) As non_curvedastext
+    FROM (SELECT ST_Buffer('POINT(1 3)'::geometry, 3) As the_geom) As foo;
+
+curvedatext                                                            non_curvedastext
+--------------------------------------------------------------------|-----------------------------------------------------------------
+CURVEPOLYGON(CIRCULARSTRING(4 3,3.12132034355964 0.878679656440359, | POLYGON((4 3,3.94235584120969 2.41472903395162,3.77163859753386 1.85194970290473,
+1 0,-1.12132034355965 5.12132034355963,4 3))                        |  3.49440883690764 1.33328930094119,3.12132034355964 0.878679656440359,
+                                                                    |  2.66671069905881 0.505591163092366,2.14805029709527 0.228361402466141,
+                                                                    |  1.58527096604839 0.0576441587903094,1 0,
+                                                                    |  0.414729033951621 0.0576441587903077,-0.148050297095264 0.228361402466137,
+                                                                    |  -0.666710699058802 0.505591163092361,-1.12132034355964 0.878679656440353,
+                                                                    |  -1.49440883690763 1.33328930094119,-1.77163859753386 1.85194970290472
+                                                                    |  --ETC-- ,3.94235584120969 3.58527096604839,4 3))
+
+--3D example
+SELECT ST_AsText(ST_LineToCurve(geom)) As curved, ST_AsText(geom) AS not_curved
+FROM (SELECT ST_Translate(ST_Force3D(ST_Boundary(ST_Buffer(ST_Point(1,3), 2,2))),0,0,3) AS geom) AS foo;
+
+                        curved                        |               not_curved
+------------------------------------------------------+---------------------------------------------------------------------
+ CIRCULARSTRING Z (3 3 3,-1 2.99999999999999 3,3 3 3) | LINESTRING Z (3 3 3,2.4142135623731 1.58578643762691 3,1 1 3,
+                                                      | -0.414213562373092 1.5857864376269 3,-1 2.99999999999999 3,
+                                                      | -0.414213562373101 4.41421356237309 3,
+                                                      | 0.999999999999991 5 3,2.41421356237309 4.4142135623731 3,3 3 3)
+(1 row)
+</programlisting>
+    </refsection>
+
+
+
+      <!-- Optionally add a "See Also" section -->
+      <refsection>
+        <title>See Also</title>
+
+        <para><xref linkend="ST_CurveToLine" /></para>
+      </refsection>
+    </refentry>
+
 	<refentry id="ST_Multi">
 		<refnamediv>
 			<refname>ST_Multi</refname>
@@ -1200,6 +1473,45 @@ UPDATE sometable
 	  </refsection>
 	</refentry>
 
+    <refentry id="ST_RemoveRepeatedPoints">
+      <refnamediv>
+        <refname>ST_RemoveRepeatedPoints</refname>
+        <refpurpose>Returns a version of the given geometry with
+                duplicated points removed.</refpurpose>
+      </refnamediv>
+
+      <refsynopsisdiv>
+        <funcsynopsis>
+          <funcprototype>
+            <funcdef>geometry <function>ST_RemoveRepeatedPoints</function></funcdef>
+            <paramdef><type>geometry</type> <parameter>geom</parameter></paramdef>
+            <paramdef choice="opt"><type>float8</type> <parameter>tolerance</parameter></paramdef>
+          </funcprototype>
+        </funcsynopsis>
+      </refsynopsisdiv>
+
+      <refsection>
+        <title>Description</title>
+        <para>Returns a version of the given geometry with
+                duplicated points removed. Will actually do something only with
+                (multi)lines, (multi)polygons and multipoints but you can safely call it with
+                any kind of geometry. Since simplification occurs on a
+                object-by-object basis you can also feed a GeometryCollection to
+                this function.</para>
+        <para>If the tolerance parameter is provided, vertices within the tolerance
+        of one another will be considered the "same" for the purposes of removal.</para>
+
+        <para>Availability: 2.2.0</para>
+        <para>&P_support;</para>
+        <para>&Z_support;</para>
+      </refsection>
+
+          <refsection>
+            <title>See Also</title>
+            <para><xref linkend="ST_Simplify" /></para>
+          </refsection>
+    </refentry>
+
 	<refentry id="ST_Reverse">
 	  <refnamediv>
 		<refname>ST_Reverse</refname>
@@ -1366,6 +1678,134 @@ LINESTRING(0 0,1 1,0 0,3 3,4 4)
 		  </refsection>
 	</refentry>
 
+    <refentry id="ST_Shift_Longitude">
+      <refnamediv>
+        <refname>ST_ShiftLongitude</refname>
+
+        <refpurpose>Shifts a geometry with geographic coordinates between -180..180 and 0..360.</refpurpose>
+      </refnamediv>
+
+      <refsynopsisdiv>
+        <funcsynopsis>
+          <funcprototype>
+            <funcdef>geometry <function>ST_ShiftLongitude</function></funcdef>
+            <paramdef><type>geometry </type> <parameter>geomA</parameter></paramdef>
+          </funcprototype>
+        </funcsynopsis>
+      </refsynopsisdiv>
+
+      <refsection>
+        <title>Description</title>
+
+        <para>Reads every point/vertex in a geometry, and if the longitude coordinate is <0, adds 360
+            to it. The result is a 0-360 version of the data to be
+            plotted in a 180 centric map</para>
+        <note><para>This is only useful for data with coordinates in
+        longitude/latitude; e.g. SRID 4326 (WGS 84 geographic)</para></note>
+
+        <warning>
+            <para>Pre-1.3.4 bug prevented this from working for MULTIPOINT. 1.3.4+ works with MULTIPOINT as well.</para>
+    </warning>
+
+        <para>&Z_support;</para>
+        <para>Enhanced: 2.0.0 support for Polyhedral surfaces and TIN was introduced.</para>
+    <para>NOTE: this function was renamed from "ST_Shift_Longitude" in 2.2.0</para>
+        <para>&P_support;</para>
+        <para>&T_support;</para>
+      </refsection>
+
+
+      <refsection>
+        <title>Examples</title>
+
+        <programlisting>--3d points
+SELECT ST_AsEWKT(ST_ShiftLongitude(ST_GeomFromEWKT('SRID=4326;POINT(-118.58 38.38 10)'))) As geomA,
+    ST_AsEWKT(ST_ShiftLongitude(ST_GeomFromEWKT('SRID=4326;POINT(241.42 38.38 10)'))) As geomb
+geomA                             geomB
+----------                        -----------
+SRID=4326;POINT(241.42 38.38 10) SRID=4326;POINT(-118.58 38.38 10)
+
+--regular line string
+SELECT ST_AsText(ST_ShiftLongitude(ST_GeomFromText('LINESTRING(-118.58 38.38, -118.20 38.45)')))
+
+st_astext
+----------
+LINESTRING(241.42 38.38,241.8 38.45)
+        </programlisting>
+      </refsection>
+
+      <!-- Optionally add a "See Also" section -->
+      <refsection>
+        <title>See Also</title>
+        <para>
+      <xref linkend="ST_WrapX" />
+    </para>
+      </refsection>
+    </refentry>
+
+    <refentry id="ST_WrapX">
+      <refnamediv>
+        <refname>ST_WrapX</refname>
+
+        <refpurpose>Wrap a geometry around an X value.</refpurpose>
+      </refnamediv>
+
+      <refsynopsisdiv>
+        <funcsynopsis>
+          <funcprototype>
+            <funcdef>geometry <function>ST_WrapX</function></funcdef>
+            <paramdef><type>geometry </type> <parameter>geom</parameter></paramdef>
+            <paramdef><type>float8 </type> <parameter>wrap</parameter></paramdef>
+            <paramdef><type>float8 </type> <parameter>move</parameter></paramdef>
+          </funcprototype>
+        </funcsynopsis>
+      </refsynopsisdiv>
+
+      <refsection>
+        <title>Description</title>
+
+    <para>
+This function splits the input geometries and then moves every resulting
+component falling on the right (for negative 'move') or on the left (for
+positive 'move') of given 'wrap' line in the direction specified by the
+'move' parameter, finally re-unioning the pieces togheter.
+    </para>
+
+        <note><para>
+This is useful to "recenter" long-lat input to have features
+of interest not spawned from one side to the other.
+    </para></note>
+
+        <para>Availability: 2.3.0 requires GEOS</para>
+        <para>&Z_support;</para>
+<!-- TODO: check these
+        <para>&P_support;</para>
+        <para>&T_support;</para>
+-->
+      </refsection>
+
+
+      <refsection>
+        <title>Examples</title>
+
+        <programlisting>
+-- Move all components of the given geometries whose bounding box
+-- falls completely on the left of x=0 to +360
+select ST_WrapX(the_geom, 0, 360);
+
+-- Move all components of the given geometries whose bounding box
+-- falls completely on the left of x=-30 to +360
+select ST_WrapX(the_geom, -30, 360);
+        </programlisting>
+      </refsection>
+
+      <!-- Optionally add a "See Also" section -->
+      <refsection>
+        <title>See Also</title>
+        <para><xref linkend="ST_Shift_Longitude" /></para>
+      </refsection>
+    </refentry>
+
 	<refentry id="ST_SnapToGrid">
 	  <refnamediv>
 		<refname>ST_SnapToGrid</refname>
diff --git a/doc/reference_processing.xml b/doc/reference_processing.xml
index 7343169..560bfe2 100644
--- a/doc/reference_processing.xml
+++ b/doc/reference_processing.xml
@@ -1,11 +1,11 @@
 <?xml version="1.0" encoding="UTF-8"?>
     <sect1 id="Geometry_Processing">
-     <sect1info>
-    <abstract>
-    <para>These functions compute geometric constructions,
-    or alter geometry size or shape.
-    </para>
-    </abstract>
+    <sect1info>
+        <abstract>
+        <para>These functions compute geometric constructions,
+        or alter geometry size or shape.
+        </para>
+        </abstract>
     </sect1info>
 
     <title>Geometry Processing</title>
@@ -15,8 +15,7 @@
                 <refname>ST_Buffer</refname>
 
                 <refpurpose>
-Returns a geometry covering all points within a given distance
-from a geometry.
+Returns a geometry covering all points within a given distance from a geometry.
             </refpurpose>
             </refnamediv>
 
@@ -876,158 +875,6 @@ SELECT d.disease_type,
       </refsection>
     </refentry>
 
-    <refentry id="ST_CurveToLine">
-      <refnamediv>
-        <refname>ST_CurveToLine</refname>
-
-        <refpurpose>Converts a geometry containing curves to a linear geometry.</refpurpose>
-      </refnamediv>
-
-      <refsynopsisdiv>
-        <funcsynopsis>
-          <funcprototype>
-            <funcdef>geometry <function>ST_CurveToLine</function></funcdef>
-            <paramdef><type>geometry</type> <parameter>curveGeom</parameter></paramdef>
-            <paramdef><type>float</type> <parameter>tolerance</parameter></paramdef>
-            <paramdef choice="opt"><type>integer</type> <parameter>tolerance_type</parameter></paramdef>
-            <paramdef choice="opt"><type>integer</type> <parameter>flags</parameter></paramdef>
-          </funcprototype>
-        </funcsynopsis>
-      </refsynopsisdiv>
-
-      <refsection>
-        <title>Description</title>
-
-        <para>Converts a CIRCULAR STRING to regular LINESTRING or CURVEPOLYGON to POLYGON or MULTISURFACE to MULTIPOLYGON. Useful for outputting to devices that can't support CIRCULARSTRING geometry types</para>
-
-        <para>Converts a given geometry to a linear geometry.
-        Each curved geometry or segment is converted into a linear
-approximation using the given `tolerance` and options (32 segments per
-quadrant and no options by default).</para>
-
-    <para>
-The 'tolerance_type' argument determines interpretation of the
-`tolerance` argument. It can take the following values:
-      <itemizedlist>
-        <listitem>
-          <para>0 (default): Tolerance is max segments per quadrant.</para>
-        </listitem>
-        <listitem>
-          <para>1: Tolerance is max-deviation of line from curve, in source units.</para>
-        </listitem>
-        <listitem>
-          <para>2: Tolerance is max-angle, in radians, between generating radii.</para>
-        </listitem>
-      </itemizedlist>
-    </para>
-
-    <para>
-The 'flags' argument is a bitfield. 0 by default.
-Supported bits are:
-      <itemizedlist>
-        <listitem>
-          <para>1: Symmetric (orientation idependent) output.</para>
-        </listitem>
-        <listitem>
-          <para>2: Retain angle, avoids reducing angles (segment lengths) when producing symmetric output. Has no effect when Symmetric flag is off.</para>
-        </listitem>
-      </itemizedlist>
-    </para>
-
-        <para>Availability: 1.3.0</para>
-    <para>Enhanced: 2.4.0 added support for max-deviation and max-angle tolerance, and for symmetric output.</para>
-    <para>Enhanced: 3.0.0 implemented a minimum number of segments per linearized arc to prevent topological collapse.</para>
-
-        <para>&sfs_compliant;</para>
-        <para>&sqlmm_compliant; SQL-MM 3: 7.1.7</para>
-        <para>&Z_support;</para>
-        <para>&curve_support;</para>
-      </refsection>
-
-
-      <refsection>
-        <title>Examples</title>
-
-        <programlisting>SELECT ST_AsText(ST_CurveToLine(ST_GeomFromText('CIRCULARSTRING(220268 150415,220227 150505,220227 150406)')));
-
---Result --
- LINESTRING(220268 150415,220269.95064912 150416.539364228,220271.823415575 150418.17258804,220273.613787707 150419.895736857,
- 220275.317452352 150421.704659462,220276.930305234 150423.594998003,220278.448460847 150425.562198489,
- 220279.868261823 150427.60152176,220281.186287736 150429.708054909,220282.399363347 150431.876723113,
- 220283.50456625 150434.10230186,220284.499233914 150436.379429536,220285.380970099 150438.702620341,220286.147650624 150441.066277505,
- 220286.797428488 150443.464706771,220287.328738321 150445.892130112,220287.740300149 150448.342699654,
- 220288.031122486 150450.810511759,220288.200504713 150453.289621251,220288.248038775 150455.77405574,
- 220288.173610157 150458.257830005,220287.977398166 150460.734960415,220287.659875492 150463.199479347,
- 220287.221807076 150465.64544956,220286.664248262 150468.066978495,220285.988542259 150470.458232479,220285.196316903 150472.81345077,
- 220284.289480732 150475.126959442,220283.270218395 150477.39318505,220282.140985384 150479.606668057,
- 220280.90450212 150481.762075989,220279.5637474 150483.85421628,220278.12195122 150485.87804878,
- 220276.582586992 150487.828697901,220274.949363179 150489.701464356,220273.226214362 150491.491836488,
- 220271.417291757 150493.195501133,220269.526953216 150494.808354014,220267.559752731 150496.326509628,
- 220265.520429459 150497.746310603,220263.41389631 150499.064336517,220261.245228106 150500.277412127,
- 220259.019649359 150501.38261503,220256.742521683 150502.377282695,220254.419330878 150503.259018879,
- 220252.055673714 150504.025699404,220249.657244448 150504.675477269,220247.229821107 150505.206787101,
- 220244.779251566 150505.61834893,220242.311439461 150505.909171266,220239.832329968 150506.078553494,
- 220237.347895479 150506.126087555,220234.864121215 150506.051658938,220232.386990804 150505.855446946,
- 220229.922471872 150505.537924272,220227.47650166 150505.099855856,220225.054972724 150504.542297043,
- 220222.663718741 150503.86659104,220220.308500449 150503.074365683,
- 220217.994991777 150502.167529512,220215.72876617 150501.148267175,
- 220213.515283163 150500.019034164,220211.35987523 150498.7825509,
- 220209.267734939 150497.441796181,220207.243902439 150496,
- 220205.293253319 150494.460635772,220203.420486864 150492.82741196,220201.630114732 150491.104263143,
- 220199.926450087 150489.295340538,220198.313597205 150487.405001997,220196.795441592 150485.437801511,
- 220195.375640616 150483.39847824,220194.057614703 150481.291945091,220192.844539092 150479.123276887,220191.739336189 150476.89769814,
- 220190.744668525 150474.620570464,220189.86293234 150472.297379659,220189.096251815 150469.933722495,
- 220188.446473951 150467.535293229,220187.915164118 150465.107869888,220187.50360229 150462.657300346,
- 220187.212779953 150460.189488241,220187.043397726 150457.710378749,220186.995863664 150455.22594426,
- 220187.070292282 150452.742169995,220187.266504273 150450.265039585,220187.584026947 150447.800520653,
- 220188.022095363 150445.35455044,220188.579654177 150442.933021505,220189.25536018 150440.541767521,
- 220190.047585536 150438.18654923,220190.954421707 150435.873040558,220191.973684044 150433.60681495,
- 220193.102917055 150431.393331943,220194.339400319 150429.237924011,220195.680155039 150427.14578372,220197.12195122 150425.12195122,
- 220198.661315447 150423.171302099,220200.29453926 150421.298535644,220202.017688077 150419.508163512,220203.826610682 150417.804498867,
- 220205.716949223 150416.191645986,220207.684149708 150414.673490372,220209.72347298 150413.253689397,220211.830006129 150411.935663483,
- 220213.998674333 150410.722587873,220216.22425308 150409.61738497,220218.501380756 150408.622717305,220220.824571561 150407.740981121,
- 220223.188228725 150406.974300596,220225.586657991 150406.324522731,220227 150406)
-
---3d example
-SELECT ST_AsEWKT(ST_CurveToLine(ST_GeomFromEWKT('CIRCULARSTRING(220268 150415 1,220227 150505 2,220227 150406 3)')));
-Output
-------
- LINESTRING(220268 150415 1,220269.95064912 150416.539364228 1.0181172856673,
- 220271.823415575 150418.17258804 1.03623457133459,220273.613787707 150419.895736857 1.05435185700189,....AD INFINITUM ....
-    220225.586657991 150406.324522731 1.32611114201132,220227 150406 3)
-
---use only 2 segments to approximate quarter circle
-SELECT ST_AsText(ST_CurveToLine(ST_GeomFromText('CIRCULARSTRING(220268 150415,220227 150505,220227 150406)'),2));
-st_astext
-------------------------------
- LINESTRING(220268 150415,220287.740300149 150448.342699654,220278.12195122 150485.87804878,
- 220244.779251566 150505.61834893,220207.243902439 150496,220187.50360229 150462.657300346,
- 220197.12195122 150425.12195122,220227 150406)
-
--- Ensure approximated line is no further than 20 units away from
--- original curve, and make the result direction-neutral
-SELECT ST_AsText(ST_CurveToLine(
- 'CIRCULARSTRING(0 0,100 -100,200 0)'::geometry,
-    20, -- Tolerance
-    1, -- Above is max distance between curve and line
-    1  -- Symmetric flag
-));
-st_astext
--------------------------------------------------------------------------------------------
- LINESTRING(0 0,50 -86.6025403784438,150 -86.6025403784439,200 -1.1331077795296e-13,200 0)
-
-
-        </programlisting>
-      </refsection>
-
-      <!-- Optionally add a "See Also" section -->
-      <refsection>
-        <title>See Also</title>
-
-        <para><xref linkend="ST_LineToCurve" /></para>
-      </refsection>
-    </refentry>
-
     <refentry id="ST_DelaunayTriangles">
         <refnamediv>
             <refname>ST_DelaunayTriangles</refname>
@@ -1231,51 +1078,6 @@ FROM (SELECT  ST_SetEffectiveArea('LINESTRING(5 2, 3 8, 6 20, 7 25, 10 10)'::geo
           </refsection>
     </refentry>
 
-    <refentry id="ST_FlipCoordinates">
-      <refnamediv>
-        <refname>ST_FlipCoordinates</refname>
-        <refpurpose>Returns a version of a geometry with X and Y axis flipped. </refpurpose>
-      </refnamediv>
-
-      <refsynopsisdiv>
-        <funcsynopsis>
-          <funcprototype>
-            <funcdef>geometry <function>ST_FlipCoordinates</function></funcdef>
-            <paramdef><type>geometry</type> <parameter>geom</parameter></paramdef>
-          </funcprototype>
-        </funcsynopsis>
-      </refsynopsisdiv>
-
-      <refsection>
-        <title>Description</title>
-        <para>Returns a version of the given geometry with X and Y axis flipped.
-        Useful for fixing geometries which contain coordinates expressed as latitude/longitude (Y,X).</para>
-        <para>Availability: 2.0.0</para>
-        <para>&curve_support;</para>
-        <para>&Z_support;</para>
-        <para>&M_support;</para>
-        <para>&P_support;</para>
-        <para>&T_support;</para>
-      </refsection>
-
-      <refsection>
-        <title>Example</title>
-        <programlisting><![CDATA[
-SELECT ST_AsEWKT(ST_FlipCoordinates(GeomFromEWKT('POINT(1 2)')));
- st_asewkt
-------------
-POINT(2 1)
-         ]]></programlisting>
-      </refsection>
-
-      <!-- Optionally add a "See Also" section -->
-      <refsection>
-        <title>See Also</title>
-        <para> <xref linkend="ST_SwapOrdinates" /> </para>
-      </refsection>
-
-    </refentry>
-
     <refentry id="ST_GeneratePoints">
       <refnamediv>
         <refname>ST_GeneratePoints</refname>
@@ -1498,194 +1300,6 @@ FROM test;
 
     </refentry>
 
-    <refentry id="ST_LineToCurve">
-      <refnamediv>
-        <refname>ST_LineToCurve</refname>
-
-        <refpurpose>Converts a linear geometry to a curved geometry.</refpurpose>
-      </refnamediv>
-
-      <refsynopsisdiv>
-        <funcsynopsis>
-          <funcprototype>
-            <funcdef>geometry <function>ST_LineToCurve</function></funcdef>
-            <paramdef><type>geometry </type> <parameter>geomANoncircular</parameter></paramdef>
-          </funcprototype>
-        </funcsynopsis>
-      </refsynopsisdiv>
-
-      <refsection>
-        <title>Description</title>
-
-        <para>Converts plain LINESTRING/POLYGON to CIRCULAR STRINGs and Curved Polygons.  Note much fewer points are needed to describe the curved equivalent.</para>
-        <note><para>If the input LINESTRING/POLYGON is not curved enough to clearly represent a curve, the function will return the same input geometry.</para></note>
-        <para>Availability: 1.3.0</para>
-        <para>&Z_support;</para>
-        <para>&curve_support;</para>
-      </refsection>
-
-
-      <refsection>
-        <title>Examples</title>
-
-        <programlisting> -- 2D Example
-SELECT ST_AsText(ST_LineToCurve(foo.the_geom)) As curvedastext,ST_AsText(foo.the_geom) As non_curvedastext
-    FROM (SELECT ST_Buffer('POINT(1 3)'::geometry, 3) As the_geom) As foo;
-
-curvedatext                                                            non_curvedastext
---------------------------------------------------------------------|-----------------------------------------------------------------
-CURVEPOLYGON(CIRCULARSTRING(4 3,3.12132034355964 0.878679656440359, | POLYGON((4 3,3.94235584120969 2.41472903395162,3.77163859753386 1.85194970290473,
-1 0,-1.12132034355965 5.12132034355963,4 3))                        |  3.49440883690764 1.33328930094119,3.12132034355964 0.878679656440359,
-                                                                    |  2.66671069905881 0.505591163092366,2.14805029709527 0.228361402466141,
-                                                                    |  1.58527096604839 0.0576441587903094,1 0,
-                                                                    |  0.414729033951621 0.0576441587903077,-0.148050297095264 0.228361402466137,
-                                                                    |  -0.666710699058802 0.505591163092361,-1.12132034355964 0.878679656440353,
-                                                                    |  -1.49440883690763 1.33328930094119,-1.77163859753386 1.85194970290472
-                                                                    |  --ETC-- ,3.94235584120969 3.58527096604839,4 3))
-
---3D example
-SELECT ST_AsText(ST_LineToCurve(geom)) As curved, ST_AsText(geom) AS not_curved
-FROM (SELECT ST_Translate(ST_Force3D(ST_Boundary(ST_Buffer(ST_Point(1,3), 2,2))),0,0,3) AS geom) AS foo;
-
-                        curved                        |               not_curved
-------------------------------------------------------+---------------------------------------------------------------------
- CIRCULARSTRING Z (3 3 3,-1 2.99999999999999 3,3 3 3) | LINESTRING Z (3 3 3,2.4142135623731 1.58578643762691 3,1 1 3,
-                                                      | -0.414213562373092 1.5857864376269 3,-1 2.99999999999999 3,
-                                                      | -0.414213562373101 4.41421356237309 3,
-                                                      | 0.999999999999991 5 3,2.41421356237309 4.4142135623731 3,3 3 3)
-(1 row)
-</programlisting>
-    </refsection>
-
-
-
-      <!-- Optionally add a "See Also" section -->
-      <refsection>
-        <title>See Also</title>
-
-        <para><xref linkend="ST_CurveToLine" /></para>
-      </refsection>
-    </refentry>
-
-    <refentry id="ST_MakeValid">
-      <refnamediv>
-        <refname>ST_MakeValid</refname>
-        <refpurpose>Attempts to make an invalid geometry valid without losing vertices.</refpurpose>
-      </refnamediv>
-
-      <refsynopsisdiv>
-        <funcsynopsis>
-          <funcprototype>
-            <funcdef>geometry <function>ST_MakeValid</function></funcdef>
-            <paramdef><type>geometry</type> <parameter>input</parameter></paramdef>
-          </funcprototype>
-        </funcsynopsis>
-      </refsynopsisdiv>
-
-      <refsection>
-        <title>Description</title>
-    <para>
-    The function attempts to create a valid representation of a given invalid
-    geometry without losing any of the input vertices.
-    Already-valid geometries are returned without further intervention.
-    </para>
-
-    <para>
-    Supported inputs are: POINTS, MULTIPOINTS, LINESTRINGS,
-    MULTILINESTRINGS, POLYGONS, MULTIPOLYGONS and GEOMETRYCOLLECTIONS
-    containing any mix of them.
-    </para>
-
-    <para>
-    In case of full or partial dimensional collapses, the output geometry
-    may be a collection of lower-to-equal dimension geometries or a
-    geometry of lower dimension.
-    </para>
-
-    <para>
-    Single polygons may become multi-geometries in case of self-intersections.
-    </para>
-        <para>Performed by the GEOS module.</para>
-
-    <para>Availability: 2.0.0</para>
-    <para>Enhanced: 2.0.1, speed improvements</para>
-    <para>Enhanced: 2.1.0, added support for GEOMETRYCOLLECTION and MULTIPOINT.</para>
-
-    <para>&Z_support;</para>
-
-          </refsection>
-          <refsection>
-            <title>Examples</title>
-            <informaltable>
-                  <tgroup cols="1">
-                    <tbody>
-                    <row>
-                        <entry><para><informalfigure>
-                            <mediaobject>
-                              <imageobject>
-                                <imagedata fileref="images/st_makevalid01.png" />
-                              </imageobject>
-                              <caption><para>before_geom: MULTIPOLYGON of 2 overlapping polygons</para></caption>
-                            </mediaobject>
-                          </informalfigure>
-                          <informalfigure>
-                            <mediaobject>
-                              <imageobject>
-                                <imagedata fileref="images/st_makevalid02.png" />
-                              </imageobject>
-                              <caption><para>after_geom: MULTIPOLYGON of 4 non-overlapping polygons</para>
-                              </caption>
-                            </mediaobject>
-                          </informalfigure>
-                <programlisting>SELECT f.geom AS before_geom, ST_MakeValid( f.geom) AS after_geom
-FROM (SELECT 'MULTIPOLYGON(((186 194,187 194,188 195,189 195,190 195,
-191 195,192 195,193 194,194 194,194 193,195 192,195 191,
-195 190,195 189,195 188,194 187,194 186,14 6,13 6,12 5,11 5,
-10 5,9 5,8 5,7 6,6 6,6 7,5 8,5 9,5 10,5 11,5 12,6 13,6 14,186 194)),
-((150 90,149 80,146 71,142 62,135 55,128 48,119 44,110 41,100 40,
-90 41,81 44,72 48,65 55,58 62,54 71,51 80,50 90,51 100,
-54 109,58 118,65 125,72 132,81 136,90 139,100 140,110 139,
-119 136,128 132,135 125,142 118,146 109,149 100,150 90)))'::geometry AS geom) AS f;</programlisting>
-            </para>
-            </entry>
-        </row>
-        <row>
-            <entry><para>
-                <informalfigure>
-                <mediaobject>
-                    <imageobject><imagedata fileref="images/st_makevalid03.png" /></imageobject>
-                    <caption><para>before_geom: MULTIPOLYGON of 6 overlapping polygons</para></caption>
-                </mediaobject>
-                </informalfigure>
-                <informalfigure>
-                <mediaobject>
-                    <imageobject><imagedata fileref="images/st_makevalid04.png" /></imageobject>
-                    <caption><para>after_geom: MULTIPOLYGON of 14 Non-overlapping polygons</para></caption>
-                </mediaobject>
-                </informalfigure>
-                <programlisting>SELECT c.geom AS before_geom, ST_MakeValid(c.geom) AS after_geom
-	FROM (SELECT 'MULTIPOLYGON(((91 50,79 22,51 10,23 22,11 50,23 78,51 90,79 78,91 50)),
-		  ((91 100,79 72,51 60,23 72,11 100,23 128,51 140,79 128,91 100)),
-		  ((91 150,79 122,51 110,23 122,11 150,23 178,51 190,79 178,91 150)),
-		  ((141 50,129 22,101 10,73 22,61 50,73 78,101 90,129 78,141 50)),
-		  ((141 100,129 72,101 60,73 72,61 100,73 128,101 140,129 128,141 100)),
-		  ((141 150,129 122,101 110,73 122,61 150,73 178,101 190,129 178,141 150)))'::geometry AS geom) AS c;</programlisting>
-            </para></entry>
-        </row>
-    </tbody>
-    </tgroup>
-</informaltable>
-</refsection>
-          <refsection>
-            <title>See Also</title>
-            <para>
-                <xref linkend="ST_IsValid" />,
-                <xref linkend="ST_Collect" />,
-                <xref linkend="ST_CollectionExtract" />
-            </para>
-          </refsection>
-    </refentry>
-
     <refentry id="ST_MaximumInscribedCircle">
       <refnamediv>
         <refname>ST_MaximumInscribedCircle</refname>
@@ -2377,46 +1991,6 @@ SELECT ST_AsText(ST_ReducePrecision('POINT(1.412 19.323)', 1.0));
       </refsection>
     </refentry>
 
-
-    <refentry id="ST_RemoveRepeatedPoints">
-      <refnamediv>
-        <refname>ST_RemoveRepeatedPoints</refname>
-        <refpurpose>Returns a version of the given geometry with
-                duplicated points removed.</refpurpose>
-      </refnamediv>
-
-      <refsynopsisdiv>
-        <funcsynopsis>
-          <funcprototype>
-            <funcdef>geometry <function>ST_RemoveRepeatedPoints</function></funcdef>
-            <paramdef><type>geometry</type> <parameter>geom</parameter></paramdef>
-            <paramdef choice="opt"><type>float8</type> <parameter>tolerance</parameter></paramdef>
-          </funcprototype>
-        </funcsynopsis>
-      </refsynopsisdiv>
-
-      <refsection>
-        <title>Description</title>
-        <para>Returns a version of the given geometry with
-                duplicated points removed. Will actually do something only with
-                (multi)lines, (multi)polygons and multipoints but you can safely call it with
-                any kind of geometry. Since simplification occurs on a
-                object-by-object basis you can also feed a GeometryCollection to
-                this function.</para>
-        <para>If the tolerance parameter is provided, vertices within the tolerance
-        of one another will be considered the "same" for the purposes of removal.</para>
-
-        <para>Availability: 2.2.0</para>
-        <para>&P_support;</para>
-        <para>&Z_support;</para>
-      </refsection>
-
-          <refsection>
-            <title>See Also</title>
-            <para><xref linkend="ST_Simplify" /></para>
-          </refsection>
-    </refentry>
-
     <refentry id="ST_SharedPaths">
       <refnamediv>
         <refname>ST_SharedPaths</refname>
@@ -2518,134 +2092,6 @@ MULTILINESTRING((76 175,90 161),(90 161,101 150),(126 125,126 156.25)))
       </refsection>
     </refentry>
 
-    <refentry id="ST_Shift_Longitude">
-      <refnamediv>
-        <refname>ST_ShiftLongitude</refname>
-
-        <refpurpose>Shifts a geometry with geographic coordinates between -180..180 and 0..360.</refpurpose>
-      </refnamediv>
-
-      <refsynopsisdiv>
-        <funcsynopsis>
-          <funcprototype>
-            <funcdef>geometry <function>ST_ShiftLongitude</function></funcdef>
-            <paramdef><type>geometry </type> <parameter>geomA</parameter></paramdef>
-          </funcprototype>
-        </funcsynopsis>
-      </refsynopsisdiv>
-
-      <refsection>
-        <title>Description</title>
-
-        <para>Reads every point/vertex in a geometry, and if the longitude coordinate is <0, adds 360
-            to it. The result is a 0-360 version of the data to be
-            plotted in a 180 centric map</para>
-        <note><para>This is only useful for data with coordinates in
-        longitude/latitude; e.g. SRID 4326 (WGS 84 geographic)</para></note>
-
-        <warning>
-            <para>Pre-1.3.4 bug prevented this from working for MULTIPOINT. 1.3.4+ works with MULTIPOINT as well.</para>
-    </warning>
-
-        <para>&Z_support;</para>
-        <para>Enhanced: 2.0.0 support for Polyhedral surfaces and TIN was introduced.</para>
-    <para>NOTE: this function was renamed from "ST_Shift_Longitude" in 2.2.0</para>
-        <para>&P_support;</para>
-        <para>&T_support;</para>
-      </refsection>
-
-
-      <refsection>
-        <title>Examples</title>
-
-        <programlisting>--3d points
-SELECT ST_AsEWKT(ST_ShiftLongitude(ST_GeomFromEWKT('SRID=4326;POINT(-118.58 38.38 10)'))) As geomA,
-    ST_AsEWKT(ST_ShiftLongitude(ST_GeomFromEWKT('SRID=4326;POINT(241.42 38.38 10)'))) As geomb
-geomA                             geomB
-----------                        -----------
-SRID=4326;POINT(241.42 38.38 10) SRID=4326;POINT(-118.58 38.38 10)
-
---regular line string
-SELECT ST_AsText(ST_ShiftLongitude(ST_GeomFromText('LINESTRING(-118.58 38.38, -118.20 38.45)')))
-
-st_astext
-----------
-LINESTRING(241.42 38.38,241.8 38.45)
-        </programlisting>
-      </refsection>
-
-      <!-- Optionally add a "See Also" section -->
-      <refsection>
-        <title>See Also</title>
-        <para>
-      <xref linkend="ST_WrapX" />
-    </para>
-      </refsection>
-    </refentry>
-
-    <refentry id="ST_WrapX">
-      <refnamediv>
-        <refname>ST_WrapX</refname>
-
-        <refpurpose>Wrap a geometry around an X value.</refpurpose>
-      </refnamediv>
-
-      <refsynopsisdiv>
-        <funcsynopsis>
-          <funcprototype>
-            <funcdef>geometry <function>ST_WrapX</function></funcdef>
-            <paramdef><type>geometry </type> <parameter>geom</parameter></paramdef>
-            <paramdef><type>float8 </type> <parameter>wrap</parameter></paramdef>
-            <paramdef><type>float8 </type> <parameter>move</parameter></paramdef>
-          </funcprototype>
-        </funcsynopsis>
-      </refsynopsisdiv>
-
-      <refsection>
-        <title>Description</title>
-
-    <para>
-This function splits the input geometries and then moves every resulting
-component falling on the right (for negative 'move') or on the left (for
-positive 'move') of given 'wrap' line in the direction specified by the
-'move' parameter, finally re-unioning the pieces togheter.
-    </para>
-
-        <note><para>
-This is useful to "recenter" long-lat input to have features
-of interest not spawned from one side to the other.
-    </para></note>
-
-        <para>Availability: 2.3.0 requires GEOS</para>
-        <para>&Z_support;</para>
-<!-- TODO: check these
-        <para>&P_support;</para>
-        <para>&T_support;</para>
--->
-      </refsection>
-
-
-      <refsection>
-        <title>Examples</title>
-
-        <programlisting>
--- Move all components of the given geometries whose bounding box
--- falls completely on the left of x=0 to +360
-select ST_WrapX(the_geom, 0, 360);
-
--- Move all components of the given geometries whose bounding box
--- falls completely on the left of x=-30 to +360
-select ST_WrapX(the_geom, -30, 360);
-        </programlisting>
-      </refsection>
-
-      <!-- Optionally add a "See Also" section -->
-      <refsection>
-        <title>See Also</title>
-        <para><xref linkend="ST_Shift_Longitude" /></para>
-      </refsection>
-    </refentry>
-
     <refentry id="ST_Simplify">
       <refnamediv>
         <refname>ST_Simplify</refname>
diff --git a/doc/reference_validation.xml b/doc/reference_validation.xml
index 34d20f2..adc0d40 100644
--- a/doc/reference_validation.xml
+++ b/doc/reference_validation.xml
@@ -5,8 +5,9 @@
 	  <sect1info>
 	    <abstract>
 			<para>These functions test whether geometries are valid according to
-			the OGC SFS standard.  They also provide information about
-			the nature and location of invalidity.
+			the OGC SFS standard.
+            They also provide information about the nature and location of invalidity.
+            There is also a function to create a valid geometry out of an invalid one.
 			</para>
    	</abstract>
     </sect1info>
@@ -276,4 +277,123 @@ SELECT ST_IsValidReason('LINESTRING(220227 150406,2220227 150407,222020 150410)'
 	  </refsection>
 	</refentry>
 
+    <refentry id="ST_MakeValid">
+      <refnamediv>
+        <refname>ST_MakeValid</refname>
+        <refpurpose>Attempts to make an invalid geometry valid without losing vertices.</refpurpose>
+      </refnamediv>
+
+      <refsynopsisdiv>
+        <funcsynopsis>
+          <funcprototype>
+            <funcdef>geometry <function>ST_MakeValid</function></funcdef>
+            <paramdef><type>geometry</type> <parameter>input</parameter></paramdef>
+          </funcprototype>
+        </funcsynopsis>
+      </refsynopsisdiv>
+
+      <refsection>
+        <title>Description</title>
+    <para>
+    The function attempts to create a valid representation of a given invalid
+    geometry without losing any of the input vertices.
+    Already-valid geometries are returned without further intervention.
+    </para>
+
+    <para>
+    Supported inputs are: POINTS, MULTIPOINTS, LINESTRINGS,
+    MULTILINESTRINGS, POLYGONS, MULTIPOLYGONS and GEOMETRYCOLLECTIONS
+    containing any mix of them.
+    </para>
+
+    <para>
+    In case of full or partial dimensional collapses, the output geometry
+    may be a collection of lower-to-equal dimension geometries or a
+    geometry of lower dimension.
+    </para>
+
+    <para>
+    Single polygons may become multi-geometries in case of self-intersections.
+    </para>
+        <para>Performed by the GEOS module.</para>
+
+    <para>Availability: 2.0.0</para>
+    <para>Enhanced: 2.0.1, speed improvements</para>
+    <para>Enhanced: 2.1.0, added support for GEOMETRYCOLLECTION and MULTIPOINT.</para>
+
+    <para>&Z_support;</para>
+
+          </refsection>
+          <refsection>
+            <title>Examples</title>
+            <informaltable>
+                  <tgroup cols="1">
+                    <tbody>
+                    <row>
+                        <entry><para><informalfigure>
+                            <mediaobject>
+                              <imageobject>
+                                <imagedata fileref="images/st_makevalid01.png" />
+                              </imageobject>
+                              <caption><para>before_geom: MULTIPOLYGON of 2 overlapping polygons</para></caption>
+                            </mediaobject>
+                          </informalfigure>
+                          <informalfigure>
+                            <mediaobject>
+                              <imageobject>
+                                <imagedata fileref="images/st_makevalid02.png" />
+                              </imageobject>
+                              <caption><para>after_geom: MULTIPOLYGON of 4 non-overlapping polygons</para>
+                              </caption>
+                            </mediaobject>
+                          </informalfigure>
+                <programlisting>SELECT f.geom AS before_geom, ST_MakeValid( f.geom) AS after_geom
+FROM (SELECT 'MULTIPOLYGON(((186 194,187 194,188 195,189 195,190 195,
+191 195,192 195,193 194,194 194,194 193,195 192,195 191,
+195 190,195 189,195 188,194 187,194 186,14 6,13 6,12 5,11 5,
+10 5,9 5,8 5,7 6,6 6,6 7,5 8,5 9,5 10,5 11,5 12,6 13,6 14,186 194)),
+((150 90,149 80,146 71,142 62,135 55,128 48,119 44,110 41,100 40,
+90 41,81 44,72 48,65 55,58 62,54 71,51 80,50 90,51 100,
+54 109,58 118,65 125,72 132,81 136,90 139,100 140,110 139,
+119 136,128 132,135 125,142 118,146 109,149 100,150 90)))'::geometry AS geom) AS f;</programlisting>
+            </para>
+            </entry>
+        </row>
+        <row>
+            <entry><para>
+                <informalfigure>
+                <mediaobject>
+                    <imageobject><imagedata fileref="images/st_makevalid03.png" /></imageobject>
+                    <caption><para>before_geom: MULTIPOLYGON of 6 overlapping polygons</para></caption>
+                </mediaobject>
+                </informalfigure>
+                <informalfigure>
+                <mediaobject>
+                    <imageobject><imagedata fileref="images/st_makevalid04.png" /></imageobject>
+                    <caption><para>after_geom: MULTIPOLYGON of 14 Non-overlapping polygons</para></caption>
+                </mediaobject>
+                </informalfigure>
+                <programlisting>SELECT c.geom AS before_geom, ST_MakeValid(c.geom) AS after_geom
+	FROM (SELECT 'MULTIPOLYGON(((91 50,79 22,51 10,23 22,11 50,23 78,51 90,79 78,91 50)),
+		  ((91 100,79 72,51 60,23 72,11 100,23 128,51 140,79 128,91 100)),
+		  ((91 150,79 122,51 110,23 122,11 150,23 178,51 190,79 178,91 150)),
+		  ((141 50,129 22,101 10,73 22,61 50,73 78,101 90,129 78,141 50)),
+		  ((141 100,129 72,101 60,73 72,61 100,73 128,101 140,129 128,141 100)),
+		  ((141 150,129 122,101 110,73 122,61 150,73 178,101 190,129 178,141 150)))'::geometry AS geom) AS c;</programlisting>
+            </para></entry>
+        </row>
+    </tbody>
+    </tgroup>
+</informaltable>
+</refsection>
+          <refsection>
+            <title>See Also</title>
+            <para>
+                <xref linkend="ST_IsValid" />,
+                <xref linkend="ST_Collect" />,
+                <xref linkend="ST_CollectionExtract" />
+            </para>
+          </refsection>
+    </refentry>
+
   </sect1>

-----------------------------------------------------------------------

Summary of changes:
 doc/reference_editor.xml     | 440 +++++++++++++++++++++++++++++++++
 doc/reference_processing.xml | 568 +------------------------------------------
 doc/reference_validation.xml | 124 +++++++++-
 3 files changed, 569 insertions(+), 563 deletions(-)


hooks/post-receive
-- 
PostGIS


More information about the postgis-tickets mailing list