Hi and thanks for your response.
No I'm not using contrast stretching in the raster symbolizer although I
did try that and it did not solve the problem. So are you saying the way
GeoServer WMS is working in this case is by design? I'm pretty sure the
screenshot I posted would be unacceptable to most users. Or is it
assumed that raster data is always preprocessed to fit nicely in the 0
to 255 range across the file before using GeoServer WMS on it?
Using MapServer WMS I was able to solve the problem by using the
following processing directive in the mapfile:
PROCESSING "SCALE=52,2047"
While the default setting of:
PROCESSING "SCALE=AUTO"
produces the same result as GeoServer.
Is there anything equivalent to that setting in GeoServer? Do you think
I could maybe fix this in the GeoServer java code? If so, can you point
me to the particular java classes that cause this behavior so I can try
to fix it?
Thanks very much,
Scott
From: [email protected] [mailto:[email protected]] On Behalf Of
Andrea Aime
Sent: Thursday, August 11, 2011 12:41 PM
To: Scott Ellis
Cc: [email protected]
Subject: Re: [Geoserver-users] problem with WMS raster display
On Thu, Aug 11, 2011 at 8:22 PM, Scott Ellis <[email protected]> wrote:
Hi, I have registered some GeoTIFF raster data with GeoServer and am
displaying it in a browser using OpenLayers. The raster data for the
whole file ranges from 52 to 2047. The problem is that GeoServer
stretches the raster data to fit from 0 to 255 based on the min/max of
each tile or the bounding box instead of the min/max of the overall
file. This means the image looks good when zoomed out, but as you zoom
in the problem gets worse and worse. Please see the attached image
below. In the middle of the lake, the min/max of the data in that tile
has narrow range so the effect is most apparent. The same problem
appears in single tile mode based on the bounding box.
Is there a way to make GeoServer stretch the raster data based on the
min/max of the whole file and not the particular tile or the bounding
box?
Just to be sure, are you applying contrast stretching in the raster
symbolizer?
Afaik there is no way to make it use the whole file statistics, for
large mosaics it would literally kill the server to compute
that (we often play with mosaic several TB large)
Cheers
Andrea
--
-------------------------------------------------------
Ing. Andrea Aime
GeoSolutions S.A.S.
Tech lead
Via Poggio alle Viti 1187
55054 Massarosa (LU)
Italy
phone: +39 0584 962313
fax: +39 0584 962313
http://www.geo-solutions.it
http://geo-solutions.blogspot.com/
http://www.youtube.com/user/GeoSolutionsIT
http://www.linkedin.com/in/andreaaime
http://twitter.com/geowolf
-------------------------------------------------------
------------------------------------------------------------------------------
Get a FREE DOWNLOAD! and learn more about uberSVN rich system,
user administration capabilities and model configuration. Take
the hassle out of deploying and managing Subversion and the
tools developers use with it.
http://p.sf.net/sfu/wandisco-dev2dev
_______________________________________________
Geoserver-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geoserver-users