[postgis-users] A question on ST_RemEdgeModFace usability

Sandro Santilli strk at keybit.net
Thu Apr 12 22:32:58 PDT 2012


On Thu, Apr 12, 2012 at 10:54:45PM +0200, Jose Carlos Martinez Llario wrote:

> In fact, for editing topogeometries without using primitive commands
> I was thinking in:
> 
> 1.- Delete the topogeometry
> 2.- Remove the primitives which depend just on the geometry deleted.
> 3.- With totopogeom insert again the whole geometry

NOTE about (2) : no primitive "depend" on TopoGeometry,
it's the other way around. 

> I know this procedure is not optimized at all but maybe this way
> (with a new function which does this work)  one can avoid the
> complicated task about using primitive editing commands and to edit
> the relation table manually.
> I have the feeling I not taking into account many things though.
> 
> What do you think about this procedure Sandro?

I think the idea should be that of _never_ removing primitives unless
really doing spring cleanups / garbage collection.

Editing a TopoGeometry should be seen as modifying the list of primitives
it is defined by. So in Andrea's case it was _adding_ a face to the list
of defining primitives. And when you want it to shrink but you're missing
a face you can split an existing one (your TopoGeometries won't change
shape).

This is about what would happen in your procedure, if you drop step (2).
The toTopoGeometry function will only _add_ primitives, never drop them.

I can see it would be beneficial to have user-friendly functions to edit
a TopoGeometry definition. I've actually been also thining about an UI 
from qgis to do that: something that lets you toggle inclusion/exclusion
of candidate primitives from a TopoGeometry with mouse clicks.

--strk; 

  ,------o-. 
  |   __/  |    Delivering high quality PostGIS 2.0 !
  |  / 2.0 |    http://strk.keybit.net - http://vizzuality.com
  `-o------'




More information about the postgis-users mailing list