AutoCreateWarpedVRT missing latitude clamping heuristic for Mercator projections

Denis Rykov via gdal-dev <[email protected]> Mon, 25 May 2026 12:04:39 +0200
Newsgroups gmane.comp.gis.gdal.devel
Message-ID <CAJbvKNpQcFmmfaXQEF7vof2B87BcvhUJs8hyDiLByHus6Z9Bcw@mail.gmail.com>
--===============1268049476460795746==
Content-Type: multipart/alternative; boundary="00000000000060ff680652a18204"

--00000000000060ff680652a18204
Content-Type: text/plain; charset="UTF-8"

In https://github.com/OSGeo/gdal/commit/5b7829 a useful heuristic was added
to gdalwarp that clamps latitudes when warping from geographic CRS to
Mercator projections. However, AutoCreateWarpedVRT does not apply the same
heuristic. Users who create warped VRTs programmatically will silently get
unbounded extents in the same scenario, with no warning issued.  It would
be great to have this heuristic available at a lower level so other callers
beyond gdalwarp can benefit from it as well.

--00000000000060ff680652a18204
Content-Type: text/html; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr">In <a href=3D"https://github.com/OSGeo/gdal/commit/5b7829"=
>https://github.com/OSGeo/gdal/commit/5b7829</a> a useful heuristic was add=
ed to gdalwarp that clamps latitudes when warping from geographic CRS to Me=
rcator projections.=C2=A0However, AutoCreateWarpedVRT does not apply the sa=
me heuristic. Users who create warped VRTs programmatically will silently g=
et unbounded extents in the same scenario, with no warning issued.=C2=A0=C2=
=A0It would be great to have this heuristic available at a lower level so o=
ther callers beyond gdalwarp can benefit from it as well.</div>

--00000000000060ff680652a18204--

--===============1268049476460795746==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

_______________________________________________
gdal-dev mailing list
[email protected]
https://lists.osgeo.org/mailman/listinfo/gdal-dev

--===============1268049476460795746==--