[mapserver-users] SLD not rendered correctly

Daniel Degasperi daniel.degasperi at r3-gis.com
Wed Nov 12 09:08:11 PST 2008


Hi James,

thx for your fast answer. I tried following piece of SLD, unfortunately 
the second PointSymbolizer overwrite the first one.

<StyledLayerDescriptor version="1.0.0" 
xmlns="http://www.opengis.net/sld" 
xmlns:gml="http://www.opengis.net/gml" 
xmlns:ogc="http://www.opengis.net/ogc" 
xmlns:xlink="http://www.w3.org/1999/xlink" 
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
xsi:schemaLocation="http://www.opengis.net/sld 
http://ogc.dmsolutions.ca/sld/1.0.0/StyledLayerDescriptor.xsd">
<NamedLayer>
<Name>tree</Name>
<UserStyle>
<FeatureTypeStyle>
<Rule>
<Name>IT:Pianta|DE:Pflanze</Name>
<PointSymbolizer>
<Graphic>
<Mark>
<WellKnownName>circle</WellKnownName>
<Fill>
    <CssParameter name="fill">#00c800</CssParameter>
</Fill>
</Mark>
<Size>5</Size>
</Graphic>
</PointSymbolizer>
<PointSymbolizer>
<Graphic>
<Mark>
<WellKnownName>circle</WellKnownName>
<Fill>
    <CssParameter name="fill">#006400</CssParameter>
</Fill>
</Mark>
<Size>2</Size>
</Graphic>
</PointSymbolizer>
</Rule>
</FeatureTypeStyle>
</UserStyle>
</NamedLayer>
</StyledLayerDescriptor>

Léveillé schrieb:
> Hi Daniel,
>  
> I'm no expert in SLD, but have you tried using 2 PointSymbolizer ?
>  
> That's what I'm doing (with lines) and it works great ...
>  
>  
>  
>                     <LineSymbolizer>
>                         <Geometry>
>                             <PropertyName>center-line</PropertyName>
>                         </Geometry>
>                         <Stroke>
>                             <CssParameter 
> name="stroke">#000000</CssParameter>
>                             <CssParameter 
> name="stroke-width">7.0</CssParameter>
>                         </Stroke>
>                     </LineSymbolizer>
>                     <LineSymbolizer>
>                         <Geometry>
>                             <PropertyName>center-line</PropertyName>
>                         </Geometry>
>                         <Stroke>
>                             <CssParameter 
> name="stroke">#009432</CssParameter>
>                             <CssParameter 
> name="stroke-width">5.0</CssParameter>
>                         </Stroke>
>                     </LineSymbolizer>
>  
>  
>  
>  
>  
>
> ______________________________________________________
>
> *JAMES LÉVEILLÉ
> *Service des systèmes de Mission
> Direction des technologies de l'information
> Ministère des Transports du Québec
>
> 5833, boul. Pierre-Bertrand, 2ième étage
> Québec (Québec) G2K 1K7
> Téléphone:   (418) 380-2005 poste 227
> Télécopieur: (418) 644-6653
> james.leveille at mtq.gouv.qc.ca <mailto:james.leveille at mtq.gouv.qc.ca>
>
>  
>
>     -----Message d'origine-----
>     *De :* mapserver-users-bounces at lists.osgeo.org
>     [mailto:mapserver-users-bounces at lists.osgeo.org] *De la part de*
>     Daniel Degasperi
>     *Envoyé :* 12 novembre 2008 10:36
>     *À :* mapserver-users at lists.osgeo.org
>     *Objet :* [mapserver-users] SLD not rendered correctly
>
>     Hello,
>
>     the attached SLD should render a point layer with an outlinecolor
>     (see stroke), unfortunately the stroke-color seems to overwrite
>     the fill color.
>     Images are attached. withoutsld.png would be the expected result,
>     withsld.png is the actual result.
>     Can anybody help me?
>
>     I'm using MapServer 5.0.3 on Centos5 and the render client is
>     OpenLayers.
>
>     These tickets could be related:
>
>         * http://trac.osgeo.org/mapserver/ticket/1887
>         * http://trac.osgeo.org/mapserver/ticket/2548
>
>
>     Regards, Daniel
>
>     -- 
>       Daniel Degasperi
>       Software Developer
>       daniel.degasperi at r3-gis.com
>       
>     ---------------------------
>       R3 GIS Srl
>       Via Johann Kravogl 2
>       I-39010 Merano - Sinigo (BZ)
>       Tel. +39 0473 494949
>       Fax. +39 0473 069902
>       Web  http://www.r3-gis.com
>     -----------------------------
>         
>


-- 
  Daniel Degasperi
  Software Developer
  daniel.degasperi at r3-gis.com
  
---------------------------
  R3 GIS Srl
  Via Johann Kravogl 2
  I-39010 Merano - Sinigo (BZ)
  Tel. +39 0473 494949
  Fax. +39 0473 069902
  Web  http://www.r3-gis.com
-----------------------------

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


More information about the MapServer-users mailing list