include in point_to_geometry.hpp implementation of point-to-multigeometry
distance computations and dispatches; compute, whenever applicable, the closest
feature of the goemetry to the point, and then compute the distance as the
distance of this closest feature to the point; optimize the performance of
point-to-ring and point-to-polygon by not computing both containment and distance
to the boundary: compute the distance to the boundary only if the containment
test fails;
to compute first the point-segment pair that realizes the minimum comparable
distance, and then use this pair to compute the actual distance; for the
cartesian-specific approach modify the code to work correctly and efficiently
for both comparable and non-comparable strategies, without calling
distance_comparable_to_regular;
the distance of two linear geometries: there are two versions implemented,
that differ on the type of objects stored in the R-Tree:
* the points of the geometry are stored in the R-Tree, in which case
the two geometries are first checked for intersection, and then,
using the R-Tree we compute the distances of the points of one geometry
to the segments of the other, and vice versa
* the segments of one geometry are stored in the R-Tree and then the
R-Tree is queried with the segments of the second geometry
The second approach is currently the default.
based on the type of the geometry:
* returns a point iterator for multipoints
* returns a segment iterator for linestrings, rings, polygons,
multilinestrings and multipolygons
the utility class also provides static begin and end methods for accessing
the first and beyond elements of the iterator type it defines
Convert struct to functions templates (pick_seeds() functions).
Move template parameters from struct level to method level.
Both for automatic type deduction.
The rationale to remove polymorphic nodes:
1. such nodes can't work properly if stored in shared memory due to the way how addresses are calculated (using offsets).
2. the rtree using Variant-based nodes has similar performance and takes less memory.
3. the rtree using newly added weak_nodes (not supported/enabled yet) will be even faster and smaller.
This is the first step to entirely drop the support for polymorphic nodes. After this it should be not needed to explicitly specify the Nodes types in visitors, therefore it should be possible to dispatch the nodes types statically more conveniently, simplify templates by removal of unneeded parameters, write simpler and more maintainable code, etc.
Remove specialization of count visitor for value_type, don't duplicate the same algorithm in 2 places.
Move Value/Indexable-aware parts into smaller helper struct and specialize it.
due to the change of namespace and name of the segment_iterator_type class;
make constructors of bg::segment_iterator class inline; change the return type
of segments_begin and segments_end to be segment_iterator<Geometry const>;