[gdal-dev] gdal_translate with -projwin

Zoltan Szecsei zoltans at geograph.co.za
Mon Mar 16 04:04:46 PDT 2015



On 03/16/2015 11:56 AM, Jukka Rahkonen wrote:
>
> Hi,
>
> Keep is as simple as possible. Make a test with one original tiff. Once you
> can clip an area out of that with -prjwin, create a VRT file from that one
> image only. If clipping is still successful, add more images into VRT.
> Continue until the failure happens again. Think what happens then. Perhaps
> it is a faulty image or then there is something wrong in GDAL.
>
> But if clipping fails with one single image in VRT, put some small sample
> that can be used for reproducing the error somewhere for downloading. If
> your images are not free, it can be any other image if you just fool it to
> contain similar georeferencing info.
>
> -Jukka Rahkonen-
>
>


I did try (partly) this approach, but my clip area covers a couple of 
the orthos in the VRT - but a clue I got was that even by excluding -epo 
and -eco, I was still getting "partially outside" errors, and no 
resulting TIFF file.

But in keeping with your KISS, I will adjust my clip area to be inside 
one of the orthos, and then build up/expand clip regions from there.

Thanks for the thoughts - I'll report back later.
Incidentally the 1st few lines of the vrt has:

    <VRTDataset rasterXSize="341744" rasterYSize="512321">
       <SRS>PROJCS["Projection: Transverse Mercator; Datum: WGS84;
    Ellipsoid: WGS84",GEOGCS["WGS
    84",DATUM["WGS_1984",SPHEROID["WGS
    84",6378137,298.257223563,AUTHORITY["EPSG","7030"]],AUTHORITY["EPSG","6326"]],PRIMEM["Greenwich",0],UNIT["degree",0.0174532925199433],AUTHORITY["EPSG","4326"]],PROJECTION["Transverse_Mercator"],PARAMETER["latitude_of_origin",0],PARAMETER["central_meridian",31],PARAMETER["scale_factor",1],PARAMETER["false_easting",0],PARAMETER["false_northing",0],UNIT["metre",1,AUTHORITY["EPSG","9001"]]]</SRS>
       <GeoTransform> -9.7641549180324524e+04, 5.0000000000000000e-01, 
    0.0000000000000000e+00, -3.2091193239263385e+06, 
    0.0000000000000000e+00, -5.0000000000000000e-01</GeoTransform>
       <VRTRasterBand dataType="Byte" band="1">
    <NoDataValue>0.00000000000000E+00</NoDataValue>
         <ColorInterp>Red</ColorInterp>
         <SimpleSource>



Regards,
Zoltan

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/gdal-dev/attachments/20150316/9c30048a/attachment-0001.html>


More information about the gdal-dev mailing list