Hi Michael, I am already using the JTS simpliefier. I am storing my features in DB2, use the db2-ng module and have
Features like
BorderEurope
BorderEurope_100 (Generalised 100 m)
BorderEurope_1000 (Generalised 1000m)
and so on
Andrea:
The urgent need is WMS, but it should work for WFS too. Uisngthe SLD is a possiblity, but
this is not really transparent. At the moment I have to convince my users that layout has to be done with SLDs and not
downloding the whole stuff and working with ARCGis. Live is hard enough.
My idea was to do a FeatureSource implementation containing the base feature source and all generalisation feature sources,
delegating most of the methods to the base feature source, but the problem is that I need
1) the reqeusted Envelope
2) the pixelDimension
to decide which generalisation to use.
And I have no idea how to transport this information from the WMS GetMap request to new FeatureSource implementation.
A second brute force idea was to implement a geoserver plugin as described here.
http://geoserver.org/display/GEOSDOC/3+A+Simple+PlugIn
defining an own service to find the correct generalisation and do an WMS redispatch.
Nasty, but would work
Any ideas
christian
Andrea Aime writes:
Christian Müller ha scritto:
Do we have something like pyramids for for vector data ?
What I mean is having a FeatureSource (say, the boundary of Europe having 100 000 vertices) and drawing the boundary on a 640x480 image.
I really do not need 100 000 points and therefore I make some generalizations, each as its own feature source, minimizing io traffic and cpu usage.
It would be nice to have a (read only) FeatureSource as a Wrapper for all the generalizations (best design pattern would be a composite), which
selects the proper generalization (depending on world and pixel size) and returns a much smaller number of vertices.
It is the same concept as we have for image pyramids (I think, AbstractGridCoverageReader has the logic built in).
Opinions ?
Are you talking WMS or WFS? WMS already does on the fly generalization
before rendering. And if you want to use pre-generalized data,
you can, just store multiple geometric columns in your database,
and use scale dependent rules to decide which geometry to use.
This effectively allows for using pre-decimated geometries, thought
of course it would be nicer if the datastore hid the extra columns
and could decide which one to pick automatically based on a generalization hint.
WFS wise, we're thinking to work on something like that as well.
WFS 1.1
specification allows to return not only attributes, but also
functions over attributes. At the moment they are not supported,
but we are looking into what amount of work it would take
to support them. Once that is working, we could have a
generalize(geom, distance) function that does generalization,
and also plays fully by the WFS rules.
Opinions?
Cheers
Andrea
--
Andrea Aime
OpenGeo - http://opengeo.org
Expert service straight from the developers.