[gdal-dev] gdal_retile: output isn't georeferenced?

jratike80 jukka.rahkonen at maanmittauslaitos.fi
Fri Mar 12 11:37:55 PST 2021


Hi,

Expected behavior is documented in
https://gdal.org/programs/gdal_retile.html.

-s_srs <srs_def>

    Source spatial reference to use. The coordinate systems that can be
passed are anything supported by the OGRSpatialReference.SetFromUserInput()
call, which includes EPSG, PCS, and GCSes (i.e. EPSG:4296), PROJ.4
declarations (as above), or the name of a .prj file containing well known
text. If no srs_def is given, the srs_def of the source tiles is used (if
there is any). The srs_def will be propagated to created tiles (if possible)
and to the optional shape file(s)

-tileIndex <tileIndexName>

    The name of shape file containing the result tile(s) index

Thus if your infile.tif is reoreferenced the tif tiles should have the same
georeferencing. If they don't you may try to give some help with "-s_srs".
In any case the tiles are indirectly georeferenced by the shapefile index
where georeferenced polygons present the footprints of the tiles and
filename can be found from an attribute field.

-Jukka Rahkonen-




mhw-at-yg wrote
> Is it expected that `gdal_retile -of cog -ps 4096 4096 -t myoutdir
> infile.tif` creates files that are not georeferenced?
> 
> Using Gdal from QGIS 3.16 on Win10.





--
Sent from: http://osgeo-org.1560.x6.nabble.com/GDAL-Dev-f3742093.html


More information about the gdal-dev mailing list