color palette on a Arc Info Binary Grid (ADF)
Matthew Perry
mtperry78 at SBCGLOBAL.NET
Wed Apr 6 10:03:01 PDT 2005
Raghu,
I've classified ArcInfo GRIDs using CLASS
expressions based on the pixel value. Here's a mapfile
sample:
LAYER
NAME "wildlife_habitat"
STATUS OFF
TYPE RASTER
# Folder containing the hdr.adf
DATA "kb_veg_grid/kbshr_v10a/"
CLASSITEM "[pixel]"
CLASS
NAME "Mixed Conifer"
EXPRESSION ([pixel] < 48 OR [pixel] == 159)
COLOR 0 123 27
END
CLASS
NAME "Conifer/Hardwood"
EXPRESSION ([pixel] >= 48 AND [pixel] < 81)
COLOR 78 221 0
END
....
....
END
Hope this helps. I did this manually which was
time-consuming given that I had 35+ classes.
There *might* be a way to convert your color table
(.clr) to classes or have gdal use the .clr
directly.... but I will defer to the rest of the list
on that one.
Good luck,
Matt Perry
Humboldt State University
--- "Shantha, Raghavendra Vasanth" <raghu at KU.EDU>
wrote:
> Hi,
>
> I was looking for a way to apply different color
> palettes (say shades of
> red, green etc) to a gray scale Arc Info Binary Grid
> (ADF) Raster file
> using mapserver.
>
> Any ideas as to how I can do this?
>
>
> Thanks,
> Raghu
>
More information about the MapServer-users
mailing list