Opened 18 years ago

Closed 17 years ago

#1013 closed defect (fixed)

gdalwarp with output GTiff separate deflate fails

Reported by: dem@… Owned by: Mateusz Łoskot
Priority: normal Milestone: 1.4.2
Component: GDAL_Raster Version: unspecified
Severity: normal Keywords:
Cc: warmerdam

Description (last modified by Mateusz Łoskot)

Hi,

I use GDAL >1.3.1 with external libtiff 3.7.4

the next comands:

gdalwarp -co "INTERLEAVE=PIXEL" -co "COMPRESS=DEFLATE" \
   rgb_separate_tiled.tif bug.tif

give theses errors:

ERROR 1: ZIPDecode:bug.tif: Decoding error at scanline xxx,
incorrect header check
ERROR 1: TIFFReadEncodedStrip() failed.
tiffinfo rgb_separate_tiled.tif
TIFF Directory at offset 0x360008
  Image Width: 1296 Image Length: 648
  Tile Width: 256 Tile Length: 256
  Bits/Sample: 8
  Sample Format: unsigned integer
  Compression Scheme: None
  Photometric Interpretation: RGB color
  Samples/Pixel: 3
  Planar Configuration: separate image planes

Julien

Attachments (1)

rgb_separate_tiled.tif (768.4 KB ) - added by dem 17 years ago.

Download all attachments as: .zip

Change History (6)

comment:2 by warmerdam, 17 years ago

Cc: warmerdam added
Description: modified (diff)
Milestone: 1.4.2
Owner: changed from warmerdam to Mateusz Łoskot
Priority: highnormal

Matuesz,

I would like you to try and reproduce this with GDAL 1.4.0 using the internal libtiff. If that works, we will close the bug unless Julien can provide information indicating the problem still exists. But I think this has been fixed by recent changes in libtiff.

comment:3 by Mateusz Łoskot, 17 years ago

Description: modified (diff)

comment:4 by Mateusz Łoskot, 17 years ago

Status: newassigned

Julien,

I'm not sure if it matters that your TIFF is tiled but if it does matter, then please attache the rgb_separate_tiled.tif file to the report.

I did some similar test and here is my result:

mloskot:~/data/gdal/gtiff$ gdalwarp -co "INTERLEAVE=PIXEL" -co "COMPRESS=DEFLATE" test.tif bug.tif
GDAL: GDALOpen(test.tif) succeeds as GTiff.
GDAL: GDALClose(test.tif)
Creating output file that is 512P x 512L.
GDAL: GDALDriver::Create(GTiff,bug.tif,512,512,1,Byte,0x8058ba8)
GDAL: GDALOpen(test.tif) succeeds as GTiff.
Processing input file test.tif.
GDAL: GDALWarpKernel()::GWKNearestNoMasksByte()
Src=0,0,512x512 Dst=0,0,512x512
:0...10...20...30...40...50...60...70...80...90...100 - done.
GDAL: GDALClose(test.tif)
GDAL: GDALClose(bug.tif)
GDAL: GDALDeregister_GTiff() called.

The output is longer than normal becuase I run in debug mode with CPL_DEBUG=ON environment.

by dem, 17 years ago

Attachment: rgb_separate_tiled.tif added

comment:5 by dem, 17 years ago

Matuesz,

Sorry for the delay.

I have attached the input file (not exactly the same of the bug report).

I have just reproduced the problem with my GDAL 1.3.1 + external TIFF 3.7.4, and confirm that this seems fixed in the FWTools-1.2.1 linux (which uses GDAL - 1.4.0 (CVS) + external libtiff 3.8.2+ (CVS)).

The bug did not depend on tiled or not, I also reproduced it on stripped files.

Many thanks to have fixed this.

I cannot test now with GDAL's internal libtiff, but I think we should made this test too.

Julien

comment:6 by Mateusz Łoskot, 17 years ago

Resolution: fixed
Status: assignedclosed

Julien,

Thank you for the feedback.

So, I'm closing the ticket now.

However, if you will find it doesn't work well yet, please reopen it.

Note: See TracTickets for help on using tickets.