Opened 9 years ago
Last modified 9 years ago
#5761 closed defect
gdalwarp zeroes all alpha pixels from grey+alpha image — at Initial Version
Reported by: | cdestigter | Owned by: | warmerdam |
---|---|---|---|
Priority: | normal | Milestone: | |
Component: | default | Version: | svn-trunk |
Severity: | normal | Keywords: | |
Cc: |
Description
When warping a grey+alpha image, gdal appears to zero out all the alpha pixels, resulting in a completely invisible image.
test case:
gdalinfo -stats ~/c/in.tif | grep Minimum rm -f ~/c/out.tif ; gdalwarp ~/c/in.tif ~/c/out.tif gdalinfo -stats ~/c/out.tif | grep Minimum
Minimum=0.000, Maximum=176.000, Mean=86.546, StdDev=59.195 Minimum=0.000, Maximum=255.000, Mean=176.375, StdDev=117.760 Creating output file that is 16P x 15L. Processing input file /Users/cdestigter/c/in.tif. 0...10...20...30...40...50...60...70...80...90...100 - done. Minimum=0.000, Maximum=176.000, Mean=86.546, StdDev=59.195 Minimum=0.000, Maximum=0.000, Mean=0.000, StdDev=0.000
Adding -setci doesn't help. If I add -dstalpha I get a good alpha band in band 3, but then I have to remove band 2 somehow.
Tested on both stock 1.11.0 and a recent trunk fork (specifically https://github.com/koordinates/gdal/commit/164434f0759ed2b5fac2f0533abe5e099e56b4e4 )
Will attach in.tif.
Note:
See TracTickets
for help on using tickets.