65 Commits

Author SHA1 Message Date
Loïc Bartoletti
4a353d1a12 Marks deprecated methods in QgsGeometryUtils redundant with QgsGeometryUtilsBase 2023-12-01 11:17:11 +01:00
Loïc Bartoletti
ac3e73e25c [refacto] QgsGeometryUtils: move base methods to a dedicated class
Refactor QgsGeometryUtils to separate "basic" methods from those involving QGIS
composite types.
By "basic" methods, we refer to those that only require doubles or (qgs)vectors.
These methods are now encapsulated in their dedicated classes and can be called
from anywhere to prevent duplications in certain methods (in particular Cartesian distance calculation).

To maintain API compatibility, all methods are also accessible in QgsGeometryUtils
which acts as a pass-through to QgsGeometryUtilsBase.
2023-12-01 11:17:11 +01:00
Loïc Bartoletti
3ab676e603 QgsGeometryUtils: move 2D distance code into QgsGeometryUtils.h and uses it 2023-12-01 11:17:11 +01:00
dubravat
e1ba6f5272 Mistype in QgsGeometryUtils::segmentSide description was fixed 2023-11-23 08:28:20 +10:00
Nyall Dawson
4b673bf860 Improve documentation 2023-06-29 20:43:08 +10:00
Nyall Dawson
933db142c5 Add method to test whether 3 points are collinear 2023-06-29 20:43:08 +10:00
Nyall Dawson
b14d42d147 Add method to return the fraction along a line for a point 2023-06-29 20:43:08 +10:00
Antoine
556df9d4f6 3.24 to 3.26 2022-03-10 09:11:39 +01:00
Antoine
53b92e14c6 fix documentation 2022-03-10 09:11:38 +01:00
Antoine
ced846856b change distToInfiniteLine method parameters 2022-03-10 09:11:38 +01:00
Antoine
9fb24b424c add method to compute distance between point and infinite line 2022-03-10 09:11:38 +01:00
Nyall Dawson
ce7d4220c5 Apply suggestions from code review 2022-01-06 13:01:08 +10:00
Tobias Schmetzer
4a32f0d344 Correct parameter name and version description for doxygen 2022-01-06 13:01:08 +10:00
Tobias Schmetzer
f0c7727467 Make segmentLength argument optional with default as 0 instead of the nullptr option 2022-01-06 13:01:08 +10:00
Tobias Schmetzer
7640026100 Adapt function to comply with default behavior at segmentLength value 0, adapt and improve test cases, include .sip.in files, corrected segmentLength calculation 2022-01-06 13:01:08 +10:00
Tobias Schmetzer
9cbcae58b5 Add QgsGeometryUtils::perpendicularCenterSegment() with description in header file, test case and sip.in for Docx 2022-01-06 13:01:08 +10:00
Loïc Bartoletti
c63c630c16 const qgsgeometryutils 2021-09-24 11:17:54 +10:00
Loïc Bartoletti
ba409e0832 readd qgsgeometry method 2021-06-09 10:45:40 +10:00
Loïc Bartoletti
da7c614f1a sipify 2021-06-09 10:45:40 +10:00
Loïc Bartoletti
65392c2329 fix sip; add method using QgsGeometry, add tests, revert missing convertTo/add 2021-06-09 10:45:40 +10:00
Loïc Bartoletti
7c0f3a1f6c sipify 2021-06-09 10:45:40 +10:00
Loïc Bartoletti
da7c8fa04e sipify 2021-06-09 10:45:40 +10:00
Denis Rouzaud
35c557a234 run sipify 2021-05-26 14:30:54 +02:00
Loïc Bartoletti
0a48e804c8 dox++ 2021-04-29 11:15:34 +10:00
Loïc Bartoletti
24dba98ab2 fix DocCoverage and Doxygen 2021-04-29 11:15:34 +10:00
Loïc Bartoletti
e837b6f5b5 deprecate and replace setZValueFromPoints by transferFirstZValuteToPoint 2021-04-29 11:15:34 +10:00
Loïc Bartoletti
95cff79cec replace setMValueFromPoints by transferFirstMValuteToPoint 2021-04-29 11:15:34 +10:00
Loïc Bartoletti
4231134f78 add a warning 2021-04-29 11:15:34 +10:00
Loïc Bartoletti
dcfa1bd02d Update setMValueFromPoints dox 2021-04-29 11:15:34 +10:00
Loïc Bartoletti
9e81011908 Adds setMValueFromPoints 2021-04-29 11:15:34 +10:00
Denis Rouzaud
ba8a445850 run sipify 2021-03-22 21:13:52 +01:00
Nyall Dawson
0c5ffe7ecf Spelling 2021-03-19 18:47:23 +10:00
Nyall Dawson
425f27186f Add method to determine closest side of rectangle to a point 2021-03-19 18:47:23 +10:00
Nyall Dawson
ba6d96725b Add geometry util to calculate a point along a segment offset in a perpendicular direction by a set offset amount 2021-03-19 18:47:23 +10:00
Loïc Bartoletti
fe80965d50 [API] Add angleBisector method 2020-12-07 08:40:59 +10:00
Loïc Bartoletti
d6ac6c4029 Fix since version for bisector method 2020-12-02 19:46:13 +10:00
Loïc Bartoletti
25e14ee766 add python binding 2020-11-28 08:11:54 +10:00
Nyall Dawson
746ee315bd Fix boolean literal presentation in dox/PyQGIS docs 2020-10-16 16:03:26 +10:00
Nyall Dawson
d3f038c929 Sipify 2020-10-09 11:20:09 +10:00
Nyall Dawson
4ee9feb56b Sipify 2020-10-09 11:20:09 +10:00
Nyall Dawson
fe5615ea44 Hold the GIL for more geometry related methods 2020-09-18 11:50:27 +10:00
Nyall Dawson
a5101f2ade [sipify] Fix header formatting 2020-06-13 16:49:14 +10:00
Nyall Dawson
cedd73ee4d More list formatting fixes 2020-06-13 16:49:14 +10:00
olivierdalang
68582a6e84 [tracing curves] experimental notice 2020-05-14 16:12:29 +02:00
olivierdalang
ab423ca2a4 Add "convert to curves" algorithm followup 2020-05-12 17:54:43 +02:00
Nyall Dawson
3a6cc5c2ca Add method to return weighted point inside triangle 2019-10-01 04:05:13 +10:00
Nyall Dawson
975eedc146 Add method to calculate the area of a triangle 2019-10-01 04:05:13 +10:00
Alessandro Pasotti
6967a21882 toJsonV2 2019-04-16 14:00:59 +02:00
Nyall Dawson
b6d66becab Sipify 2019-02-27 09:41:11 +10:00
Nyall Dawson
384d310233 Minor improvements to PyQGIS returns for SIP_OUT params 2019-02-05 04:55:34 +11:00