[gdal-dev] add string field to img

Chaitanya kumar CH chaitanya.ch at gmail.com
Tue Jul 24 07:13:58 PDT 2012


You can add this info as meta-data tags. You will have to define your own
names for the keys. Something like pix_1_class, pix_2_class, etc.

To add these you can use the -mo option with gdal_translate[1] or use a vrt
file[2]. You can create such a vrt file using gdal_translate too by setting
the output format (-of) to VRT.

[1]: http://www.gdal.org/gdal_translate.html
[2]: http://www.gdal.org/gdal_vrttut.html

On Tue, Jul 24, 2012 at 7:27 PM, jdmorgan <jdmorgan at unca.edu> wrote:

> Hello,
> I was hoping someone could help me out.  I have a raster .img file. with
> existing pixel values.  Those values are integer, but are classed to string
> values not currently in the same .img file.  For example pixel value 2
> means ClassTwo. Is it possible to add the string values (a new field) onto
> the raster .img file?
> Thanks,
> Derek
> ______________________________**_________________
> gdal-dev mailing list
> gdal-dev at lists.osgeo.org
> http://lists.osgeo.org/**mailman/listinfo/gdal-dev<http://lists.osgeo.org/mailman/listinfo/gdal-dev>

Best regards,
Chaitanya kumar CH.

17.2416N 80.1426E
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/gdal-dev/attachments/20120724/c7881a1b/attachment.html>

More information about the gdal-dev mailing list