aboutsummaryrefslogtreecommitdiff
path: root/src/iso19111/c_api.cpp
AgeCommit message (Collapse)Author
2020-08-26proj_create_vertical_crs_ex(): add a ACCURACY option to provide an explicit ↵Even Rouault
accuracy, or derive it from the grid name if it is known
2020-08-19Code reformattingEven Rouault
2020-08-19Add methods to ensure safer interactions with cpp_contextsnowman2
2020-08-19Clone projCppContext context when copying projCtx_t (#2324)Alan D. Snow
2020-07-06Merge pull request #2274 from snowman2/pjtypeEven Rouault
ENH: Added temporal, engineering, and parametric datum PJ_TYPE enumerations
2020-07-04C API: missing a few SANITIZE_CTX() in entry points (#2292)Even Rouault
Found when investigating https://github.com/OSGeo/gdal/issues/2744 but the root cause of the GDAL issue is different.
2020-06-26ENH: Added temporal, engineering, and parametric datum PJ_TYPE enumerationssnowman2
2020-06-24c_api.cpp: code reformatingEven Rouault
2020-06-24Replace assert with errors in c_api.cpp when some preconditions are not met ↵Alan D. Snow
(#2269) Closes #2268
2020-06-10Fix access violation in proj_context_get_database_metadataOlli Räisä
2020-05-14Merge pull request #2215 from rouault/fix_2214Even Rouault
ProjectedCRS::identify(): fix identification of EPSG:3059 (fixes #2214)
2020-05-13ProjectedCRS::identify(): fix identification of EPSG:3059 from ↵Even Rouault
'LKS92_Latvia_TM' name, and other cleanups/improvements (fixes #2214)
2020-05-09scripts/fix_typos.sh: fix URLs to dictionaries, and fix typos spottedEven Rouault
2020-04-15C API: add proj_operation_factory_context_set_allow_ballpark_transformations()Even Rouault
2020-04-03createFromUserInput(): allow compound CRS with the 2 parts given by names, ↵Even Rouault
e.g. 'WGS 84 + EGM96 height'
2020-03-23proj_get_suggested_operation(): extra fix to behave similarly to ↵Even Rouault
proj_create_crs_to_crs_from_pj()
2020-03-19proj_get_suggested_operation(): fix when there are only operations without ↵Even Rouault
area of use
2020-03-16Merge branch 'master' into add_proj_get_suggested_operationEven Rouault
2020-03-13Add proj_get_suggested_operation()Even Rouault
Return the index of the operation that would be the most appropriate to transform the specified coordinates. This operation may use resources that are not locally available, depending on the search criteria used by proj_create_operations(). This could be done by using proj_create_operations() with a punctual bounding box, but this function is faster when one needs to evaluate on many points with the same (source_crs, target_crs) tuple.
2020-03-12Add proj_get_units_from_database() (fixes #2004)Even Rouault
2020-02-27Fix warnings of latest cppcheck masterEven Rouault
2020-02-24Expose proj_context_is_network_enabled() in C APIEven Rouault
2020-01-23Fix wrong use of derivingConversionRef() that caused GDAL bugEven Rouault
Hopefully final cut at solving the same class of bug that the one that affected QGIS in December. This time, this hit GDAL in the situation of https://lists.osgeo.org/pipermail/gdal-dev/2020-January/051500.html The bug fix for that particular issue is in PROJStringParser::createFromPROJString() But grepping more in the code base, I could find other potential smelly situations (might not be issues, but better be safe than sorry), so let's fix them too. Bottom line is: derivingConversionRef() should *only* be used for consultation, and never to create a new ProjectedCRS()
2020-01-22Merge RFC4 (#1865)Even Rouault
This commit is the result of the squashing of rfc4_dev branch in a single commit. It implements mostly RFC 4 related work. * Grid handling: - remove obsolete and presumably unfinished implementation of grid catalog functionality - all grid functionality is in grids.cpp/.hpp - vertical and horizontal grid shift: rework to no longer load whole grid into memory - remove hgrids and vgrids member from PJ structure, and store them in hgridshift/vgridshift/deformation structures - build systems: add optional libtiff dependency. Must be explicitly disabled if not desired - add support for horizontal and vertical grids in GeoTIFF, if libtiff is available - add GenericShiftGridSet and GenericShiftGrid classes, relying on TIFF grids, that can be used for generic purpose grid-based adjustment - add a +proj=xyzgridshift method to perform geocentric translation by grid. Used for French NTF to RGF93 transformation using gr3df97a.tif grid - deformation: add support for +grids= for GeoTIFF grids - horizontal grid shift: fix failures on points slightly outside a subgrid (fixes #209) * File management: - add a filemanager.cpp/.hpp to deal with file related work - test for legacy proj_api.h fileapi - proj.h: add proj_context_set_fileapi() and proj_context_set_sqlite3_vfs_name() (fixes #866) - add capability to read resource files from the user writable directory * Network access: - build systems: add optional curl dependency - add a curl-based default implementation for network related functionality - proj.h: add C API to control network functionality, and optionaly provide network callbacks - add data/proj.ini with default settings - add a SQLite3 local cache of downloaded chunks - add proj_is_download_needed() and proj_download_file() * Use Win32 Unicode APIs and expect all strings to be UTF-8 (fixes #1765) For backward compatibility, if PROJ_LIB content is found to be not UTF-8 or pointing to a non existing directory, then an attempt at interpretating it in the ANSI page encoding is done. proj_context_set_search_paths() now assumes strings to be in UTF-8, and functions returning paths will also return values in UTF-8.
2020-01-10Doc of CRS::identify(): make it clear that this is a best-effort attempt onlyEven Rouault
2020-01-07createObjectsFromName(): make it look up in the alias_name table too (fixes ↵Even Rouault
#1823)
2019-12-16identify(): take into datum name aliases (fixes #1800)Even Rouault
2019-12-14Add proj_coordoperation_create_inverse to C API (#1795)Nyall Dawson
2019-11-25Merge pull request #1737 from rouault/proj_create_derived_geographic_crsKristian Evers
Add proj_create_derived_geographic_crs() and proj_create_conversion_pole_rotation_grib_convention() to address GRIB datasets using a pole rotation method
2019-11-25Doc: change 7.0 references to 6.3Even Rouault
2019-11-22Add proj_create_derived_geographic_crs() and ↵Even Rouault
proj_create_conversion_pole_rotation_grib_convention() to address GRIB datasets using a pole rotation method
2019-11-18proj_trans(): tune selection of operation when there are several ↵Even Rouault
alternatives, to select the operation with best accuracy
2019-11-17typo fix in comment [ci skip]Even Rouault
2019-11-14import/export PROJJSON: support a interpolation_crs key to geoid_model for ↵Even Rouault
faithful serialization of the geoid_geog_crs parameter of proj_create_vertical_crs_ex()
2019-11-14Code reformatEven Rouault
2019-11-09Doc: document oddity related to identification of CRS from ESRI WKTEven Rouault
Or more generally formulations that don't have an explicit axis order. Refs https://github.com/pyproj4/pyproj/issues/475 projinfo 'GEOGCS["GCS_WGS_1984",DATUM["D_WGS_1984",SPHEROID["WGS_1984",6378137.0,298.257223563]],PRIMEM["Greenwich",0.0],UNIT["Degree",0.0174532925199433]]' returns EPSG:4326 with 100% confidence. But its axis order is not the same as EPSG:4326. I've pondered about this, like decreasing the confidence of the match, but this would have downstream effects on GDAL (shapefiles with the above content in a .prj would no longer be identified as EPSG:4326). So for now, document that oddity.
2019-11-04proj_create_vertical_crs(): enhance docEven Rouault
2019-11-04Merge remote-tracking branch 'origin/master' into geoid_modelEven Rouault
2019-11-02Add a geoid_model name in database, use GEOIDMODEL for transformations, add ↵Even Rouault
a proj_create_vertical_crs_ex()
2019-10-30createFromWkt(): be tolerant to missing scale_factor parameter (fixes #1700)Even Rouault
This is invalid WKT, but GDAL 2.4 used to accept it and make a reasonable use of it... Currently we default it to 0 which is non sensical. Better use 1 as GDAL 2.4 did, and emit a warning. Other fix: proj_create_from_wkt() was documented to operate by default in non-strict validation mode, but it was actually in strict mode. So do as documented.
2019-10-24Generalize generalize_proj_crs_create_bound_vertical_crs_to_WGS84()Even Rouault
In recent commits, we added a generalize_proj_crs_create_bound_vertical_crs_to_WGS84() function, but there are situations where more accurate results can be obtained, if instead of specifying WGS84 as the hub CRS, the user can specify the exact hub CRS. For example the GEOID2018 grid is against NAD83(2011). So replace this function with proj_crs_create_bound_vertical_crs()
2019-10-04Add a proj_crs_demote_to_2D(). Useful if forced to export a 3D CRS to a best ↵Even Rouault
approximate as WKT1 that doesn't support it
2019-10-04proj_normalize_for_visualization(): make it work with CRS objectsEven Rouault
2019-10-02Add API and WKT mapping for 'nsper' to EPSG Vertical Persepective methodEven Rouault
Relates to https://github.com/OSGeo/gdal/issues/1856
2019-09-23Document the autopromotion to 3D when mix of 2D/3D CRS in ↵Even Rouault
createOperations(), and test it (fixes #1623)
2019-09-12C API: add proj_crs_create_bound_vertical_crs_to_WGS84()Even Rouault
2019-09-11API: add CRS::promoteTo3D(), proj_crs_promote_to_3D() and ↵Even Rouault
proj_crs_create_projected_3D_crs_from_2D() (fixes #1587) Also add a --3d switch to projinfo
2019-09-08Merge pull request #1585 from rouault/replace_2018_by_2019Kristian Evers
Use in API and utilities WKT2_2019 instead of WKT2_2018 (fixes #1578)
2019-09-08Use in API and utilities WKT2_2019 instead of WKT2_2018 (fixes #1518)Even Rouault
- C API: PJ_GUESSED_WKT2_2019 is added, PJ_GUESSED_WKT2_2018 aliased to it - C API: PJ_WKT2_2019[_SIMPLIFIED] is added, PJ_WKT2_2018[_SIMPLIFIED] alias to it - C++ API: similarly for WKTFormatter::Convention::WKT2_2019[_SIMPLIFIED] Those above changes should be fully backward API and ABI compatible. projinfo changes: - accept WKT2_2019 as value for -o switch. WKT2_2018 is still accepted (undocumented) - output now uses 'WKT2_2019 string:', so might break scripts that would rely on that. Other internal code references to WKT2_2018 changes to WKT2_2019, included in tests.
2019-09-05BUG: add SANITIZE_CTX for coordoperation is_instantiable and ↵snowman2
has_ballpark_transformation