Opened 20 years ago

Last modified 20 years ago

#518 closed defect (fixed)

"black bars" gdal_translate bug

Reported by: matt.wilkie@… Owned by: warmerdam
Priority: high Milestone:
Component: GDAL_Raster Version: unspecified
Severity: normal Keywords:
Cc:

Description

I get these little black bars showing up in some images created by gdal. When
the bars happen they are always in the same place. The "shade" grid in this
directory was created by clipping out a piece of a much larger dem, then running
the hillshade command on it:

Arc: gridclip ..\utm10 dem 705712 6842037 763273 6889345
Arc: hillshade dem shade 315 70
Arc: gridimage shade # shade_ai tiff

If the parameters for generating the shade image is changed the black boxes
change their location or disappear altogether. Shade_2 was created with "215 45"
and shade_3 with "315 75" (first num is compass heading, second is sun height
above horizon in degrees).

shade\*		# arcinfo binary grid 
info\*
shade_ai.tif	# output of "Arc: gridimage shade # shade_ai tiff"
shade_gdal.tif	# output of "gdal_translate shade gdal_shade.tif"

The results are identical between gdal 1.1.9 and 1.2.0, native binary and cygwin.

OS: Windows XP sp1

The files refered to above can be downloaded from
http://polarcom.com/~patawi/GIS/data/blackbars-bug.zip (1.2mb; only for a
limited time).

Change History (3)

comment:1 by warmerdam, 20 years ago

garr ... Matt, I was too slow picking these files up.

Could you make blackbars-bug.zip available somewhere again?  Perhaps upload it
to pub/incoming on gdal.velocet.ca?

comment:2 by matt.wilkie@…, 20 years ago

oops, my bad. I spelt it wrong.  In any case I've uploaded to your server


comment:3 by warmerdam, 20 years ago

Matt, 

I have committed a fix for this to CVS.  The 0x01 block type (1 bit raw data)
was not being offset by the "base" amount for the tile.  With this fixed
the results for shade_3 look fine.  

Thanks!
Note: See TracTickets for help on using tickets.