On Thu, 6 Oct 2005, randy george wrote:
Thanks Chris,
I was planning to look at this today. It actually makes more sense
to me to extend WFS, since svg is a vector format not raster as in WMS. It
is nice to have WMS capability on a vector datastore as a fall back for
clients without svg capability. However, it makes more sense to serve svg
out of WFS as an alternative format to GML and have filter query and
transaction capability.
Yeah, that would be a good thing. My thought is actually to have SVG as
an output format for both WFS and WMS.
You want it as WFS to get at the attributes, and to make use of the
complex filtering, as well as doing transactions.
You want it as WMS to do styling, especially nice things like user defined
styling.
The current SVG support doesn't really do either. There is Gabriel's
streaming renderer, which is very fast, but does no styling, and doesn't
include the attributes. There is the batik one, that does styling, but is
slow.
If you're looking to do WFS type support, what I would actually do is
extend:
http://svn.geotools.org/geotools/trunk/gt/module/main/src/org/geotools/gml/producer/FeatureTransformer.java
to do SVG instead of GML. This should be pretty easy, probably changing a
few of the headers (though this may all happen in GeoServer), and
implementing a new version of
http://svn.geotools.org/geotools/trunk/gt/module/main/src/org/geotools/gml/producer/GeometryTransformer.java
that writes SVG instead of GML. By going this route you get all the speed
of the current GML writer, and you also don't have to rewrite any of the
code that handles the other attributes (for WFS you need to respond to
requesting just a few attributes correctly). The code is a bit funky,
it's a SAX producer, but it works well.
At some later point we may want to rewrite all the SVG stuff, a super
class to handle either WMS styles or WFS feature information. But for now
I'd say just go with changing the FeatureProducer to SVG geometries.
best regards,
Chris
Thanks
Randy-----Original Message-----
From: Chris Holmes [mailto:cholmes@anonymised.com]
Sent: Thursday, October 06, 2005 6:39 AM
To: randy george
Subject: some produce docsThis went to geoserver list, but you might have missed it;
http://docs.codehaus.org/display/GEOSDOC/Create+your+own+Output+Format?decor
ator=printableIt's for wfs output, but the way wms is done is very similar. It's not
the best overview, but the walkthrough gives you a good picture of how to
add a new one.C
--