[GRASS-dev] new r.out.gdal fails to preserve 8bit color

Markus Neteler neteler at fbk.eu
Tue Nov 20 11:52:18 EST 2007



Maciej Sieczka wrote:
> 
> Maciej Sieczka wrote:
>> Exporting a CELL GRASS raster, value range 0-255, r.out.gdal issues an:
>> 
>> ERROR 6: SetColorInterpretation() not supported for this dataset.
>> 
>> and the output map is greyscale.
> 
> There is a discussion about this defect on the GDAL dev list:
> http://www.nabble.com/r.out.gdal%3A-SetColorInterpretation%28%29-not-supported-tf3021127.html
> 

I have submitted a fix to CVS. Now a valid color table is also written
in the case that the user does not manually select Byte/UInt16 type
*and* the data range supports this. I used a range check to preselect the 
GDAL type.
Additionally, the used GDAL data type is advertised in a new user message.

Finally the GeoTIFF color tables work easily :)
Tested with Spearfish: fields, spot.image, aspect, elevation.dem,
elevation.10m

Markus

PS: Proudly presented by 
       http://wiki.osgeo.org/index.php/European_GIS_Code_Sprint
-- 
View this message in context: http://www.nabble.com/new-r.out.gdal-fails-to-preserve-8bit-color-tf2871516.html#a13860630
Sent from the Grass - Dev mailing list archive at Nabble.com.



More information about the grass-dev mailing list