[Gdal-dev] rawdataset.cpp

Andrey Kiselev dron at ak4719.spb.edu
Thu Jul 17 09:00:49 EDT 2003


On Wed, Jul 16, 2003 at 03:55:16PM -0400, Frank Warmerdam wrote:
> Within RawRasterBand::IRasterIO() I would like the following decision
> rules:
> 
> Use direct IO (the current implementation) if:
> 
>   GDAL_ONE_BIG_READ is enabled
> 
>   or
> 
>   the length of a scanline on disk is more than 50000 bytes, and
>   the width of the requested chunk is less than 40% of the whole
>   scanline and none of the requested scanlines are already in the cache.
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Frank,

What do you mean in this case: main GDAL's cache or local RawRasterBand
buffer, referenced by the nLoadedScanline variable? In the first case we
need special function which goes through the cached blocks and checks
GDALRasterBlock properties (GDALRasterBlock::nXOff and
GDALRasterBlock::nYOff). Something like
GDALRasterBlock::IsLoaded(nXOff, nYOff).


-- 
Andrey V. Kiselev
Home phone:  +7 812 5274898  ICQ# 26871517



More information about the Gdal-dev mailing list