negative values and colors in Ascii Grids

Carola Jesch cjesch at CCT.LSU.EDU
Mon Jan 16 14:46:54 EST 2006


Hi Frank,
I had a look to the raster-howto and the sources as well, but was unsure,
because I can't imagine that most users have grids that exactly have values
between 0 and 255 in it.
So sorry fot the questions.
Do you plan to implement a colormap for ascii grids like the clr for binary
grids? What would you suggest to display the negative values?

Thanks, Carola 

> -----Original Message-----
> From: fwarmerdam at gmail.com [mailto:fwarmerdam at gmail.com] On 
> Behalf Of Frank Warmerdam
> Sent: Monday, January 16, 2006 7:29 AM
> To: Carola Jesch
> Cc: MAPSERVER-USERS at lists.umn.edu
> Subject: Re: [UMN_MAPSERVER-USERS] negative values and colors 
> in Ascii Grids
> 
> On 1/15/06, Carola Jesch <cjesch at cct.lsu.edu> wrote:
> > Hi,
> >
> > I have an contineous ASCII GRID (floating values) that I 
> would like to 
> > display in MapServer. This grid shows bathymetry (ocean) 
> and elevation
> > (land) data. There are a lot of negative values for the ocean, 
> > starting from -1500 to 0 and only a small range for the land (0 to 
> > 20). When I am trying to display the grid, the entire image 
> is black. 
> > Does MapServer support negative values? How can I display 
> the grid with colors?
> > I have tried to convert the Ascii file to a binary grid, 
> but I don't 
> > know how to create a colormap (*.clr). ArcGIS doesn't seem 
> to support 
> > this or does anyone of you how to do that?
> 
> Carola,
> 
> By default Mapserver will read the grid values directly, and 
> clip any values outside the range 0 to 255 the bounds.  So 
> all your negative values are cliipped to zero, and the top 
> value is 20  (out of 255) which would appear nearly black.
> 
> The first step I would suggest is enabling autoscaling with 
> the layer directive:
> 
>   PROCESSING "SCALE=AUTO"
> 
> Beyond that I would suggest you review the raster howto.
> 
>   http://mapserver.gis.umn.edu/docs/howto/raster_data
> 
> 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    | Geospatial 
> Programmer for Rent
> 



More information about the mapserver-users mailing list