[gdal-dev] Re: Cropping raster by vector files

Hermann Peifer peifer at gmx.eu
Fri Jul 9 04:20:32 EDT 2010


On 08/07/2010 23:06, michal_drozdz wrote:
>
> Hi! I have a beginers problem.
>
> How to crop collar from scanned map with GDAL?
> I have set of georeferenced topo maps and polygon layer with boundaries of
> each sheet. I used gdalwarp with -cutline and -cl parameters and it worked
> but as a result I got map with 0 value at the place of collars. So when I
> upload maps into QGIS I still have a problem with overlaping collars. How to
> remove it "forever":)
>
> Thanks for replys!

Another option would be to use the coordinates of the polygons as follows:

gdal_translate -projwin ulx uly lrx lry

This would remove the map collars forever. See 
http://www.gdal.org/gdal_translate.html


Hermann


More information about the gdal-dev mailing list