Feature request #5742
Updated by Paolo Cavallini almost 7 years ago
* GRASS raster can have labels (very convenient, e.g. r.param.scale saves feature names along with categories)
* when saving to TIFF, these are stripped
* as a consequence, the flow DTM>Features raster>Feature vector strips the categories, and data are lost.
Of course we can Use raster values as categories, but keeping the labels would be much better. One way would be to pipe directly the two GRASS commands, without exporting in between, but this is not implemented yet.
Notes from Etienne Tourigny:
labels could be added as GTIFF metadata, which GDAL supports but I don't know how/if this could be done in GRASS
If the export is using r.out.gdal there must be a way to put/get metadata in a gtiff?
from r.out.gdal:
<pre>
metaopt=string[,string,...]
Metadata key(s) and value(s) to include
In the form of "META-TAG=VALUE", separate multiple entries with a comma. Not supported by all output format drivers.
</pre>
Notes from Benjamin Ducke:
Theoretically, it wouldn't be very hard to read the labels from the mapset in which SEXTANTE is storing the (temporary) GRASS datasets; they are saved as plain ASCII there.
However, the host GIS for SEXTANTE must then somehow deal with this additional data in some useful way (e.g. via a virtual raster attribute table).
* when saving to TIFF, these are stripped
* as a consequence, the flow DTM>Features raster>Feature vector strips the categories, and data are lost.
Of course we can Use raster values as categories, but keeping the labels would be much better. One way would be to pipe directly the two GRASS commands, without exporting in between, but this is not implemented yet.
Notes from Etienne Tourigny:
labels could be added as GTIFF metadata, which GDAL supports but I don't know how/if this could be done in GRASS
If the export is using r.out.gdal there must be a way to put/get metadata in a gtiff?
from r.out.gdal:
<pre>
metaopt=string[,string,...]
Metadata key(s) and value(s) to include
In the form of "META-TAG=VALUE", separate multiple entries with a comma. Not supported by all output format drivers.
</pre>
Notes from Benjamin Ducke:
Theoretically, it wouldn't be very hard to read the labels from the mapset in which SEXTANTE is storing the (temporary) GRASS datasets; they are saved as plain ASCII there.
However, the host GIS for SEXTANTE must then somehow deal with this additional data in some useful way (e.g. via a virtual raster attribute table).