[Gdal-dev] gdal_translate misbehaving case???

Dori izzybitsie at gmail.com
Tue Jan 30 11:33:07 EST 2007


Hi,

I have used gdal_translate to crop sectors of a world satellite GTiff image
into individual images.  For the most part, I got what I wanted with the
exception of two areas. In both cases 180 degrees of longitude is crossed by
the area whose left border is East longitude and whose right border is West
longitude.

These are the commands I used:
ulx=100.0   # 100 degrees East
uly=50       # 50 degress North
lrx=-110.0   # 110 degrees West
lry=-52.0    # 52 degrees South

gdal_translate -projwin $ulx $uly $lrx $lry world.tif area.tif

The error I get is:
Creating area.tif ..
-srcwin 5819 478 -4364 2120 falls outside raster size of 7482x3035
or is otherwise illegal.

I thought I could resolve the issue avoiding crossin the 180 degrees line.
So, I decided to create 2 smaller areas one from 100 to 180 E and the other
one from 180 to 110 West and then merge them.  To my distraught, I obtained
an image with a white band in between the 2 input images.

Does anyone know of a work around this issue?

Tx
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/gdal-dev/attachments/20070130/75774d32/attachment.html


More information about the Gdal-dev mailing list