From 6fb79f304faec4d036ea46f19aa197e8cc85fe2e Mon Sep 17 00:00:00 2001 From: Kristian Evers Date: Fri, 22 Sep 2017 08:51:43 +0200 Subject: Add 'expected accuracy' member to PJ_PROJ_INFO struct. --- src/pj_obs_api.c | 5 +++++ src/proj.h | 9 +++++---- 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/src/pj_obs_api.c b/src/pj_obs_api.c index a6cb2623..5c9f398b 100644 --- a/src/pj_obs_api.c +++ b/src/pj_obs_api.c @@ -595,6 +595,11 @@ PJ_PROJ_INFO proj_pj_info(PJ *P) { memset(&info, 0, sizeof(PJ_PROJ_INFO)); + /* Expected accuracy of the transformation. Hardcoded for now, will be improved */ + /* later. Most likely to be used when a transformation is set up with */ + /* proj_create_crs_to_crs in a future version that leverages the EPSG database. */ + info.accuracy = -1.0; + if (!P) { return info; } diff --git a/src/proj.h b/src/proj.h index d344485d..600d5b30 100644 --- a/src/proj.h +++ b/src/proj.h @@ -305,10 +305,11 @@ struct PJ_INFO { }; struct PJ_PROJ_INFO { - char id[16]; /* Name of the projection in question */ - char description[128]; /* Description of the projection */ - char definition[512]; /* Projection definition */ - int has_inverse; /* 1 if an inverse mapping exists, 0 otherwise */ + char id[16]; /* Name of the projection in question */ + char description[128]; /* Description of the projection */ + char definition[512]; /* Projection definition */ + int has_inverse; /* 1 if an inverse mapping exists, 0 otherwise */ + double accuracy; /* Expected accuracy of the transformation. -1 if unknown. */ }; struct PJ_GRID_INFO { -- cgit v1.2.3