Maybe you can just define the layer 2X in the mapfile. Put the altered layer on top of the regular layer? I am assuming that you can get the good values to be transparent and not white.
On Tue, Apr 26, 2011 at 11:57 AM, Matt Bartolome <[email protected]> wrote: > Hello, > I have a funky raster I'm trying to tile as jpegs. For whatever reason this > RGB raster has white pixels on the source raster which should be black. Is > it possible to set only these white pixels to be black on the output jpeg? I > was playing around with the CLASS directive. This sets all those white > pixels to black, but it does not preserve the rest of the rgb that I want to > use; those "good" values are not processed and show as blank (white) space. > How do I do this? I thought of preprocessing this with gdalwarp but the > raster becomes too large (source is an ecw) on output so need to do it > on-the-fly with mapserver (I'm using mapserver trunk and gdal 1.8 on linux). > > Thanks! > Matt > > OUTPUTFORMAT > NAME jpeg > DRIVER "AGG/JPEG" > MIMETYPE "image/jpeg" > IMAGEMODE RGB > EXTENSION "jpg" > END > > LAYER > NAME "test" > TYPE RASTER > STATUS ON > DATA "/test.tif" > > PROJECTION > "init=epsg:2230" > END > > PROCESSING "NODATA=255" > > CLASS > NAME "set white to black" > EXPRESSION ([red] = 255 AND [green] = 255 AND [blue] = 255) > STYLE > COLOR 0 0 0 > END > > END > > _______________________________________________ > mapserver-users mailing list > [email protected] > http://lists.osgeo.org/mailman/listinfo/mapserver-users > > _______________________________________________ mapserver-users mailing list [email protected] http://lists.osgeo.org/mailman/listinfo/mapserver-users
