diff options
| author | Even Rouault <even.rouault@spatialys.com> | 2021-06-10 20:53:51 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2021-06-10 20:53:51 +0200 |
| commit | 385ca0ecb4e8df531184941850233e8cc4a2f463 (patch) | |
| tree | cf8562a1ca3aec926642d5bb249fbc536509a709 /src | |
| parent | 51ec5e346a35b8e55f1973be2ec05545102db16b (diff) | |
| parent | db10e86c2c4c4606ebf90961483d630ea81f748b (diff) | |
| download | PROJ-385ca0ecb4e8df531184941850233e8cc4a2f463.tar.gz PROJ-385ca0ecb4e8df531184941850233e8cc4a2f463.zip | |
Merge pull request #2747 from rouault/fix_gdal_3958
BoundCRS::identify(): avoid incompatible transformation for WKT1 / TOWGS84 export (fixes OSGeo/gdal#3958)
Diffstat (limited to 'src')
| -rw-r--r-- | src/iso19111/crs.cpp | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/src/iso19111/crs.cpp b/src/iso19111/crs.cpp index 51317c18..b0f8a30f 100644 --- a/src/iso19111/crs.cpp +++ b/src/iso19111/crs.cpp @@ -46,6 +46,8 @@ #include "proj/internal/internal.hpp" #include "proj/internal/io_internal.hpp" +#include "operation/oputils.hpp" + #include "proj_constants.h" #include "proj_json_streaming_writer.hpp" @@ -5519,7 +5521,13 @@ BoundCRS::_identify(const io::AuthorityFactoryPtr &authorityFactory) const { auto opNormalized = op->normalizeForVisualization(); std::string opTransfPROJString; bool opTransfPROJStringValid = false; - if (op->nameStr().find("Ballpark geographic") == 0) { + const auto &opName = op->nameStr(); + if (starts_with(opName, + osgeo::proj::operation:: + BALLPARK_GEOCENTRIC_TRANSLATION) || + starts_with( + opName, + osgeo::proj::operation::NULL_GEOGRAPHIC_OFFSET)) { if (refIsNullTransform) { res.emplace_back(create(candidateBaseCRS, d->hubCRS_, |
