SLD / Point symbolizer & Size

François Prunayre fx.prunayre at OIEAU.FR
Thu Apr 6 05:45:24 PDT 2006


Hi list, 
Using SLD and symbols, I get 2 differents behaviour using Mapserver &
Geoserver. Differences is on point symbolizer and the size parameter. 
 
For example, using a png file of 20x20px
<http://sandre.eaufrance.fr/geo/sym/port.png>
http://sandre.eaufrance.fr/geo/sym/port.png
in the following SLD for mapserver :
http://xml.sandre.eaufrance.fr/exist/Geo/sld/REPOM.xml
<http://sandre.eaufrance.fr/geoserver/data/generated/topp_REPOM.html> 
 
When I ask for 3 images (400x400px) for the REPOM layer at 3 differents
scales, the symbol is getting bigger and bigger ... Size is set to 2. And
units in the OGC SLD spec is defined as "The Size element gives the absolute
size of the graphic in pixels encoded as a floating-point number."
http://services.sandre.eaufrance.fr/geo/ouvrage?SERVICE=WMS
<http://services.sandre.eaufrance.fr/geo/ouvrage?SERVICE=WMS&VERSION=1.1.1&R
EQUEST=GetMap&LAYERS=REPOM&WIDTH=400&HEIGHT=400&BBOX=-6,41,10,52&SRS=epsg:43
26&SLD=http://xml.sandre.eaufrance.fr/exist/Geo/sld/REPOM.xml>
&VERSION=1.1.1&REQUEST=GetMap&LAYERS=REPOM&WIDTH=400&HEIGHT=400&BBOX=-6,41,1
0,52&SRS=epsg:4326&SLD=http://xml.sandre.eaufrance.fr/exist/Geo/sld/REPOM.xm
l
http://services.sandre.eaufrance.fr/geo/ouvrage?SERVICE=WMS
<http://services.sandre.eaufrance.fr/geo/ouvrage?SERVICE=WMS&VERSION=1.1.1&R
EQUEST=GetMap&LAYERS=REPOM&WIDTH=400&HEIGHT=400&BBOX=-6,48,0,50&SRS=epsg:432
6&SLD=http://xml.sandre.eaufrance.fr/exist/Geo/sld/REPOM.xml>
&VERSION=1.1.1&REQUEST=GetMap&LAYERS=REPOM&WIDTH=400&HEIGHT=400&BBOX=-6,48,0
,50&SRS=epsg:4326&SLD=http://xml.sandre.eaufrance.fr/exist/Geo/sld/REPOM.xml
 
<http://services.sandre.eaufrance.fr/geo/ouvrage?SERVICE=WMS&VERSION=1.1.1&R
EQUEST=GetMap&LAYERS=REPOM&WIDTH=400&HEIGHT=400&BBOX=-5,48,-4,49&SRS=epsg:43
26&SLD=http://xml.sandre.eaufrance.fr/exist/Geo/sld/REPOM.xml>
http://services.sandre.eaufrance.fr/geo/ouvrage?SERVICE=WMS&VERSION=1.1.1&RE
QUEST=GetMap&LAYERS=REPOM&WIDTH=400&HEIGHT=400&BBOX=-5,48,-4,49&SRS=epsg:432
6&SLD=http://xml.sandre.eaufrance.fr/exist/Geo/sld/REPOM.xml
 
Using Geoserver with the same layers, when I ask for 3 images (400x400px)
for the REPOM layer at 3 differents scales (same as previous query), the
symbol is always the same size (15 as defined in the STYLES for geoserver).
http://sandre.eaufrance.fr/geoserver/wms?SERVICE=WMS
<http://sandre.eaufrance.fr/geoserver/wms?SERVICE=WMS&VERSION=1.1.1&REQUEST=
GetMap&LAYERS=REPOM&WIDTH=400&HEIGHT=400&BBOX=-6,41,10,52&SRS=epsg:4326&STYL
ES=REPOM&FORMAT=image/png>
&VERSION=1.1.1&REQUEST=GetMap&LAYERS=REPOM&WIDTH=400&HEIGHT=400&BBOX=-6,41,1
0,52&SRS=epsg:4326&STYLES=REPOM&FORMAT=image/png
http://sandre.eaufrance.fr/geoserver/wms?SERVICE=WMS
<http://sandre.eaufrance.fr/geoserver/wms?SERVICE=WMS&VERSION=1.1.1&REQUEST=
GetMap&LAYERS=REPOM&WIDTH=400&HEIGHT=400&BBOX=-6,41,10,52&SRS=epsg:4326&STYL
ES=REPOM&FORMAT=image/png>
&VERSION=1.1.1&REQUEST=GetMap&LAYERS=REPOM&WIDTH=400&HEIGHT=400&BBOX=-6,48,0
,50&SRS=epsg:4326&STYLES=REPOM&FORMAT=image/png
http://sandre.eaufrance.fr/geoserver/wms?SERVICE=WMS
<http://sandre.eaufrance.fr/geoserver/wms?SERVICE=WMS&VERSION=1.1.1&REQUEST=
GetMap&LAYERS=REPOM&WIDTH=400&HEIGHT=400&BBOX=-5,48,-4,49&SRS=epsg:4326&STYL
ES=REPOM&FORMAT=image/png>
&VERSION=1.1.1&REQUEST=GetMap&LAYERS=REPOM&WIDTH=400&HEIGHT=400&BBOX=-5,48,-
4,49&SRS=epsg:4326&STYLES=REPOM&FORMAT=image/png
 
Mapserver is setting the SIZE parameter in the class ... but maybe not
MAXSIZE and MINSIZE. In that case default value for MAXSIZE and MINSIZE are
used ? ... should we have SIZE=MAXSIZE=MINSIZE to have always the same size
for the symbol. 
 
This behaviour also occurs using well know shape as "square", "circle",
"triangle" ...
 
Any ideas on how to get symbol always with the same size ? Anyone having the
same behaviour ? 
 
Thanks for your help. 
Francois
 
PS : Geoserver doesn't support SLD parameter in the URL for the time being
so we have to define a style in Geoserver and the using keyword STYLES in
the URL.
 
 
 

-- 
Ce message a ete verifie par MailScanner pour des virus ou des polluriels et rien de suspect n'a ete trouve.

Les donnees et renseignements contenus dans ce message sont personnels, confidentiels et prives. Toute publication, utilisation ou diffusion, meme partielle, doit etre autorisee.

Any data and information contained in this electronic mail is personal, confidential and secret. Any total or partial publication, use or distribution must be authorized.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/mapserver-users/attachments/20060406/efae50b9/attachment.htm>


More information about the MapServer-users mailing list