[GRASS5] Re: rules in r.colors

Michael Barton michael.barton at asu.edu
Fri May 14 19:55:06 EDT 2004


Glynn,

I understand this and how it is supposed to work the way you have it 
set up. Sorry if I was confusing in this regard. My suggestion was to 
build on your work in a somewhat different direction. With the new 
rules code you did, it is possible to read in text files of color 
rules. I was suggesting to use this same code to access user-defined 
files rather than a limited set of color table files located in the 
$GISBASE/etc/colors folder. It is indeed a different objective than 
yours was.

Perhaps it is problematic to do this. Having a set of predefined GRASS 
color tables is certainly handy (realizing that grey.eq, grey.log, and 
random are somewhat different beasts from the other color tables). For 
different reasons, it also seems a useful thing to build into r.colors 
the functionality of  'r.colors input=[map] <colortable.txt' so that a 
user could more easily access (and even share) custom color tables. The 
latter should not get mixed up with the standard predefined set.

I can't quite envision your suggestion for replacing the stdin option, 
but it seems interesting. While it is very handy to be able to create a 
color table on the fly as you can now, it would be even nicer to have 
the option to save this to a file (as I think you are suggesting?) to 
use again for various maps if you liked it (and not have to dig it out 
of the $GISBASE/$LOCATION/$MAPSET/colr directory (the rast=[map] option 
is a more efficient way of achieving the latter).

All in all, GRASS has some very nice and diverse ways of managing 
colors for raster files. Maybe it is already pretty much as good as it 
can get without a lot of trouble. But this discussion seems useful. 
Thanks for the work you've put into this.

Michael Barton
______________________________
Michael Barton, Professor & Curator
School of Human Origins, Cultures, & Societies
Arizona State University
Tempe, AZ  85287-2402
USA

voice: 480-965-6262; fax: 480-965-7671
www: http://www.public.asu.edu/~cmbarton
On May 14, 2004, at 4:02 PM, grass5-request at grass.itc.it wrote:

> No. As I've said at least twice before, that is *not* the purpose of
> the "rules=" option. The "rules=" option is intended solely as a
> transitional measure.
>
> The fact that the arguments to rules= happen to be files is an
> implementation detail, which shouldn't be visible to the user.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: text/enriched
Size: 2435 bytes
Desc: not available
Url : http://lists.osgeo.org/pipermail/grass-dev/attachments/20040514/72afa36a/attachment.bin


More information about the grass-dev mailing list