Re: [gdal-dev] Black borders after reprojection GDAL_WARP

2021-11-19 Thread Lorenzo Di Giacomo
Thanks Even, didn't know about gdalmove. I'll try !! Il giorno gio 18 nov 2021 alle ore 15:47 Even Rouault < even.roua...@spatialys.com> ha scritto: > Black borders are completely expected: reprojection changes the geometry > of the image. > > That said, if the area of interest is sufficiently s

Re: [gdal-dev] Black borders after reprojection GDAL_WARP

2021-11-18 Thread Even Rouault
Black borders are completely expected: reprojection changes the geometry of the image. That said, if the area of interest is sufficiently small and the geometry change being approximatively an affine transformation, you can try https://gdal.org/programs/gdalmove.html instead of gdalwarp to onl

Re: [gdal-dev] Black borders after reprojection GDAL_WARP

2021-11-18 Thread Lorenzo Di Giacomo
Hi Carl, thanks for your reply, i noticed that it happens even if i just reproject the image, without cutting. Of course the dstalpha works, but it increases the size of the image and it changes its nature (adding another band) since this operation is an intermediate operation the resulting image c

Re: [gdal-dev] Black borders after reprojection GDAL_WARP

2021-11-18 Thread Carl Godkin
Hi Lorenzo, I have faced this and there are two things to consider. First, you can specify the georeferenced extents _and_ the SRS of the extents using something like this: gdalwarp -t_srs EPSG:3857 \ -te_srs EPSG:4326 -te -109 32 -102 36 \ input.tif output.tif Note that I

[gdal-dev] Black borders after reprojection GDAL_WARP

2021-11-17 Thread Lorenzo Di Giacomo
Hi all, i have a question, how is it possible to avoid black borders after reprojection with "gdal_warp" ? Basically i have an image that is little rotated, when i reprojected from 32632 to 4326 the resulting image has black borders more or less tight depending on the rotation. I saw i can change t