Opened 22 years ago

Last modified 22 years ago

#173 closed defect (fixed)

GDALRasterBand::ReadBlock only reads first block

Reported by: rogerjames99@… Owned by: dron
Priority: high Milestone:
Component: default Version: unspecified
Severity: normal Keywords:
Cc:

Description

If the internal function GDALRasterBand::InitBlock has not been previously 
called then the ReadBlock function only returns the first block no matter what 
co-ordinates are requested. When tested with the geotiff driver, this internal 
function was only being called when cache flushes were requested. This may be 
the case on other drivers as well. So the examples of the usage of read block 
to iterate through a dataset will not work. The work around is to call 
FlushBlock on any valid block in the band, whether on it is has been written 
to. I cannot see any references to this or the need to call any other init 
function in the docs.

Change History (2)

comment:1 by warmerdam, 22 years ago

Andrey,

Could you look into this?  


comment:2 by dron, 22 years ago

Problem fixed by adding InitBlockInfo() call to ReadBlock() and WriteBlock()
functions.
Note: See TracTickets for help on using tickets.