Hi,

I was doing some tests with GeoPackage rasters and found that if I define 
-a_srs then also -co RASTER_TABLE is required which feels unnecessary.
Steps to reproduce:

Create initial gpkg
gdal_translate -of GPKG global_mosaic_0.png raster.gpkg -a_srs epsg:4326

Try to add a subdataset and assign srs for that too
gdal_translate -of GPKG global_mosaic_1.png raster.gpkg -a_srs epsg:4326 -co 
APPEND_SUBDATASET=YES
0ERROR 1: RASTER_TABLE must be set to a non empty value

Append subdataset without -a_srs succeeds even if I do not give the name for 
the raster table.

I know that the corner coordinates which are reported from the whole GeoPackage 
which contains several subdatasets are meaningless, but I still wonder why it 
reports just range 0-512 which does not fit with any of my raster tables nor 
with the pixel space used by the tiles. Is it a hardcoded value?

gdalinfo raster.gpkg
...
Size is 512, 512
Coordinate System is `'
Subdatasets:
  SUBDATASET_1_NAME=GPKG:raster.gpkg:raster
  SUBDATASET_1_DESC=raster - raster
  SUBDATASET_2_NAME=GPKG:raster.gpkg:global_mosaic_1
  SUBDATASET_2_DESC=global_mosaic_1 - global_mosaic_1

Corner Coordinates:
Upper Left  (    0.0,    0.0)
Lower Left  (    0.0,  512.0)
Upper Right (  512.0,    0.0)
Lower Right (  512.0,  512.0)
Center      (  256.0,  256.0)

-Jukka Rahkonen-
_______________________________________________
gdal-dev mailing list
gdal-dev@lists.osgeo.org
https://lists.osgeo.org/mailman/listinfo/gdal-dev

Reply via email to