Dear Geoserver Users,
I’m trying to display contours coming from a Barnes surface interpolation. The Interpolated Surfaces works well stand-alone, but the chaining into the contour extraction does not work.
My SLD looks like this:
<?xml version="1.0" encoding="ISO-8859-1"?><StyledLayerDescriptor version=“1.0.0”
xsi:schemaLocation=“http://www.opengis.net/sld 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”>
Barnes surface contours
Barnes Surface contoursA style that produces a Barnes surface using a rendering transformation
<ogc:Function name=“gs:Contour”>
<ogc:Function name=“parameter”>
ogc:Literaldata</ogc:Literal>
<ogc:Function name=“gs:BarnesSurface”>
<ogc:Function name=“parameter”>
ogc:Literaldata</ogc:Literal>
</ogc:Function>
<ogc:Function name=“parameter”>
ogc:LiteralvalueAttr</ogc:Literal>
ogc:Literalbewertung_bo_wert</ogc:Literal>
</ogc:Function>
<ogc:Function name=“parameter”>
ogc:Literalscale</ogc:Literal>
ogc:Literal1000</ogc:Literal>
</ogc:Function>
<ogc:Function name=“parameter”>
ogc:Literalconvergence</ogc:Literal>
ogc:Literal0.8</ogc:Literal>
</ogc:Function>
<ogc:Function name=“parameter”>
ogc:Literalpasses</ogc:Literal>
ogc:Literal3</ogc:Literal>
</ogc:Function>
<ogc:Function name=“parameter”>
ogc:LiteralminObservations</ogc:Literal>
ogc:Literal1</ogc:Literal>
</ogc:Function>
<ogc:Function name=“parameter”>
ogc:LiteralmaxObservationDistance</ogc:Literal>
ogc:Literal10000</ogc:Literal>
</ogc:Function>
<ogc:Function name=“parameter”>
ogc:LiteralpixelsPerCell</ogc:Literal>
ogc:Literal10</ogc:Literal>
</ogc:Function>
<ogc:Function name=“parameter”>
ogc:LiteralqueryBuffer</ogc:Literal>
ogc:Literal40</ogc:Literal>
</ogc:Function>
<ogc:Function name=“parameter”>
ogc:LiteraloutputBBOX</ogc:Literal>
<ogc:Function name=“env”>
ogc:Literalwms_bbox</ogc:Literal>
</ogc:Function>
</ogc:Function>
<ogc:Function name=“parameter”>
ogc:LiteraloutputWidth</ogc:Literal>
<ogc:Function name=“env”>
ogc:Literalwms_width</ogc:Literal>
</ogc:Function>
</ogc:Function>
<ogc:Function name=“parameter”>
ogc:LiteraloutputHeight</ogc:Literal>
<ogc:Function name=“env”>
ogc:Literalwms_height</ogc:Literal>
</ogc:Function>
</ogc:Function>
</ogc:Function>
<ogc:Function name=“parameter”>
ogc:Literallevels</ogc:Literal>
ogc:Literal-20</ogc:Literal>
ogc:Literal-15</ogc:Literal>
ogc:Literal-10</ogc:Literal>
ogc:Literal-5</ogc:Literal>
ogc:Literal0</ogc:Literal>
ogc:Literal5</ogc:Literal>
ogc:Literal20</ogc:Literal>
</ogc:Function>
</ogc:Function>
</ogc:Function>
rule1
Isotherm#000000
1
<ogc:Function name=“round”>
ogc:PropertyNamevalue</ogc:PropertyName>
</ogc:Function>
Arial
Normal
12
ogc:Literal2</ogc:Literal>
#FFFFFF
0.6
#000000
2000
true
100
50
30
I get the following exception:
Caused by: java.security.InvalidParameterException: Could not convert the value [GridCoverage2D[“Process Results”, GeneralEnvelope[(4426557.1796875, 5312865.4335937), (4491521.1796875, 5364506.7382812)], DefaultProjectedCRS[“DHDN / 3-degree Gauss-Kruger zone 4”]]
? RenderedSampleDimension(“Process Results”:[-999 … 10])
? ? GeophysicsCategory(“Process Results”:[-999.0 … 10.137810707092171])
? GeophysicsCategory(“No data”:[NaN(0…0)])
? Image=WritableRenderedImageAdapter
, {levels=[-20, -15, -10, -5, 0, 5, 20]}] into the expected type class org.geotools.coverage.grid.GridCoverage2D for parameter data
at org.geotools.process.function.ProcessFunction.evaluateInputs(ProcessFunction.java:198)
at org.geotools.process.function.ProcessFunction.evaluate(ProcessFunction.java:103)
at org.geotools.renderer.lite.StreamingRenderer.applyRenderingTransformation(StreamingRenderer.java:2224)
at org.geotools.renderer.lite.StreamingRenderer.processStylers(StreamingRenderer.java:1984)
at org.geotools.renderer.lite.StreamingRenderer.paint(StreamingRenderer.java:814)
at org.geoserver.wms.map.RenderedImageMapOutputFormat.produceMap(RenderedImageMapOutputFormat.java:490)
This message says it cannot convert a GridCoverage2D into a GridCoverage2D – strange?
Any idea what could help here?
I’m running Geoserver 2.2.0 with the corresponding WPS module in a Java6 environment.
Kind regards,
Sebastian Schmidt
SWM -Besser leben mit M.
Informations- und Prozesstechnik
Anwendungen Technische Geschäftsfelder
Telefon: 089/23 61-44 78
Telefax: 089-2361-70 44 78
schmidt.sebastian2@anonymised.com
www.swm.de
SWM Services GmbH, Emmy-Noether-Straße 2, 80992 München; Geschäftsführer Dr. Florian Bieberbach, Herbert König, Reinhard Büttner, Stephan Schwarz, Erna-Maria Trixl; Sitz München; Registergericht München HRB 126 674; Aufsichtsratsvorsitzender Oberbürgermeister Christian Ude
Der Inhalt dieser E-Mail oder eventueller Anhänge ist ausschließlich für den bezeichneten Adressaten bestimmt. Wenn Sie nicht der vorgesehene Adressat dieser E-Mail oder dessen Vertreter sein sollten, so beachten Sie bitte, dass jede Form der Kenntnisnahme, Veröffentlichung, Vervielfältigung oder Weitergabe des Inhalts dieser E-Mail unzulässig ist. Wir bitten Sie, sich in diesem Fall mit dem Absender der E-Mail in Verbindung zu setzen.