[mapserver-users] using sld on the server

Pablo Cecconi pc at educ.ar
Wed Aug 5 06:33:43 PDT 2015


Hi, we are using SLDs generated by QGIS with Mapserver through the WMS SLD
parameter with very good results. You can even pass the parameter to a
mapcache instance to get a tile cache styled with SLDs.
Nevertheless, you should be aware of a few things:

- QGIS only allows you to specify sizes (i.e.: for symbols) in map units or
millimeters and Mapserver doesn't support Millimeters as a unit. So if you
use millimeters you will get very different symbol sizes on the Mapserver
render than what you see in QGIS. Our solution is to automatically apply a
factor to scale symbol sizes on our import SLD tool.

- QGIS allows you to define labels for a layer but the label styles are NOT
exported to the SLD file. Although Mapserver does support labels on SLD
files and works pretty well.

- We experienced some segmentation faults trying to use SLDs through
Mapscript so we ended up using the WMS parameter which works very well.

Hope these helps.
Cheers from Argentina!

Pablo


On Wed, Aug 5, 2015 at 8:56 AM, Rahkonen Jukka (MML) <
jukka.rahkonen at maanmittauslaitos.fi> wrote:

> Hi,
>
> Could you do one more test: read SLD out from Mapserver and push it back
> with WMS SLD or SLD_BODY. I suppose you will see a different map again at
> least if the styles are not very simple.
>
> -Jukka Rahkonen-
>
> Yves Jacolin wrote:
>
> On Saturday, June 27, 2015 10:57:46 Jachym Cepicky wrote:
> >> Hi all,
> >>
> >> is there possibility to style layer using SLD file configured in
> MapScript?
> >> Idea would be, instead of using CLASS for configuration, you would
> >> just pass the SLD and things would magically happen (just like it
> >> works in GeoServer).
> >>
> >> Generating MapFiles from QGIS would than be next logical step ..
> >>
> >> I assume, I've missed something and there must be solution for this
> >> lying around for couple of years, but did not find anything
> >>
> >> thanks for any hint
> >>
> > Jachym,
>
> > Take care of (probably) some difference between QGIS, GeoServer and
> MapServer on how to understand SLD information.
>
> > See my test from mapserver to QGIS and GeoServer:
> > * MapSever: https://twitter.com/yjacolin/status/464456432461828096
> > * GeoServer (same data, Style from MapServer SLD)
> > https://twitter.com/yjacolin/status/464456796548390912
> > * QGIS : https://twitter.com/yjacolin/status/464477708622503937
>
> > It wil be interesting to test SLD export/import in other direction (GS
> to QGIS and MS, QGIS to GS and MS).
>
> Y.
> --
> Responsable Formation et Support
> Camptocamp France SAS
> Savoie Technolac, BP 352
> 73377 Le Bourget du Lac, Cedex
> Tel (France) : +33 4 58 48 20 43 (new !) Tel (Suisse) : +41 21 619 10 43
> Mob. : +33 6 18 75 42 21 Fax : 04 79 70 15 81 Mail :
> yves.jacolin at camptocamp.com http://www.camptocamp.com
> _______________________________________________
> mapserver-users mailing list
> mapserver-users at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
> _______________________________________________
> mapserver-users mailing list
> mapserver-users at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/mapserver-users/attachments/20150805/6553ff4c/attachment-0001.html>


More information about the mapserver-users mailing list