We're updating the issue view to help you get more done. 

Raster styling: ChannelSelection/ContrastEnhancement not working properly

Description

The same style which I posted in does not work under 2.10.0 any more. Within the <ChannelSelection> I can permute values for <SourceChannelName> freely without having an effect on the result. Also my VendorOptions are not interpreted at all. GeoServer's log does not print any errors and the server returns a regular image, as if rendered with the default raster-style.

Here is the style from GEOS-7235:

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 <?xml version="1.0" encoding="ISO-8859-1"?> <StyledLayerDescriptor version="1.0.0" xsi:schemaLocation="http://www.opengis.net/sld http://schemas.opengis.net/sld/1.0.0/StyledLayerDescriptor.xsd" 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"> <NamedLayer> <Name>raster_contrast</Name> <UserStyle> <Title>Raster Contrast Enhancement</Title> <Abstract>Raster style with custom contrast adjustment</Abstract> <FeatureTypeStyle> <Rule> <Name>rule1</Name> <Title>Opaque Raster</Title> <Abstract>A raster with 100% opacity and custom contrast</Abstract> <RasterSymbolizer> <Opacity>1.0</Opacity> <ChannelSelection> <RedChannel> <SourceChannelName>1</SourceChannelName> <ContrastEnhancement> <Normalize> <VendorOption name="algorithm">StretchToMinimumMaximum</VendorOption> <VendorOption name="minValue">33</VendorOption> <VendorOption name="maxValue">227</VendorOption> </Normalize> <GammaValue>0.6</GammaValue> </ContrastEnhancement> </RedChannel> <GreenChannel> <SourceChannelName>2</SourceChannelName> <ContrastEnhancement> <Normalize> <VendorOption name="algorithm">StretchToMinimumMaximum</VendorOption> <VendorOption name="minValue">44</VendorOption> <VendorOption name="maxValue">225</VendorOption> </Normalize> <GammaValue>0.6</GammaValue> </ContrastEnhancement> </GreenChannel> <BlueChannel> <SourceChannelName>3</SourceChannelName> <ContrastEnhancement> <Normalize> <VendorOption name="algorithm">StretchToMinimumMaximum</VendorOption> <VendorOption name="minValue">46</VendorOption> <VendorOption name="maxValue">227</VendorOption> </Normalize> <GammaValue>0.6</GammaValue> </ContrastEnhancement> </BlueChannel> </ChannelSelection> </RasterSymbolizer> </Rule> </FeatureTypeStyle> </UserStyle> </NamedLayer> </StyledLayerDescriptor>

Environment

Ubuntu 16.04 Server x64, Oracle Java 1.8, Native JAI

Status

Assignee

Daniele Romagnoli

Reporter

MichaelS

Triage

Fix versions

Affects versions

2.10.0

Components

Priority

Medium