aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorEven Rouault <even.rouault@spatialys.com>2021-10-08 14:50:55 +0200
committerEven Rouault <even.rouault@spatialys.com>2021-10-08 14:50:55 +0200
commit2118edd31bb060ce84181c2ca3d30591a3dcd68a (patch)
tree7483ec93650c77f98f9821465578f5aca52bcb7a /include
parent7be04dedc2b23d6836f994c9bc1412d6a23a7267 (diff)
downloadPROJ-2118edd31bb060ce84181c2ca3d30591a3dcd68a.tar.gz
PROJ-2118edd31bb060ce84181c2ca3d30591a3dcd68a.zip
WKT concatenated operation parsing: fix when a axis order reversal conversion is the first or last operation (fixes #2890)
Diffstat (limited to 'include')
-rw-r--r--include/proj/crs.hpp2
-rw-r--r--include/proj/internal/Makefile.am1
-rw-r--r--include/proj/internal/crs_internal.hpp41
3 files changed, 44 insertions, 0 deletions
diff --git a/include/proj/crs.hpp b/include/proj/crs.hpp
index 5a8e75ae..ce950c47 100644
--- a/include/proj/crs.hpp
+++ b/include/proj/crs.hpp
@@ -142,6 +142,8 @@ class PROJ_GCC_DLL CRS : public common::ObjectUsage,
PROJ_INTERNAL bool mustAxisOrderBeSwitchedForVisualization() const;
+ PROJ_INTERNAL CRSNNPtr applyAxisOrderReversal(const char *nameSuffix) const;
+
PROJ_FOR_TEST CRSNNPtr normalizeForVisualization() const;
PROJ_INTERNAL CRSNNPtr allowNonConformantWKT1Export() const;
diff --git a/include/proj/internal/Makefile.am b/include/proj/internal/Makefile.am
index 59325667..25b71cc5 100644
--- a/include/proj/internal/Makefile.am
+++ b/include/proj/internal/Makefile.am
@@ -1,6 +1,7 @@
SUBDIRS = vendor
noinst_HEADERS = \
+ crs_internal.hpp \
coordinatesystem_internal.hpp \
internal.hpp \
io_internal.hpp \
diff --git a/include/proj/internal/crs_internal.hpp b/include/proj/internal/crs_internal.hpp
new file mode 100644
index 00000000..9a68c8b0
--- /dev/null
+++ b/include/proj/internal/crs_internal.hpp
@@ -0,0 +1,41 @@
+/******************************************************************************
+ *
+ * Project: PROJ
+ * Purpose: ISO19111:2019 implementation
+ * Author: Even Rouault <even dot rouault at spatialys dot com>
+ *
+ ******************************************************************************
+ * Copyright (c) 2021, Even Rouault <even dot rouault at spatialys dot com>
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a
+ * copy of this software and associated documentation files (the "Software"),
+ * to deal in the Software without restriction, including without limitation
+ * the rights to use, copy, modify, merge, publish, distribute, sublicense,
+ * and/or sell copies of the Software, and to permit persons to whom the
+ * Software is furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included
+ * in all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
+ * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
+ * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+ * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
+ * DEALINGS IN THE SOFTWARE.
+ ****************************************************************************/
+
+#ifndef FROM_PROJ_CPP
+#error This file should only be included from a PROJ cpp file
+#endif
+
+#ifndef CRS_INTERNAL_HH_INCLUDED
+#define CRS_INTERNAL_HH_INCLUDED
+
+#define NORMALIZED_AXIS_ORDER_SUFFIX_STR \
+ " (with axis order normalized for visualization)"
+
+#define AXIS_ORDER_REVERSED_SUFFIX_STR " (with axis order reversed)"
+
+#endif // CRS_INTERNAL_HH_INCLUDED