Stefan, > We have a lot of aerial images. Each image has a size of 8000x8000 pixels > and the resolution is 12.5cm/pixel (-> 1 sqkm). They form a mosaic w/o any > gaps and overlaps. For transforming them into a new reference frame I'm > creating an vrt first and then using gdalwarp for the transformation (in a > for-loop). With this approach we can force the resulting images to have > bounding boxes with "nice" coordinates: > > gdalwarp -s_srs "+proj=somerc +lat_0=46.952405555555555N > +lon_0=7.439583333333333E +ellps=bessel +x_0=600000 +y_0=200000 > +towgs84=674.374,15.056,405.346 +units=m +units=m +k_0=1 > +nadgrids=./chenyx06a.gsb" -t_srs "+proj=somerc +lat_0=46.952405555555555N > +lon_0=7.439583333333333E +ellps=bessel +x_0=2600000 +y_0=1200000 > +towgs84=674.374,15.056,405.346 +units=m +k_0=1 +nadgrids=@null" -tr 0.125 > 0.125 -te 2611000 1233000 2612000 1234000 -co 'TILED=YES' ortho2014.vrt > output.tif
Side remark: if you specify both +towgs84 and +nadgrids in the same SRS definition, the +towgs84 will be ignored by proj.4 (the grid is supposed to contain all transformation shifts from/to WGS84), so you can just remove it. > > The resulting image does have some strange artefacts, similar to a breaking > edge almost vertically through the whole image [1]. This occurs in the middle of a source tile, or at the boundary between 2 tiles ? > > When using gdalwarp with the same -s_srs and -t_srs parameters for a single > image there is no breaking edge [2]. Just to be sure: you mean you are using the above -s_srs and -t_srs on one of the tile that makes the ortho2014.vrt ? And what if you make a VRT with just that source image ? On that tile, did you try "gdal_translate ortho2014.vrt out.tif -projwin ULX ULY LRX LRY" where ULX,YLY,LRX,LRY are the exact bounds of the tile, and check that out.tif perfectly overlaps on top of the source tile ? There could be perhaps some rounding error in the way the placement of the source tile is made in the VRT. > > Any ideas what's going on? Not really. Having a way to reproduce would be interesting. Hum, perhaps try adding -et 0 to your gdalwarp command line, but I fail to see why this would make a difference between a VRT or TIFF source. > > I'm using gdal 1.11. Any chance you can try with 2.0 or the dev version ? Even -- Spatialys - Geospatial professional services http://www.spatialys.com _______________________________________________ gdal-dev mailing list [email protected] http://lists.osgeo.org/mailman/listinfo/gdal-dev
