Thk u very much. I have two questions. 1.If I want to use the following combination, Red=Band3 Green=Band2*0.8+band4*0.2; Blue=band1 2. what is the general combination for good look jpeg file?
>weixj2003ld wrote: >> I read a geotiff file, and find that >> poBand->GetColorTable()==NULL > >Wei, > >Presumably GetColorTable() returns NULL because the GeoTIFF file >does not have a color table. > >> But I use ERDAS IMAGINE9.2 (a software that deal with geotiff), I find >> that it is not grey,but I use "gdal_translate -b 6 -of JPEG old.tif >> net.jpg", find that is is grey. > >Well, you are selecting only one band withouta color table to export >to net.jpg. How do you expect it to be anything other than greyscale? >If you want an RGB jpeg file then select three bands to be used as >red, green and blue. > >eg. >gdal_translate -b 4 -b 5 -b 6 o-of JPEG old.tif net.jpg > >Best regards, > >-- >---------------------------------------+-------------------------------------- >I set the clouds in motion - turn up | Frank Warmerdam, warmer...@pobox.com >light and sound - activate the windows | http://pobox.com/~warmerdam >and watch the world go round - Rush | Geospatial Programmer for Rent >
_______________________________________________ gdal-dev mailing list gdal-dev@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/gdal-dev