We are trying to convert a 16-bit img into an 8-bit tif.  Unfortunately,
the colors appear VERY dark (not downconverted, but just plain dark).  I
suspect that this has something to do with the histogram.  The gdalinfo
of the original image can be found here <http://pastebin.com/cmVxRJyE> .

 

When I tell GDAL to convert straight from 16-bit to 8-bit with:

gdal_translate -ot Byte -of GTiff 28jan09_worldview_tucumcari_nm.img
output.tif

I get what looks like the original image with clouds covering it...
almost solid white. (See the gdalinfo here
<http://pastebin.com/ike52mMp> )

 

When I scale around 16-bits:

gdal_translate -ot Byte -of GTiff -scale 0 65535 0 255
28jan09_worldview_tucumcari_nm.img output.tif

I get a solid black image.  (See the gdalinfo here
<http://pastebin.com/XpJL6AQY> )

 

When I scale around the extents specified by the histogram:

gdal_translate -ot Byte -of GTiff -scale 117 2047 0 255
28jan09_worldview_tucumcari_nm.img output.tif

I get the dark image described above. (See the gdalinfo here
<http://pastebin.com/Ju4azd47> )

 

I suspect if we can get GDAL to process and remove the histogram, we
will not have these issues.  Any help in doing this or further
diagnosing the issue would be greatly appreciated.




***This e-mail message is intended only for the above named recipient(s)
and may contain information that is sensitive or proprietary. If you have
received this message in error or are not the named recipient(s), please 
immediately notify the sender, delete this e-mail message without making
a copy and do not disclose or relay this e-mail message to anyone.***

Attachment: gdalinfoRound1
Description: gdalinfoRound1

Attachment: gdalinfoRound2
Description: gdalinfoRound2

_______________________________________________
gdal-dev mailing list
gdal-dev@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/gdal-dev

Reply via email to