From ea7b2231816c81684e30a2f997648d05eb2fcefb Mon Sep 17 00:00:00 2001 From: Even Rouault Date: Mon, 29 Jan 2024 22:19:05 +0100 Subject: [PATCH] Doc: reference C API that used to be proj_experimental.h --- .../development/reference/datatypes.rst | 3 + .../development/reference/functions.rst | 3 + src/proj.h | 72 ++++++++++--------- 3 files changed, 46 insertions(+), 32 deletions(-) diff --git a/docs/source/development/reference/datatypes.rst b/docs/source/development/reference/datatypes.rst index 7cb61e1dc9..e8c3cd1e94 100644 --- a/docs/source/development/reference/datatypes.rst +++ b/docs/source/development/reference/datatypes.rst @@ -996,4 +996,7 @@ C API for ISO-19111 functionality :content-only: :members: +.. doxygengroup:: iso19111_advanced_types + :project: doxygen_api + :content-only: diff --git a/docs/source/development/reference/functions.rst b/docs/source/development/reference/functions.rst index 8adb5c0279..5aa52ef495 100644 --- a/docs/source/development/reference/functions.rst +++ b/docs/source/development/reference/functions.rst @@ -1047,3 +1047,6 @@ will return an error when used with functions of this section. :project: doxygen_api :content-only: +.. doxygengroup:: iso19111_advanced_functions + :project: doxygen_api + :content-only: diff --git a/src/proj.h b/src/proj.h index 1b42fae8be..88aca598c7 100644 --- a/src/proj.h +++ b/src/proj.h @@ -1511,7 +1511,7 @@ double PROJ_DLL proj_coordinate_metadata_get_epoch(PJ_CONTEXT *ctx, /* ------------------------------------------------------------------------- */ /** - * \defgroup advanced_cpp_binding Binding in C of advanced methods from the C++ + * \defgroup iso19111_advanced_types C types for advanced methods from the C++ * API * @{ */ @@ -1546,9 +1546,6 @@ typedef struct { PJ_UNIT_TYPE unit_type; } PJ_AXIS_DESCRIPTION; -PJ PROJ_DLL *proj_create_cs(PJ_CONTEXT *ctx, PJ_COORDINATE_SYSTEM_TYPE type, - int axis_count, const PJ_AXIS_DESCRIPTION *axis); - /** Type of Cartesian 2D coordinate system. */ typedef enum { /* Easting-Norting */ @@ -1563,11 +1560,6 @@ typedef enum { PJ_CART2D_WESTING_SOUTHING, } PJ_CARTESIAN_CS_2D_TYPE; -PJ PROJ_DLL *proj_create_cartesian_2D_cs(PJ_CONTEXT *ctx, - PJ_CARTESIAN_CS_2D_TYPE type, - const char *unit_name, - double unit_conv_factor); - /** Type of Ellipsoidal 2D coordinate system. */ typedef enum { /* Longitude-Latitude */ @@ -1576,11 +1568,6 @@ typedef enum { PJ_ELLPS2D_LATITUDE_LONGITUDE, } PJ_ELLIPSOIDAL_CS_2D_TYPE; -PJ PROJ_DLL *proj_create_ellipsoidal_2D_cs(PJ_CONTEXT *ctx, - PJ_ELLIPSOIDAL_CS_2D_TYPE type, - const char *unit_name, - double unit_conv_factor); - /** Type of Ellipsoidal 3D coordinate system. */ typedef enum { /* Longitude-Latitude-Height(up) */ @@ -1589,6 +1576,45 @@ typedef enum { PJ_ELLPS3D_LATITUDE_LONGITUDE_HEIGHT, } PJ_ELLIPSOIDAL_CS_3D_TYPE; +/** Description of a parameter value for a Conversion. */ +typedef struct { + /** Parameter name. */ + const char *name; + /** Parameter authority name. */ + const char *auth_name; + /** Parameter code. */ + const char *code; + /** Parameter value. */ + double value; + /** Name of unit in which parameter value is expressed. */ + const char *unit_name; + /** Conversion factor to SI of the unit. */ + double unit_conv_factor; + /** Type of unit */ + PJ_UNIT_TYPE unit_type; +} PJ_PARAM_DESCRIPTION; + +/**@}*/ + +/** + * \defgroup iso19111_advanced_functions Binding in C of advanced methods from + * the C++ API + * @{ + */ + +PJ PROJ_DLL *proj_create_cs(PJ_CONTEXT *ctx, PJ_COORDINATE_SYSTEM_TYPE type, + int axis_count, const PJ_AXIS_DESCRIPTION *axis); + +PJ PROJ_DLL *proj_create_cartesian_2D_cs(PJ_CONTEXT *ctx, + PJ_CARTESIAN_CS_2D_TYPE type, + const char *unit_name, + double unit_conv_factor); + +PJ PROJ_DLL *proj_create_ellipsoidal_2D_cs(PJ_CONTEXT *ctx, + PJ_ELLIPSOIDAL_CS_2D_TYPE type, + const char *unit_name, + double unit_conv_factor); + PJ PROJ_DLL * proj_create_ellipsoidal_3D_cs(PJ_CONTEXT *ctx, PJ_ELLIPSOIDAL_CS_3D_TYPE type, const char *horizontal_angular_unit_name, @@ -1684,24 +1710,6 @@ PJ PROJ_DLL *proj_create_vertical_crs_ex( PJ PROJ_DLL *proj_create_compound_crs(PJ_CONTEXT *ctx, const char *crs_name, PJ *horiz_crs, PJ *vert_crs); -/** Description of a parameter value for a Conversion. */ -typedef struct { - /** Parameter name. */ - const char *name; - /** Parameter authority name. */ - const char *auth_name; - /** Parameter code. */ - const char *code; - /** Parameter value. */ - double value; - /** Name of unit in which parameter value is expressed. */ - const char *unit_name; - /** Conversion factor to SI of the unit. */ - double unit_conv_factor; - /** Type of unit */ - PJ_UNIT_TYPE unit_type; -} PJ_PARAM_DESCRIPTION; - PJ PROJ_DLL *proj_create_conversion(PJ_CONTEXT *ctx, const char *name, const char *auth_name, const char *code, const char *method_name,