I Thanks Markus, I didn't know I could export image groups directly from r.out.gdal. The GUI doesn't list image groups from the available inputs... I will tell Martin.<div><br></div><div>giovanni<br><br><div class="gmail_quote">
2011/9/19 Markus Metz <span dir="ltr"><<a href="mailto:markus.metz.giswork@googlemail.com">markus.metz.giswork@googlemail.com</a>></span><br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
<div class="im">On Mon, Sep 19, 2011 at 11:15 AM, G. Allegri <<a href="mailto:giohappy@gmail.com">giohappy@gmail.com</a>> wrote:<br>
> Thanks Hamish, r.out.tiff did the work. I already had tried it but I failed<br>
> because I dind't set the region correctly.<br>
> Anyway, setting the -t flag writes the TFW but doesn't make it a *true*<br>
> GTiff, because r.out.tiff writes a Baseline tiff, without the GTiff tags.<br>
> But that isn't a problem of course, I can produce a GTiff with another step<br>
> (eg gdal tools).<br>
<br>
</div>You can export a true GTiff with color as cell values instead of<br>
original cell values with<br>
<br>
# extract RGB values<br>
r.mapcalc "mymap.r = r#mymap; mymap.g = g#mymap; mymap.b = b#mymap"<br>
<br>
# create RGB group<br>
i.group group=mymap.rgb in=mymap.r,mymap.g,mymap.b<br>
<br>
# export RGB group<br>
r.out.gdal in=mymap.rgb out=mymap.tif -c<br>
<br>
The -c flag to skip export of the colortable because the raster values<br>
themselves hold the color info.<br>
<br>
Markus M<br>
<div class="im"><br>
> giovanni<br>
><br>
> 2011/9/17 Hamish <<a href="mailto:hamish_b@yahoo.com">hamish_b@yahoo.com</a>><br>
>><br>
>> Giovanni wrote:<br>
>> > The question is the object :)I have a Float raster which GRASS<br>
>> > displays with a certain color table (I haven't set it...<br>
>> > PS: what table is used by default?). What's the most effective<br>
>> > way to export the raster into a true color Geotiff (as a 3 Byte<br>
>> > bands with color interpretation) using a certain color table?<br>
>><br>
>> I believe that r.out.tiff will export using colors, not data.<br>
>> Add the -t flag to get a world file & so make it a geotiff.<br>
>><br>
>> In GRASS 6.4 the d.out.file module is another option, set the<br>
>> size= parameter to the number of rows and columns, and select<br>
>> format=geotiff.<br>
>><br>
>> The default color table is "rainbow", see the r.colors help page<br>
>> for details.<br>
>><br>
>><br>
>> Hamish<br>
><br>
><br>
</div>> _______________________________________________<br>
> grass-user mailing list<br>
> <a href="mailto:grass-user@lists.osgeo.org">grass-user@lists.osgeo.org</a><br>
> <a href="http://lists.osgeo.org/mailman/listinfo/grass-user" target="_blank">http://lists.osgeo.org/mailman/listinfo/grass-user</a><br>
><br>
><br>
</blockquote></div><br></div>