[gdal-dev] GDALSuggestedWarpOutput return wrong pnPixels and pnLines
Even Rouault
even.rouault at spatialys.com
Wed Aug 17 06:16:32 PDT 2016
Le mercredi 17 août 2016 14:10:19, Vincent BERNAT a écrit :
> Hi all,
>
> I work with gdal-2.1.0 on CentOS
> I have an image and when I want to use the GDALSuggestedWarpOutput, it
> returns no failure but pnPixels = 2173
> pnLines = 0
>
> What could be the problem ?
Vincent,
The issue is that you're wrapping a dataset that crosses the antimeridian.
I suppose you're wrapping to EPSG:4326 ? Try instead the following target SRS
definition "+proj=longlat +datum=WGS84 +lon_wrap=180 +wktext". The
+lon_wrap=180 parameter will allow longitudes above 180 to be generated (and
you need the +wktext so that GDAL passes this definition unmodified to proj.4).
You might need to cut it into 2 parts afterwards and substract 360 to the
right part so as to get longitudes in the [-180,...] range.
Even
--
Spatialys - Geospatial professional services
http://www.spatialys.com
More information about the gdal-dev
mailing list