Re: [GRASS-dev] color tables question

2011-01-16 Thread Hamish
Michael wrote:
> Is there a way when you 1) reproject or 2) georectify a map
> to bring its color table with it into the target
> location/mapset?

I was under the impression that that happened already for both
scenarios.
 
> Or do you have to manually copy the color table from the
> original mapet to the new one?

I'm pretty sure that's not needed, both from memory and from
a quick grep of the code:

grass65/raster/r.proj$ grep color *
main.c:  orows, ocols, have_colors, /* Input map has a colour table */
main.c:have_colors = G_read_colors(inmap->answer, setname, &colr);
main.c:if (have_colors > 0) {
main.c: G_write_colors(mapname, G_mapset(), &colr);
main.c: G_free_colors(&colr);


grass65/imagery/i.rectify$ grep color *
exec.c: colr_ok = G_read_colors(name, mapset, &colr) > 0;
exec.c: G_write_colors(result, G_mapset(), &colr);
exec.c: G_free_colors(&colr);



> If the latter, perhaps a nice enhancement to r.color would be
> the ability to copy a color table from ANY other map and not
> just those in the current location.

if you like, Glynn's new r.colors.out + 'r.colors rules=' will
do that outside of the automation.



Hamish



  
___
grass-dev mailing list
grass-dev@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-dev


[GRASS-dev] color tables question

2011-01-16 Thread Michael Barton
Some has probably asked this sometime before and I missed it.

Is there a way when you 1) reproject or 2) georectify a map to bring its color 
table with it into the target location/mapset?

Or do you have to manually copy the color table from the original mapet to the 
new one? If the latter, perhaps a nice enhancement to r.color would be the 
ability to copy a color table from ANY other map and not just those in the 
current location.

Michael

C. Michael Barton
Director, Center for Social Dynamics & Complexity
Professor of Anthropology, School of Human Evolution & Social Change
Arizona State University

voice:  480-965-6262 (SHESC), 480-727-9746 (CSDC)
fax:  480-965-7671 (SHESC),  480-727-0709 (CSDC)
www: http://www.public.asu.edu/~cmbarton, http://csdc.asu.edu











___
grass-dev mailing list
grass-dev@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-dev