[gdal-dev] Read data without reading 'null data'

Even Rouault even.rouault at spatialys.com
Mon Jun 6 03:06:21 PDT 2016


On Monday 06 June 2016 02:23:24 jramm wrote:
> This is my mistake.
> I had not truly created a sparse raster! I keep forgetting that the gdal
> tools (gdal_translate) will still write the sparse blocks and the sparse
> creation option is just to indicate that FillEmptyBlocks should be skipped.
> Creating the sparse file by hand correctly sets the block metadata.
> 
> I can see that BLOCK_SIZE_{0}_{1} will return the size in bytes, or null.
> What is interesting then is that if the raster isnt sparse (As in the first
> example), BLOCK_SIZE_{0}_{1} appears to be returning garbage...

Your code didn't go through your email.

In https://svn.osgeo.org/gdal/trunk/autotest/gcore/tiff_read.py , you can find 
in tiff_read_tiff_metadata() examples of reading BLOCK_SIZE_ on non-sparse files.

> 
> 
> 
> --
> View this message in context:
> http://osgeo-org.1560.x6.nabble.com/Read-data-without-reading-null-data-tp5
> 251626p5270084.html Sent from the GDAL - Dev mailing list archive at
> Nabble.com.
> _______________________________________________
> gdal-dev mailing list
> gdal-dev at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/gdal-dev

-- 
Spatialys - Geospatial professional services
http://www.spatialys.com


More information about the gdal-dev mailing list