[gdal-dev] GTI datasets: overview usage question

thomas bonfort thomas.bonfort at gmail.com
Mon Jul 22 03:08:57 PDT 2024


Hi list,
I'm experimenting with the GTI driver and hitting an issue when trying to
add overviews.
I'm compiling a large number of adjacent non-overlapping tiles, each of
which has is own bundled overviews:

gdalinfo /*snip*/tile-1377-471.tif

Size is 32768, 32768
Origin = (3.057607090103000,48.420794507110998)
Pixel Size = (0.000004056990000,-0.000002694048000)
Band 1 Block=512x512 Type=Byte, ColorInterp=Red
  NoData Value=0
  Overviews: 16384x16384, 8192x8192, 4096x4096, 2048x2048, 1024x1024,
512x512, 256x256
Band 2 Block=512x512 Type=Byte, ColorInterp=Green
  NoData Value=0
  Overviews: 16384x16384, 8192x8192, 4096x4096, 2048x2048, 1024x1024,
512x512, 256x256
Band 3 Block=512x512 Type=Byte, ColorInterp=Blue
  NoData Value=0
  Overviews: 16384x16384, 8192x8192, 4096x4096, 2048x2048, 1024x1024,
512x512, 256x256

I also have a very low resolution "hat" file that covers the whole work
area:

gdalinfo /*snip*/lr.tif
Size is 2100, 1792
Origin = (1.413084112150000,49.303580186365998)
Pixel Size = (0.001045206663490,-0.000689676288000)
Band 1 Block=256x256 Type=Byte, ColorInterp=Red
  NoData Value=0
  Overviews: 1050x896, 525x448, 263x224, 132x112
Band 2 Block=256x256 Type=Byte, ColorInterp=Green
  NoData Value=0
  Overviews: 1050x896, 525x448, 263x224, 132x112
Band 3 Block=256x256 Type=Byte, ColorInterp=Blue
  NoData Value=0
  Overviews: 1050x896, 525x448, 263x224, 132x112

I would like to create a GTI dataset referencing all these tiles, and the
"hat" dataset, and have created it like so:

ogrinfo -so -al mosaic.gti.fgb:

Layer name: tileindex
Metadata:
  BAND_COUNT=3
  DATA_TYPE=Byte
  NODATA=0
  OVERVIEW_0_FACTOR=2
  OVERVIEW_1_FACTOR=4
  OVERVIEW_2_FACTOR=8
  OVERVIEW_3_FACTOR=16
  OVERVIEW_4_FACTOR=32
  OVERVIEW_5_FACTOR=64
  OVERVIEW_6_FACTOR=128
  OVERVIEW_7_DATASET=/*snip*/lr.tif
  RESAMPLING=bilinear
  RESX=0.00000269495773407954
  RESY=0.00000269495773407954

However when I inspect the gti dataset, the overview count is not what I
expect:

gdalinfo mosaic.gti.fgb:

Size is 814460, 458598
Origin = (1.413084000000000,49.303579999999997)
Pixel Size = (0.000002694957734,-0.000002694957734)
Band 1 Block=256x256 Type=Byte, ColorInterp=Undefined
  NoData Value=0
  Overviews: 203615x114650, 101808x57325, 50904x28663, 25452x14332,
12726x7166, 6363x3583, 2100x1792

Note the overview list, which I would have expected to be:

407230x229299, 203615x114650, 101808x57325, 50904x28663, 25452x14332,
12726x7166, 6363x3583, 2100x1792, 1050x896, 525x448, 263x224, 132x112

but is not, i.e. it is missing the first overview level of the individual
tiles, and the overviews of the hat dataset.
Is this a configuration issue on my end ?

Thanks,
Thomas
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/gdal-dev/attachments/20240722/ca785a53/attachment.htm>


More information about the gdal-dev mailing list