RE: [Geoserver-devel] getting image from wms results in error

it's strange:

with styles=green i'm now able to get a .png or .jpg of my province-layer but NOT an .svg altough .svg works for the bc_roads-example-layer. my province-layer is served by a postgis-datastore, could this make a difference...?

http://127.0.0.1:8081/geoserver/wms?request=GetMap&layers=province&bbox=59,-1,150,61&width=900&height=600&srs=EPSG:-1&styles=green&Format=image/png

jean-pierre

At 11:38 09.01.2004 +1030, you wrote:

This could be a style problem. Make sure the style contain FeatureTypeStyle for your FeatureType and that they have approriate symbolisers. This bit me also. Unfortunately SLD does not provide very good generic styling.

Sean

So I spent a bit of time investigating, and it looks like the SVG encoder
missed a call to encode polygons. I'm having trouble with my SVG
plug-ins, so I couldn't actually view it, but it now _does_ generate xml
for the lines. I assume your layer is polygons, or else we've got some
other problem... I was able to succesfully use a postgis datasource. It
looks like the class has two ways to encode polygons, if this doesn't work
you may try changing line 561 to say writePolyContent( instead of
writePoly( . So just move this class to
geoserver/src/org/vfny/geoserver/responses/wms/map/ and rebuild geoserver,
and it may fix the problem. Thanks for catching the bug, and let me know
if this fix works.

Chris

On Fri, 9 Jan 2004, Jean-Pierre Praz wrote:

it's strange:

with styles=green i'm now able to get a .png or .jpg of my province-layer
but NOT an .svg altough .svg works for the bc_roads-example-layer. my
province-layer is served by a postgis-datastore, could this make a
difference...?

http://127.0.0.1:8081/geoserver/wms?request=GetMap&layers=province&bbox=59,-1,150,61&width=900&height=600&srs=EPSG:-1&styles=green&Format=image/png

jean-pierre

At 11:38 09.01.2004 +1030, you wrote:
>This could be a style problem. Make sure the style contain
>FeatureTypeStyle for your FeatureType and that they have approriate
>symbolisers. This bit me also. Unfortunately SLD does not provide very
>good generic styling.
>
>Sean

-------------------------------------------------------
This SF.net email is sponsored by: Perforce Software.
Perforce is the Fast Software Configuration Management System offering
advanced branching capabilities and atomic changes on 50+ platforms.
Free Eval! http://www.perforce.com/perforce/loadprog.html
_______________________________________________
Geoserver-devel mailing list
Geoserver-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-devel

--

(attachments)

SVGEncoder.java (26.9 KB)

yes, my province-layer is polygons. with the modified SVGEncoder it works perfect, thanks for fixing that.

for my purpose it would be nice to still have the fid-attribute from the gml-output in the svg-output. i will probably modify SVGEncoder a bit. does the Feature-class expose this attribute?

<jpp:country fid="country.19260">

<path d="..." id="country.19260" />

jean-pierre

At 19:39 09.01.2004 -0500, you wrote:

So I spent a bit of time investigating, and it looks like the SVG encoder
missed a call to encode polygons. I'm having trouble with my SVG
plug-ins, so I couldn't actually view it, but it now _does_ generate xml
for the lines. I assume your layer is polygons, or else we've got some
other problem... I was able to succesfully use a postgis datasource. It
looks like the class has two ways to encode polygons, if this doesn't work
you may try changing line 561 to say writePolyContent( instead of
writePoly( . So just move this class to
geoserver/src/org/vfny/geoserver/responses/wms/map/ and rebuild geoserver,
and it may fix the problem. Thanks for catching the bug, and let me know
if this fix works.

Chris

The SVGEncoder version I have in my computer has the ability of encoding FID
and any other attribute data
as attributes in the resulting SVG elements for each feature. Althoug I was
very inactive in geoserver for the last
2 months, I think I'll be able of commiting it if you need it.

please all of you excuse my ausence, since some of the discused topics were
directly related to my work in geoserver,
it's just that I was (and still I am) trying to reach a dead line were it
was supposed we were 5 developers and actually we're just 3, so I'm very
bussy with my main project.

regards,

Gabriel Roldán.

----- Original Message -----
From: "Jean-Pierre Praz" <jpraz@anonymised.com>
To: <geoserver-devel@lists.sourceforge.net>
Sent: Saturday, January 10, 2004 12:01 PM
Subject: RE: [Geoserver-devel] getting image from wms results in error

yes, my province-layer is polygons. with the modified SVGEncoder it works
perfect, thanks for fixing that.

for my purpose it would be nice to still have the fid-attribute from the
gml-output in the svg-output. i will probably modify SVGEncoder a bit.

does

the Feature-class expose this attribute?

<jpp:country fid="country.19260">

<path d="..." id="country.19260" />

jean-pierre

At 19:39 09.01.2004 -0500, you wrote:
>So I spent a bit of time investigating, and it looks like the SVG encoder
>missed a call to encode polygons. I'm having trouble with my SVG
>plug-ins, so I couldn't actually view it, but it now _does_ generate xml
>for the lines. I assume your layer is polygons, or else we've got some
>other problem... I was able to succesfully use a postgis datasource. It
>looks like the class has two ways to encode polygons, if this doesn't

work

>you may try changing line 561 to say writePolyContent( instead of
>writePoly( . So just move this class to
>geoserver/src/org/vfny/geoserver/responses/wms/map/ and rebuild

geoserver,

>and it may fix the problem. Thanks for catching the bug, and let me know
>if this fix works.
>
>Chris

-------------------------------------------------------
This SF.net email is sponsored by: Perforce Software.
Perforce is the Fast Software Configuration Management System offering
advanced branching capabilities and atomic changes on 50+ platforms.
Free Eval! http://www.perforce.com/perforce/loadprog.html
_______________________________________________
Geoserver-devel mailing list
Geoserver-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-devel

yes, my province-layer is polygons. with the modified SVGEncoder it
works
perfect, thanks for fixing that.

Cool, sorry I missed it before the release, I should have done more
testing.

for my purpose it would be nice to still have the fid-attribute from
the
gml-output in the svg-output. i will probably modify SVGEncoder a
bit. does
the Feature-class expose this attribute?

Yes, you should be able to very easily. It's just feature.getID(), I
believe. Check the geotools api to be sure. All features, even those
with just geometries, should have the fid as their ID.

Chris

<jpp:country fid="country.19260">

<path d="..." id="country.19260" />

jean-pierre

At 19:39 09.01.2004 -0500, you wrote:
>So I spent a bit of time investigating, and it looks like the SVG
encoder
>missed a call to encode polygons. I'm having trouble with my SVG
>plug-ins, so I couldn't actually view it, but it now _does_ generate
xml
>for the lines. I assume your layer is polygons, or else we've got
some
>other problem... I was able to succesfully use a postgis
datasource. It
>looks like the class has two ways to encode polygons, if this
doesn't work
>you may try changing line 561 to say writePolyContent( instead of
>writePoly( . So just move this class to
>geoserver/src/org/vfny/geoserver/responses/wms/map/ and rebuild
geoserver,
>and it may fix the problem. Thanks for catching the bug, and let me
know
>if this fix works.
>
>Chris

-------------------------------------------------------
This SF.net email is sponsored by: Perforce Software.
Perforce is the Fast Software Configuration Management System
offering
advanced branching capabilities and atomic changes on 50+ platforms.
Free Eval! http://www.perforce.com/perforce/loadprog.html
_______________________________________________
Geoserver-devel mailing list
Geoserver-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-devel

-------------------------------------------------
This mail sent through IMP: http://horde.org/imp/