<div dir="ltr"><div class="gmail_quote"><div class="HOEnZb"><div class="h5"><div dir="ltr"><div class="gmail_quote"><div dir="ltr"><div><div><div><div>Hello all,<br><br></div>I have set up an SLD for a raster WMS as a test.  I want our WMS user to be able to supply their own SLD, with the aim of presenting a raster with categorical values in various colors according to pixel value, with some of them, which represent flag values, transparent.  Based on my experiments, and this 6-year-old thread, it appears that MapServer can't do this?<br>


<br></div>I'd like the SLD to read something like this:<br><br><?xml version="1.0" encoding="UTF-8"?><br><StyledLayerDescriptor version="1.0.0"<br>  xmlns="<a href="http://www.opengis.net/sld" target="_blank">http://www.opengis.net/sld</a>"<br>


  xmlns:se="<a href="http://www.opengis.net/se" target="_blank">http://www.opengis.net/se</a>"<br>  xmlns:ogc="<a href="http://www.opengis.net/ogc" target="_blank">http://www.opengis.net/ogc</a>"<br>  xmlns:xlink="<a href="http://www.w3.org/1999/xlink" target="_blank">http://www.w3.org/1999/xlink</a>"<br>


  xmlns:xsi="<a href="http://www.w3.org/2001/XMLSchema-instance" target="_blank">http://www.w3.org/2001/XMLSchema-instance</a>"<br>  xsi:schemaLocation="<a href="http://www.opengis.net/sld" target="_blank">http://www.opengis.net/sld</a><br>


  <a href="http://schemas.opengis.net/sld/1.0.0/StyledLayerDescriptor.xsd" target="_blank">http://schemas.opengis.net/sld/1.0.0/StyledLayerDescriptor.xsd</a>"><br>  <NamedLayer><br>    <se:Name>freezethaw_amsre</se:Name><br>


      <UserStyle><br>        <se:Name>xxx</se:Name><br>        <se:FeatureTypeStyle><br>          <se:Rule><br>            <se:RasterSymbolizer><br>              <se:ColorMap type="values"><br>


                  <ColorMapEntry color="#0000ff" quantity="0" opacity="1" /><br>                  <ColorMapEntry color="#ff0000" quantity="1" opacity="1" /><br>


                  <ColorMapEntry color="#a5a500" quantity="2" opacity="1" /><br>                  <ColorMapEntry color="#00ff00" quantity="3" opacity="1" /><br>


                  <ColorMapEntry color="#ffffff" quantity="251" opacity="0" /><br>                  <ColorMapEntry color="#111111" quantity="252" opacity="0" /><br>


                  <ColorMapEntry color="#775533" quantity="254" opacity="0" /><br>                  <ColorMapEntry color="#7799bb" quantity="255" opacity="0" /><br>


              </se:ColorMap><br>            </se:RasterSymbolizer><br><br>          </se:Rule><br>        </se:FeatureTypeStyle><br>      </UserStyle><br>  </NamedLayer><br></StyledLayerDescriptor><br>


<br></div>I only seem to be able to change the opacity of the entire image -- not of specific regions within the image according to pixel value.  Is there a way to achieve this using MapServer?<br><br></div>Thanks in advance,<br>


Bruce<br></div><div class="gmail_extra"><div><div><br><br><div class="gmail_quote">On Mon, Nov 12, 2007 at 7:15 AM, Yewondwossen Assefa <span dir="ltr"><<a href="mailto:yassefa@dmsolutions.ca" target="_blank">yassefa@dmsolutions.ca</a>></span> wrote:<br>


<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div>Jacolin Yves wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Hi,<br>
<br>
I am trying to set up a fill-opacity via an SLD url for a polygonal layer. I thought succeed to realize this last week but I failed to do it after changing some code in my application. I read this bug (4 years old): <a href="http://trac.osgeo.org/mapserver/ticket/1155" target="_blank">http://trac.osgeo.org/<u></u>mapserver/ticket/1155</a> and think it is impossible to do it.<br>



<br>
My question: is it possible to change the opacity of a layer using an SLD url?<br>
<br>
</blockquote></div>
SLD 1.0 does not support the opacity parameter at a layer level except for the raster symbolizer. SLD supports opacity setting at "CLASS" level but MapServer does not have the capacity for now to specify opacity per class/style.<div>


<br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
I am afraid to had dream last week :(<br>
<br>
Y.<br>
</blockquote>
<br>
<br>
-- <br></div>
------------------------------<u></u>------------------------------<u></u>----<br>
Assefa Yewondwossen<br>
Software Analyst<br>
<br>
Email: <a href="mailto:assefa@dmsolutions.ca" target="_blank">assefa@dmsolutions.ca</a><br>
<a href="http://www.dmsolutions.ca/" target="_blank">http://www.dmsolutions.ca/</a><br>
<br>
Phone: <a href="tel:%28613%29%20565-5056" value="+16135655056" target="_blank">(613) 565-5056</a> (ext 14)<br>
Fax:   <a href="tel:%28613%29%20565-0925" value="+16135650925" target="_blank">(613) 565-0925</a><br>
------------------------------<u></u>------------------------------<u></u>----<br>
</blockquote></div><br><br clear="all"><br></div></div><span><font color="#888888">-- <br>Bruce Raup<br><a href="http://cires.colorado.edu/~braup/" target="_blank">http://cires.colorado.edu/~braup/<br clear="all">
<br>-- <br>Bruce Raup<br>http://cires.colorado.edu/~braup/<br clear="all"><br>-- <br>Bruce Raup<br>http://cires.colorado.edu/~braup/

</a></font></span></div></div></div></div></div></div></div>