Ejemplo n.º 1
0
 inline void apply(Item1 const& item1, Item2 const& item2)
 {
     if ( !items_overlap
          && (geometry::within(*points_begin(*item1), *item2)
              || geometry::within(*points_begin(*item2), *item1))
          )
     {
         items_overlap = true;
     }
 }
Ejemplo n.º 2
0
    static inline return_type apply(Linear1 const& linear1,
                                    Linear2 const& linear2,
                                    Strategy const& strategy,
                                    bool = false)
    {
        if (geometry::num_points(linear1) == 1)
        {
            return dispatch::distance
                <
                    typename point_type<Linear1>::type,
                    Linear2,
                    Strategy
                >::apply(*points_begin(linear1), linear2, strategy);
        }

        if (geometry::num_points(linear2) == 1)
        {
            return dispatch::distance
                <
                    typename point_type<Linear2>::type,
                    Linear1,
                    Strategy
                >::apply(*points_begin(linear2), linear1, strategy);
        }

        if (geometry::num_segments(linear2) < geometry::num_segments(linear1))
        {
            return point_or_segment_range_to_geometry_rtree
                <
                    geometry::segment_iterator<Linear2 const>,
                    Linear1,
                    Strategy
                >::apply(geometry::segments_begin(linear2),
                         geometry::segments_end(linear2),
                         linear1,
                         strategy);

        }

        return point_or_segment_range_to_geometry_rtree
            <
                geometry::segment_iterator<Linear1 const>,
                Linear2,
                Strategy
            >::apply(geometry::segments_begin(linear1),
                     geometry::segments_end(linear1),
                     linear2,
                     strategy);
    }
Ejemplo n.º 3
0
Curve::const_point_iterator Curve::vertices_begin() const
{
	return points_begin(0);
}
Ejemplo n.º 4
0
// Adavnced Iterators access
Curve::point_iterator Curve::vertices_begin()
{
	return points_begin(0);
}
Ejemplo n.º 5
0
 static inline iterator_type begin(MultiPoint& multipoint)
 {
     return points_begin(multipoint);
 }
Ejemplo n.º 6
0
void Ftbs::recalculate_radius() {
	max_radius2 = 0;
	furthest_point = Vector::Zero;
	for (auto it = points_begin(); it != points_end(); ++it)
		update_radius(*it);
}