Ciao Fabio,
can you provide us with the style + the relevant dataset?

Regards,
Simone Giannecchini
-------------------------------------------------------
Ing. Simone Giannecchini
GeoSolutions S.A.S.
Founder

Via Poggio alle Viti 1187
55054  Massarosa (LU)
Italy

phone: +39 0584 962313
fax:      +39 0584 962313
mob:    +39 333 8128928

http://www.geo-solutions.it
http://geo-solutions.blogspot.com/
http://www.youtube.com/user/GeoSolutionsIT
http://www.linkedin.com/in/simonegiannecchini
http://twitter.com/simogeo

-------------------------------------------------------


On Tue, Feb 8, 2011 at 8:49 AM, Grita, Fabio (ESA) <[email protected]>wrote:

>  Hello,
> I have trouble rendering the opacity for a raster layer in Geoserver 2.0.2.
> I am trying to set the ocean (value 9999.0) as transparent. I am using the
> follwing SLD. Is there anything I am missing:
>
> <?xml version="1.0" encoding="UTF-8"?>
> <StyledLayerDescriptor xmlns="http://www.opengis.net/sld"; 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://schemas.opengis.net/sld/1.0.0/StyledLayerDescriptor.xsd*<http://schemas.opengis.net/sld/1.0.0/StyledLayerDescriptor.xsd>"
> version="1.0.0">
> <UserLayer>
>         <Name>rasterfao-ndvi</Name>
>         <LayerFeatureConstraints>
>             <FeatureTypeConstraint/>
>         </LayerFeatureConstraints>
>         <UserStyle>
>                 <Name>rasterfao-ndvi</Name>
>                 <Title>ndvi</Title>
>                 <Abstract>Automatically generated SLD from
> ndvi.clr</Abstract>
>                 <FeatureTypeStyle>
>                         <Rule>
>                                 <RasterSymbolizer>
>                                     <Opacity>1.0</Opacity>
>                                     <OverlapBehavior>
>                                        <AVERAGE/>
>                                     </OverlapBehavior>
>                                     <ColorMap type="ramp">
>
> <ColorMapEntry color="#709959" quantity="0.0" opacity="1.0" label="0 - 50
> m"/>
> <ColorMapEntry color="#80A362" quantity="50.0" opacity="1.0" label="50 -
> 100"/>
> <ColorMapEntry color="#91B06B" quantity="100.0" opacity="1.0" label="100 -
> 200"/>
> <ColorMapEntry color="#A1BA73" quantity="200.0" opacity="1.0" label="200 -
> 500"/>
> <ColorMapEntry color="#B3C77D" quantity="500.0" opacity="1.0" label="500 -
> 700"/>
> <ColorMapEntry color="#C7D48A" quantity="700.0" opacity="1.0" label="700 -
> 900"/>
> <ColorMapEntry color="#D8DE92" quantity="900.0" opacity="1.0" label="900 -
> 1100"/>
> <ColorMapEntry color="#EBE99D" quantity="1100.0" opacity="1.0" label="1100
> - 1300"/>
> <ColorMapEntry color="#F2ECA2" quantity="1300.0" opacity="1.0" label="1300
> - 1500"/>
> <ColorMapEntry color="#F2E89D" quantity="1500.0" opacity="1.0" label="1500
> - 1700"/>
> <ColorMapEntry color="#F2E59B" quantity="1700.0" opacity="1.0" label="1700
> - 1900"/>
> <ColorMapEntry color="#F2E196" quantity="1900.0" opacity="1.0" label="1900
> - 2100"/>
> <ColorMapEntry color="#F2DC91" quantity="2100.0" opacity="1.0" label="2100
> - 2300"/>
> <ColorMapEntry color="#F2D88F" quantity="2300.0" opacity="1.0" label="2300
> - 2500"/>
> <ColorMapEntry color="#F2D38A" quantity="2500.0" opacity="1.0" label="2500
> - 2700"/>
> <ColorMapEntry color="#F2CE85" quantity="2700.0" opacity="1.0" label="2700
> - 2900"/>
> <ColorMapEntry color="#EBC286" quantity="2900.0" opacity="1.0" label="2900
> - 3100"/>
> <ColorMapEntry color="#E6BA85" quantity="3100.0" opacity="1.0" label="3100
> - 3300"/>
> <ColorMapEntry color="#DEAF83" quantity="3300.0" opacity="1.0" label="3300
> - 3600"/>
> <ColorMapEntry color="#D9A882" quantity="3600.0" opacity="1.0" label="3600
> - 3900"/>
> <ColorMapEntry color="#D19D80" quantity="3900.0" opacity="1.0" label="3900
> - 4500"/>
> <ColorMapEntry color="#C9977F" quantity="4500.0" opacity="1.0" label="4500
> - 5000"/>
> <ColorMapEntry color="#C48F7E" quantity="5000.0" opacity="1.0" label="5000
> - 5500"/>
> <ColorMapEntry color="#C79183" quantity="5500.0" opacity="1.0" label="5500
> - 6000"/>
> <ColorMapEntry color="#D19B97" quantity="6000.0" opacity="1.0" label="6000
> - 6500"/>
> <ColorMapEntry color="#DBA9AB" quantity="6500.0" opacity="1.0" label="6500
> - 7000"/>
> <ColorMapEntry color="#E3B6BE" quantity="7000.0" opacity="1.0" label="7000
> - 7500"/>
> <ColorMapEntry color="#E8C36B" quantity="7500.0" opacity="1.0" label="7500
> - 8000"/>
> <ColorMapEntry color="#F0D3E1" quantity="8000.0" opacity="1.0"
> label="&gt;8000"/>
> <ColorMapEntry color="#D4CFC7" quantity="9999.0" opacity="0"
> label="Watermask"/>
> <ColorMapEntry color="#D4CFC7" quantity="65535.0" opacity="0" label="No
> Data"/>
>                                    </ColorMap>
>                                    </RasterSymbolizer>
>                         </Rule>
>                 </FeatureTypeStyle>
>         </UserStyle>
> </UserLayer>
> </StyledLayerDescriptor>
>
>
> This is the output I get, the value 9999.0 corresponds to the ocean.
>
>
>
> Many thanks,
> Fabio
>
>
>
> ------------------------------------------------------------------------------
> The ultimate all-in-one performance toolkit: Intel(R) Parallel Studio XE:
> Pinpoint memory and threading errors before they happen.
> Find and fix more than 250 security defects in the development cycle.
> Locate bottlenecks in serial and parallel code that limit performance.
> http://p.sf.net/sfu/intel-dev2devfeb
> _______________________________________________
> Geoserver-users mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/geoserver-users
>
>

<<PBrush 1.jpg>>

------------------------------------------------------------------------------
The ultimate all-in-one performance toolkit: Intel(R) Parallel Studio XE:
Pinpoint memory and threading errors before they happen.
Find and fix more than 250 security defects in the development cycle.
Locate bottlenecks in serial and parallel code that limit performance.
http://p.sf.net/sfu/intel-dev2devfeb
_______________________________________________
Geoserver-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geoserver-users

Reply via email to