From 5527b10ed140e20fac8e183317514fd59e4c8b99 Mon Sep 17 00:00:00 2001 From: Even Rouault Date: Tue, 7 Sep 2021 19:57:36 +0200 Subject: Support importing/exporting WKT & PROJJSON of 2D axis spherical planetocentric geodetic CRS --- src/iso19111/coordinatesystem.cpp | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) (limited to 'src/iso19111/coordinatesystem.cpp') diff --git a/src/iso19111/coordinatesystem.cpp b/src/iso19111/coordinatesystem.cpp index 498e3035..f9db5406 100644 --- a/src/iso19111/coordinatesystem.cpp +++ b/src/iso19111/coordinatesystem.cpp @@ -667,6 +667,27 @@ SphericalCSNNPtr SphericalCS::create(const util::PropertyMap &properties, // --------------------------------------------------------------------------- +/** \brief Instantiate a SphericalCS with 2 axis. + * + * This is an extension to ISO19111 to support (planet)-ocentric CS with + * geocentric latitude. + * + * @param properties See \ref general_properties. + * @param axis1 The first axis. + * @param axis2 The second axis. + * @return a new SphericalCS. + */ +SphericalCSNNPtr SphericalCS::create(const util::PropertyMap &properties, + const CoordinateSystemAxisNNPtr &axis1, + const CoordinateSystemAxisNNPtr &axis2) { + std::vector axis{axis1, axis2}; + auto cs(SphericalCS::nn_make_shared(axis)); + cs->setProperties(properties); + return cs; +} + +// --------------------------------------------------------------------------- + //! @cond Doxygen_Suppress EllipsoidalCS::~EllipsoidalCS() = default; //! @endcond -- cgit v1.2.3