16-bit to 8-bit stretch options
Frank Warmerdam
warmerdam at POBOX.COM
Tue Feb 13 08:13:22 PST 2007
Vincent J. Troisi wrote:
> We have 16-bit geotiff images we are serving to google earth. Google earth
> is making requests for 8-bit images (png). However, when the conversion
> is done from 16-bit to 8-bit, some pixel values which are not "0" in the
> 16-bit geotiff get set to "0" during the conversion process. Is there
> anyway
> to control the options for this conversion in the map file? Is there a
> document
> available that describes the conversion process performed by mapserver?
Vincent,
There is no document describing this beyond what is in the Raster data
access howto and the mapfile refs.
Basically the only control you have over this is very careful selection
of the scaling range unless you want to setup classes for each range
mapping it to an output color.
I think you can use floating point values in the scaling info so with
care you should be able to come up with a scaling range that would map
0 to 0 and 1 to 1.
Best regards,
--
---------------------------------------+--------------------------------------
I set the clouds in motion - turn up | Frank Warmerdam, warmerdam at pobox.com
light and sound - activate the windows | http://pobox.com/~warmerdam
and watch the world go round - Rush | President OSGeo, http://osgeo.org
More information about the MapServer-users
mailing list