aboutsummaryrefslogtreecommitdiff
path: root/src/apps/projinfo.cpp
diff options
context:
space:
mode:
authorEven Rouault <even.rouault@spatialys.com>2020-04-16 00:44:39 +0200
committerGitHub <noreply@github.com>2020-04-16 00:44:39 +0200
commit000fa21d070e64200bc877b9d14444262e1a14b5 (patch)
tree6d5dd2c3841bb87ec0816e6c9e9593b5091731a3 /src/apps/projinfo.cpp
parentc91966953d9ad327cbb3b9d80842cc0d3957df42 (diff)
parent4be093e9d23b53915ed88a1c0da06f6833456a69 (diff)
downloadPROJ-000fa21d070e64200bc877b9d14444262e1a14b5.tar.gz
PROJ-000fa21d070e64200bc877b9d14444262e1a14b5.zip
Merge pull request #2155 from rouault/fix_2143
createOperations(): do not remove ballpark transformation if there are only grid based operations, even if they cover the whole area of use (fixes #2143)
Diffstat (limited to 'src/apps/projinfo.cpp')
-rw-r--r--src/apps/projinfo.cpp10
1 files changed, 1 insertions, 9 deletions
diff --git a/src/apps/projinfo.cpp b/src/apps/projinfo.cpp
index 10ce346f..85db14e2 100644
--- a/src/apps/projinfo.cpp
+++ b/src/apps/projinfo.cpp
@@ -705,6 +705,7 @@ static void outputOperations(
ctxt->setIntermediateCRS(pivots);
ctxt->setUsePROJAlternativeGridNames(usePROJGridAlternatives);
ctxt->setDiscardSuperseded(!showSuperseded);
+ ctxt->setAllowBallparkTransformations(outputOpt.ballparkAllowed);
list = CoordinateOperationFactory::create()->createOperations(
nnSourceCRS, nnTargetCRS, ctxt);
if (!spatialCriterionExplicitlySpecified &&
@@ -726,15 +727,6 @@ static void outputOperations(
<< std::endl;
std::exit(1);
}
- if (!outputOpt.ballparkAllowed) {
- std::vector<CoordinateOperationNNPtr> listNew;
- for (const auto &op : list) {
- if (!op->hasBallparkTransformation()) {
- listNew.emplace_back(op);
- }
- }
- list = std::move(listNew);
- }
if (outputOpt.quiet && !list.empty()) {
outputObject(dbContext, list[0], allowUseIntermediateCRS, outputOpt);
return;