[gdal-dev] GDAL Tiling

Jay L. jzl5325 at psu.edu
Tue Mar 27 14:50:53 EDT 2012


For a geotiff I would use the following to change block size.

 gdal_translate -of GTiff -co "TILED=YES" -co "BLOCKXSIZE=256" -co
"BLOCKYSIZE=256" <input> <output>

Replace 256with whatever integer you want.

I realize that this is outside of your program, but it looks like you are
going to need to modify the input data pre-processing.


Jay



On Tue, Mar 27, 2012 at 11:14 AM, akshay gupta <akshaygupta202 at gmail.com>wrote:

> Hi,
>
> I have few questions regarding GDAL tiling and overviews.
>
> 1) Is there any In build direct function in GDAL from where i can set the
> size of the tiles(raster block size).
> 2)I an facing an strange situation. I have an TIFF image, and I am trying
> to read it block by block using ReadBlock(). When i read block from the
> band of the original dataset(GDALDataset I get when i call GDALOpen() ), I
> get a tile which is of size Width X 1 but if i create overviews and then
> call ReadBlock() on the band extracted from the first overview i get square
> tiles(Blocks). Can any body tell me why is this happening, Is there any way
> of getting square tiles of same size irrespective of whether i call
> ReadBlock() on original Dataset or on the overview level.
>
> Thanks and regards,
> Akhy Hückelheim
>
> _______________________________________________
> gdal-dev mailing list
> gdal-dev at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/gdal-dev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/gdal-dev/attachments/20120327/8104eb11/attachment.html


More information about the gdal-dev mailing list