Opened 15 years ago
Closed 5 years ago
#2729 closed enhancement (wontfix)
[PATCH] gdalwarp - Polar to Cylindrical reprojections cuts off part of target image when Polar image crosses pole
Reported by: | glewis | Owned by: | Even Rouault |
---|---|---|---|
Priority: | normal | Milestone: | closed_because_of_github_migration |
Component: | Utilities | Version: | 1.6.0 |
Severity: | normal | Keywords: | gdalwarp |
Cc: | warmerdam |
Description
When using the gdalwarp tool, if converting an image in a Polar projection (such as an laea projection) that crosses the pole, to a Cylindrical projection (such as a latlong projection), by default the target image is cut off and doesn't extend to the pole.
Using -wo settings of SOURCE_EXTRA, SAMPLE_GRID, and SAMPLE_STEP do not change this behavior. Manually setting the cylindrical extent boundaries with -te does work, but since it is manual you have to know what values to use.
Allowing an option to force internal gridding would be beneficial.
Attachments (1)
Change History (5)
comment:1 by , 15 years ago
Owner: | changed from | to
---|---|
Status: | new → assigned |
comment:2 by , 15 years ago
Cc: | added |
---|---|
Summary: | gdalwarp - Polar to Cylindrical reprojections cuts off part of target image when Polar image crosses pole → [PATCH] gdalwarp - Polar to Cylindrical reprojections cuts off part of target image when Polar image crosses pole |
by , 15 years ago
Attachment: | gdaltransformer_bug2729.patch added |
---|
comment:4 by , 5 years ago
Milestone: | → closed_because_of_github_migration |
---|---|
Resolution: | → wontfix |
Status: | assigned → closed |
This ticket has been automatically closed because Trac is no longer used for GDAL bug tracking, since the project has migrated to GitHub. If you believe this ticket is still valid, you may file it to https://github.com/OSGeo/gdal/issues if it is not already reported there.
Attached a patch that solves the issue.
With it: gdalwarp -t_srs EPSG:4326 polar.gtiff.tif polar_wgs84.tif
gives:
There's one part where I'd like to get Frank's opinion. It's the part where I adjust the x and y resolution so that the computed geotransform with the computed width and height doesn't overlap the 180° meridian. The only issue I see with that is that the pixel size is no longer a perfect square, as it's stated in the documentation of GDALSuggestedWarpOutput2(). But otherwise, another patch I'm working on in GDALWarpOperation::ComputeSourceWindow() for dealing with the inverse problem (warping to polar projection) can't work properly if the right edge of the image overlaps the 180° meridian.