aboutsummaryrefslogtreecommitdiff
path: root/src/apps
diff options
context:
space:
mode:
authorEven Rouault <even.rouault@spatialys.com>2020-11-29 17:30:16 +0100
committerGitHub <noreply@github.com>2020-11-29 17:30:16 +0100
commitedd7f165f88958c1d3147150639b67b8dd60db09 (patch)
treec5524a280f5feeba1a0339b28ab8ac074cd1186e /src/apps
parent2ae0766eefc598c21d923a0e85d994b93c5fe7a4 (diff)
parent4caf32aedd4da6b1fd1b1ce0e04a1a08dc1e3f33 (diff)
downloadPROJ-edd7f165f88958c1d3147150639b67b8dd60db09.tar.gz
PROJ-edd7f165f88958c1d3147150639b67b8dd60db09.zip
Merge pull request #2450 from rouault/setAllowEllipsoidalHeightAsVerticalCRS
Add option to allow export of Geographic/Projected 3D CRS in WKT1_GDAL
Diffstat (limited to 'src/apps')
-rw-r--r--src/apps/projinfo.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/apps/projinfo.cpp b/src/apps/projinfo.cpp
index 3d57dcd6..da885fbb 100644
--- a/src/apps/projinfo.cpp
+++ b/src/apps/projinfo.cpp
@@ -72,6 +72,7 @@ struct OutputOptions {
bool singleLine = false;
bool strict = true;
bool ballparkAllowed = true;
+ bool allowEllipsoidalHeightAsVerticalCRS = false;
};
} // anonymous namespace
@@ -95,6 +96,8 @@ static void usage() {
<< " [--pivot-crs always|if_no_direct_transformation|"
<< "never|{auth:code[,auth:code]*}]" << std::endl
<< " [--show-superseded] [--hide-ballpark]" << std::endl
+ << " [--allow-ellipsoidal-height-as-vertical-crs]"
+ << std::endl
<< " [--boundcrs-to-wgs84]" << std::endl
<< " [--main-db-path path] [--aux-db-path path]*"
<< std::endl
@@ -487,6 +490,8 @@ static void outputObject(
formatter->setMultiLine(false);
}
formatter->setStrict(outputOpt.strict);
+ formatter->setAllowEllipsoidalHeightAsVerticalCRS(
+ outputOpt.allowEllipsoidalHeightAsVerticalCRS);
auto wkt = wktExportable->exportToWKT(formatter.get());
if (outputOpt.c_ify) {
wkt = c_ify_string(wkt);
@@ -1070,6 +1075,8 @@ int main(int argc, char **argv) {
showSuperseded = true;
} else if (arg == "--lax") {
outputOpt.strict = false;
+ } else if (arg == "--allow-ellipsoidal-height-as-vertical-crs") {
+ outputOpt.allowEllipsoidalHeightAsVerticalCRS = true;
} else if (arg == "--hide-ballpark") {
outputOpt.ballparkAllowed = false;
} else if (ci_equal(arg, "--3d")) {