[postgis-users] Optimizations: splitting large features
Jeff Dege
jdege at korterra.com
Fri Apr 27 07:43:34 PDT 2007
There were two ideas I'd had with respect to manipulating geometries so
as to make the draw faster on a map. The first was simplifying them -
reducing the number of points. If your map resulution is 1km per pixel,
there's no point in sending to the drawing engine points that are 10m
apart. I'm told that PostGIS has functions to support this.
The other is to split features apart. Instead, for example, of having
one feature representing a river that snakes around over a large area,
and hence has to be included in nearly every spatial query, break it
apart into multiple features each of which represents a short segment of
the river.
I asked, as an aside in an earlier post, if PostGIS provided functions
to support this, but no one addressed the question. (Though I did get
detailed responses for the main question, for which you have my thanks.)
But it is a question that I'd like an answer to, so I'm asking it by
itself. Does PostGIS provide functions for splitting apart geometries?
I see functions in the manual for doing intersections and differences
between geometries, but I don't see anything that would handle the
problem directly. I could see how we could define a set of clipping
gemoetries to tile the plane, and then use the intersection function to
clip our starting features, but I'm not sure this would be the best
approach.
Is this a common optimization? Is there a usual approach? Does anyone
have code for doing this?
More information about the postgis-users
mailing list