Good point Jukka, that's probably true. However the problem is we don't want to 
alter the original data file and lose information in it by down converting it 
to 8-bit RGB just for display, because we want to do processing on it later 
after displaying it. We were hoping WMS could do the proper conversion on the 
fly during display without altering the original data.
Thanks,
Scott

-----Original Message-----
From: Rahkonen Jukka [mailto:jukka.rahko...@mmmtike.fi] 
Sent: Thursday, August 11, 2011 3:07 PM
To: 'geoserver-users@lists.sourceforge.net'
Subject: Re: [Geoserver-users] problem with WMS raster display

Hi,

Mapserver mapfile had directive  PROCESSING "SCALE=52,2047"
Using same values in -scale option with gdal_traslate should give equivalent 
image.

-Jukka Rahkonen-


Andrea Aime wrote:
> 
> On Thu, Aug 11, 2011 at 10:23 PM, Scott Ellis 
> <sel...@ittvis.com> wrote:
> > Hi and thanks again for your response.
> >
> > I have tried various SLD's to no avail. The problem occurs 
> with the standard "raster" SLD that comes with GeoServer.
> >
> > In a separate email to your personal account, I have sent 
> the GeoTIFF data file that reproduces the problem. It is 
> about 4 MB so I hope it goes through. Please let me know if 
> you do not receive it. When you do, thanks so much for 
> loading it into GeoServer and taking a look at the behavior.
> 
> I did receive it and know why the image is not being 
> displayed properly.
> The source image has this structure:
> 
> Band 1 Block=1024x1 Type=UInt16, ColorInterp=Red
> Band 2 Block=1024x1 Type=UInt16, ColorInterp=Green
> Band 3 Block=1024x1 Type=UInt16, ColorInterp=Blue
> Band 4 Block=1024x1 Type=UInt16, ColorInterp=Alpha
> 
> That is, RGBA, but 16 bits per pixel. Before encoding to JPEG we have
> to reduce it to RGB 8 bits
> per pixel, that is done computing a dynamic stretching that involves
> only the pixels in the current
> area.
> As already said, it's not possible to use the entire image, especially
> because the encoding portion
> only sees the portion of the original image to be encoded (eventually
> rescaled, band-selected,
>  reprojected and so on).
> 
> I'm not sure if it's possible to do anything about this particular
> case with just SLD, your best
> bet is likely to find some software that can turn it into a 
> RGBA 8 bit.
> I've tried quickly with gdal_translate but with little success, the
> translated image becomes very
> very light, almost white in most parts.
> 
> 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
> Geoserver-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/geoserver-users
> 
------------------------------------------------------------------------------
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
Geoserver-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-users

------------------------------------------------------------------------------
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
Geoserver-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-users

Reply via email to