[GRASS5] r.slope.aspect crash - libes/gis/null_data.c

Glynn Clements glynn.clements at virgin.net
Fri Jan 18 22:13:23 EST 2002


[CC to GRASS5]

Helena wrote:

> in case that you would have time to add it,
> this is that missing color table, it is used for both pcurv and tcurv
> - currently the output for curvatures will just give you
> blue map, so it appears that the output is incorrect.
> c1min is minimum value for profile curvature and c2min is minimum for tangential -
> c1max and c2max is the same for maximums.
> This colortable could be used also for partial derivatives output but I assume
> that whoever runs it with that option knows what is he doing and can chenge the
> colortable
> himself.

At present, the only colour table management performed by
r.slope.aspect is this:

        sprintf(buf, "r.colors map='%s' c=aspect",
		G_fully_qualified_name (aspect_name, G_mapset()));
	system(buf);

If there is supposed to be a "standard" colour table for gradient
and/or curvature maps, it should probably go into r.colors rather than
individual programs.

NB: the colour table in question is the following, from
src/libes/rst_gmsl/interp_float/output2d.c:

	MIN		127   0 255
	-0.01		  0   0 255
	-0.001		  0 127 255
	-0.00001	  0 255 255
	0.0		200 255 200
	0.00001		255 255   0
	0.001		255 127   0
	0.01		255   0   0
	MAX		255   0 200

Also, might it be better to map the extremes to some fixed value?

It might be a good idea to have at least one standard colour table
which *doesn't* adjust to the range of the data, to facilitate a
common colouring scheme across multiple maps.

Such a colour table would have to conceptually range between +/-
infinity (although a finite range could be useful for DEMs); r.colors
would extract a suitable subrange by interpolating arctangents.

-- 
Glynn Clements <glynn.clements at virgin.net>



More information about the grass-dev mailing list