[postgis-users] Postgis topology help
pcreso at pcreso.com
pcreso at pcreso.com
Wed Apr 4 12:14:13 PDT 2012
Thanks again for a prompt reply.
QGIS is showing the results of the inserts & polygonise in the attached image. So, yes, just as you sketched it.
I had assumed Polygonize was constructing polygon TopoGeometries ?? Obviously I've missed something somewhere.
I can find no info at all on the ST_TopologySummary() function. Not in the docs, & even Google cannot find a single reference. Where do I look for some explanation of this function (& any others that might be relevant )?
Thanks,
Brent
--- On Thu, 4/5/12, Sandro Santilli <strk at keybit.net> wrote:
From: Sandro Santilli <strk at keybit.net>
Subject: Re: [postgis-users] Postgis topology
help
To: pcreso at pcreso.com, "PostGIS Users Discussion" <postgis-users at postgis.refractions.net>
Date: Thursday, April 5, 2012, 5:49 AM
On Wed, Apr 04, 2012 at 09:57:10AM -0700, pcreso at pcreso.com wrote:
> Following on from the reply by strk (thanks!!) I'm still working through how to use topologies.
>
> I have a script which creates a topology, adds 5 linestrings looking like:
>
> | | |
> ---------------
> | | |
> ---------------
> | | |
>
> validates the result and then Polygonizes it, creating two faces.
Like this
?
| | |
-+------+------+-
| | |
-+------+------+-
| | |
> I'm using the SVN docs
> ( http://www.postgis.org/documentation/manual-svn/Topology.html )
> as my reference, as this is the best I have found so far.
>
> What I want this script to do is run a query listing/describing the faces that have been created, then extract them as polygon geometries into a Postgis geometry column to be used as conventional polygons, but I can see no way in the docs of accomplishing this.
ST_TopologySummary gives you a good
summary.
You can use GetFaceGeometry to extract the faces polygons,
maybe use it in a query to <yourtoponame>.face to see them
all. Remember that face_id=0 is the universe face, so you
want to skip that from the query.
> Once I get the script able to complete this operation I figure I should have a much better understanding of how Postgis topology works, & will stick it on the wiki as a working example. I'll also insert more commands to illustrate other operations, as I learn this stuff.
>
> Any suggestions as to how to accomplish these next steps?
I think your next step should be looking at constructing TopoGeometry
objects :)
--strk;
,------o-.
| __/ | Delivering high quality PostGIS 2.0 !
| / 2.0 | http://strk.keybit.net - http://vizzuality.com
`-o------'
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/postgis-users/attachments/20120404/eeb1e4c1/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: topo.png
Type: image/png
Size: 2014 bytes
Desc: not available
URL: <http://lists.osgeo.org/pipermail/postgis-users/attachments/20120404/eeb1e4c1/attachment.png>
More information about the postgis-users
mailing list