This is a long shot but if it was me I'd play with a virtual raster:
   gdalbuildvrt  -srcnodata "-999" -vrtnodata "255 255 255"  mosaic100.vrt
mosaic100.tif
My example above is probably not correct. It's assuming a single band or
channel input and 3 bands/channel output but hopefully you get my idea.

Rich



On Fri, Jan 31, 2014 at 2:18 PM, Smith, Michael <[email protected]>wrote:

>  Hi group,
>
>
>
> I am having a heck of a time figuring out how to have MapServer ignore
> NODATA values in a WMS.  Please help!
>
>
>
> ***THE DATA
>
>
>
> GDAL shows the NODATA value of this TIFF to be -999:
>
>
>
> C:\WorkSpace\medem2>gdalinfo mosaic100.tif
>
>   <snip>
>
>   NoData Value=-999
>
>
>
> I also confirmed this in ArcGIS, the NoData pixels do not draw.  The
> raster is a 32-bit float (a DEM).
>
>
>
> ***THE MAPFILE
>
>
>
> I have tried the following, which the docs all indicate should work:
>
>
>
>   PROCESSING "NODATA=-999"  (nodata pixels show as black)
>
>
>
>  PROCESSING "SCALE=-3,950"  (again nodata pixels -999 show as black, it
> does scale the rest of the data)
>
>
>
>   CLASS
>
>     EXPRESSION ([pixel] > -999)   (whole image is white)
>
>   END
>
>
>
>   PROCESSING "LUT=0:0,100:128,500:192,951:255"  (nodata pixels show black,
> it does apply the LUT correctly otherwise)
>
>
>
> ***CHECK IT OUT
>
>
>
> You can see this for yourself if you like, use this WMS:
>
>
> http://mapserver.maine.gov/wms/mapserv.exe?map=c:/wms/topos.map&;
>
>
>
> Choose the Maine_DEM_2m group
>
>
>
> ===============================
> *Michael Smith MS GISP*
> State GIS Manager, Maine Office of GIS
> State of Maine, Office of Information Technology
> *michael.smith _at_ maine.gov <http://maine.gov>* 207-215-5530
>
> Board Member, Maine GeoLibrary
> Education Chair, Maine GIS Users Group
> State Rep, National States Geographic Information Council
>
>
> State House Station 145
> 51 Commerce Drive
> Augusta, ME 04333-0145
> 69o 47' 58.9"W  44o 21' 54.8"N
>
> _______________________________________________
> mapserver-users mailing list
> [email protected]
> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>



-- 
Richard Greenwood
[email protected]
www.greenwoodmap.com

<<image001.jpg>>

_______________________________________________
mapserver-users mailing list
[email protected]
http://lists.osgeo.org/mailman/listinfo/mapserver-users

Reply via email to