Commit Graph

5217 Commits

Author SHA1 Message Date
Adam Wulkiewicz
786bc54c68 Add util/type_traits, polylinear_tag, simplify types in umbrella strategies. 2020-08-28 19:12:31 +02:00
Adam Wulkiewicz
5ca542fc4f Merge pull request #726 from awulkiew/feature/strategies
Umbrella strategies.
2020-08-28 16:16:25 +02:00
Adam Wulkiewicz
0166c8ea6e Merge pull request #743 from awulkiew/feature/for_each
Refactor for_each_x and implement new algorithms.
2020-08-24 12:37:23 +02:00
Adam Wulkiewicz
7ef3117f27 [for_each] Refactor for_each_x and implement new algorithms.
for_each_range now expects functors instead of structs with apply()
member function.

for_each_segment now calls functor also for degenerated ranges for
consistency with segment_iterator.

New algorithms based on std::all_of, std::any_of and std::none_of
- all_points_of, any_point_of, none_point_of
- all_segments_of, any_segment_of, none_segment_of
- all_ranges_of, any_range_of, none_range_of

New algorithms used in several places in the library.

This code requires C++14.
2020-08-24 12:28:43 +02:00
Adam Wulkiewicz
070480d97c Merge pull request #745 from awulkiew/feature/constexpr
Support constexpr in points, segment, box, get, dot and cross products.
2020-08-24 12:26:52 +02:00
Barend Gehrels
5813841757 Merge pull request #744 from barendgehrels/fix/remove_is_ii
[get_turn_info] Remove the recently added is_ii
2020-08-19 09:51:30 +02:00
Adam Wulkiewicz
0326eaf679 [arithmetic][core][geometries] Support constexpr in points, segment, box, get, dot and cross products. 2020-08-16 00:50:35 +02:00
Adam Wulkiewicz
99fe9fe6c6 [is_valid] Add TODO comments in is_valid for linestrings. 2020-08-13 19:19:32 +02:00
Barend Gehrels
7739109b3b [get_turn_info] Remove the recently added is_ii 2020-08-12 11:39:22 +02:00
Adam Wulkiewicz
734b6470af [strategies] Add missing #includes. 2020-08-10 21:06:46 +02:00
Barend Gehrels
8251f19331 Merge pull request #741 from barendgehrels/fix/handle_as_touch
Fix/handle as touch
2020-08-10 20:46:00 +02:00
Adam Wulkiewicz
98617679bb [algorithms] Fix dangling references for referring_segment and non-true references returned from ranges. 2020-08-10 12:40:55 +02:00
Adam Wulkiewicz
52cceae021 [strategies] Relocate area, envelope and expand strategies. 2020-08-05 22:59:13 +02:00
Barend Gehrels
adef6b24de [turns] handle ii-situation in touch,
which is a new situation which needs to be handled in the handle-as-touch,
in last commit.
2020-08-05 11:10:15 +02:00
Barend Gehrels
dfbbfc0a87 [turns] if the touch-interior touches near the end (near the IP), then handle
it as if it is a touch
2020-08-05 10:43:35 +02:00
Adam Wulkiewicz
9ede81c724 Merge pull request #738 from awulkiew/fix/direct_formulas2
[formulas] Normalize resulting longitudes in direct formulas.
2020-07-31 23:43:29 +02:00
Adam Wulkiewicz
36298d6324 [formulas] Normalize resulting longitudes in direct formulas. 2020-07-31 19:44:18 +02:00
Barend Gehrels
9759656d2b Merge pull request #736 from barendgehrels/fix/imperfect-touch
Fix errors in some floating point cases
2020-07-22 11:57:35 +02:00
Barend Gehrels
0969372147 [get_turns] use distance measures for side, and handle situation
with an imperfect touch (floating point issue)
2020-07-22 11:53:48 +02:00
Barend Gehrels
761170b0b4 [intersection] check for disjoint-by-range.
Without it, in FP calculations, for nearly collinear segments, it might happen that an intersection is calculated even if the ranges are farther apart from each other
2020-07-15 12:45:34 +02:00
Adam Wulkiewicz
a5b46d0f8b [algorithms][strategies] Add umbrella strategies for area, envelope and expand. 2020-07-10 12:58:23 +02:00
Adam Wulkiewicz
5c878cfb31 Merge pull request #700 from vissarion/fix_default_strategies_distance
Add missing cases for default strategies in distance algorithm
2020-07-08 20:44:21 +02:00
Barend Gehrels
cc0643941a [turns] correct variable names, remove old unused functionality 2020-07-08 10:18:00 +02:00
Barend Gehrels
d347251055 [traversal] Support additional cluster exit functionality.
This makes it more efficient too (sort-by-side one time less).
This fixes some cases in buffer when rescaling is turned off.
2020-06-24 12:36:30 +02:00
Barend Gehrels
4cab526355 Merge pull request #724 from barendgehrels/refactoring/intersection
[intersection] refactor segment-intersection class
2020-06-19 22:05:25 +02:00
Mateusz Łoskot
06208f61d7 Fix MSVC warning C4127: conditional expression is constant (#730)
Fixes #727
2020-06-19 19:12:58 +02:00
Barend Gehrels
81c8351d82 [intersection] refactor segment-intersection class,
to avoid using both non-rescaled and rescaled coordinates in one method
2020-06-10 14:30:34 +02:00
Caian Benedicto
10b0c37216 [index] Add custom pack allocator to r-tree constructor (#720)
* Add pack overload that accepts custom allocator

* Refactor packed rtree construction to pack_construct

* Add rtree constructors with support for a pack allocator

* Add copyright to modified files

* Rework constructors to leave pack allocator at the end

* Rename tree_allocator and pack_allocator

* Update list of contributors

* Fix temp_allocator comment
2020-06-08 18:33:41 +02:00
Jonathan Wakely
aafbceccc7 Make index::detail::rtree::visitors::insert base class public
Fixes #721
2020-06-05 19:29:27 +01:00
Barend Gehrels
001274d72c Merge pull request #712 from barendgehrels/fix/sort-by-side-stability
[overlay] Fix possible instabilities in sort_by_side
2020-05-15 22:45:14 +02:00
Adam Wulkiewicz
a92b5e36fc Merge pull request #695 from awulkiew/feature/setops_output
Support tupled-output in difference, sym_difference and union_.
2020-05-13 17:04:04 +02:00
Adam Wulkiewicz
1d994350bd Merge pull request #710 from awulkiew/fix/varray
[index] Use memcpy and memmove only if T is_trivially_copyable.
2020-05-13 16:55:38 +02:00
tinko92
bf8f192412 [extensions] Performance improvements for side_robust strategy (#701)
* reorganize some parts of orient2d for a speedup

* replace array in orient2d with own clearly named type.
2020-05-13 16:10:58 +03:00
Barend Gehrels
cb3eff6657 [overlay] Fix possible instabilities in sort_by_side
plus some minor code refactoring
2020-05-13 14:10:04 +02:00
Barend Gehrels
70ecdfdd19 [buffer] Fix direction code for some new cases.
The similar_direction function could be erroneous for corner cases,
refactored it out.
This also makes it a bit less dependent on infinite_line (cartesian)
2020-05-06 14:22:32 +02:00
Barend Gehrels
ef66e923cc Merge pull request #708 from barendgehrels/feature/buffer-turn-in-original-revision
[buffer] remove rescaling from the turn-in-original check
2020-05-06 10:24:54 +02:00
Adam Wulkiewicz
d09596b96e [setops] Rename single_tag_from_base_tag util and remove commented code. 2020-05-05 20:47:15 +02:00
Adam Wulkiewicz
5f2d4b31f0 [index] Use memcpy and memmove only if T is_trivially_copyable.
In C++03 mimic the trait with has_trivial_copy, has_trivial_assign and
has_trivial_destructor.
2020-05-01 23:43:05 +02:00
Adam Wulkiewicz
f3d1e702d9 [relate] Add missing include. 2020-04-30 23:44:05 +02:00
Barend Gehrels
14059a2c69 [buffer] remove rescaling from the turn-in-original check 2020-04-29 13:49:24 +02:00
Barend Gehrels
c93594b20d [buffer] add strategy to expand and
other review remarks
2020-04-29 12:27:45 +02:00
Barend Gehrels
13890d9801 [buffer] additional cleanup and fix sections with normal box type 2020-04-29 12:27:45 +02:00
Barend Gehrels
d4af24851e [buffer] revise turn_in_piece visitor:
- avoid side_of_intersection
- use new abstraction piece_border to verify point-in-piece
- this replaces the robust_ring
- and more related
2020-04-29 12:27:43 +02:00
Vissarion Fisikopoulos
9c1cc9a22c [algorithms] [distance] Add missing cases for default strategies 2020-04-22 14:10:25 +03:00
Adam Wulkiewicz
e825b50ccb [srs] Fix EPSG 3785 definitions. 2020-04-16 18:28:54 +02:00
Mateusz Łoskot
b554a5f87d Correct #689 with check for C++14 support instead of C++11 features (#696) 2020-04-15 18:58:20 +02:00
Adam Wulkiewicz
5a92ca8664 [setops] Add suport for tupled-output in difference, sym_difference and union_. 2020-04-13 15:58:17 +02:00
Adam Wulkiewicz
670c52d3e3 [intersection] Modify tupled-output utils and move them out from intersection code. 2020-04-13 15:56:48 +02:00
Mateusz Łoskot
2dbe5bf554 Deprecate C++03 in Boost 1.73 (#689)
Following discussion in #590, we are identifying support for C++03
as a candidate for removal from future releases of Boost.Geometry.

Issue deprecation warning during compilation in C++03 conformance mode
Users can define BOOST_GEOMETRY_DISABLE_DEPRECATED_03_WARNING to disable it.
2020-03-29 00:19:58 +01:00
Adam Wulkiewicz
201530285a Merge pull request #650 from awulkiew/feature/setops_output
Missing input combinations in intersection() and introduction of tupled-output.
2020-03-26 15:13:01 +01:00