1 // Boost.Geometry (aka GGL, Generic Geometry Library)
3 // Copyright (c) 2007-2012 Barend Gehrels, Amsterdam, the Netherlands.
5 // This file was modified by Oracle on 2016.
6 // Modifications copyright (c) 2016, Oracle and/or its affiliates.
7 // Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
9 // Use, modification and distribution is subject to the Boost Software License,
10 // Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
11 // http://www.boost.org/LICENSE_1_0.txt)
13 #ifndef BOOST_GEOMETRY_STRATEGIES_INTERSECTION_HPP
14 #define BOOST_GEOMETRY_STRATEGIES_INTERSECTION_HPP
17 #include <boost/geometry/core/point_type.hpp>
18 #include <boost/geometry/geometries/segment.hpp>
20 #include <boost/geometry/policies/relate/intersection_points.hpp>
21 #include <boost/geometry/policies/relate/direction.hpp>
22 #include <boost/geometry/policies/relate/tupled.hpp>
24 #include <boost/geometry/strategies/intersection.hpp>
25 #include <boost/geometry/strategies/side.hpp>
26 #include <boost/geometry/strategies/intersection_result.hpp>
28 #include <boost/geometry/strategies/cartesian/cart_intersect.hpp>
29 #include <boost/geometry/strategies/cartesian/side_by_triangle.hpp>
30 #include <boost/geometry/strategies/spherical/intersection.hpp>
31 #include <boost/geometry/strategies/spherical/ssf.hpp>
33 #include <boost/geometry/policies/robustness/segment_ratio_type.hpp>
36 namespace boost { namespace geometry
41 \brief "compound strategy", containing a segment-intersection-strategy
49 typename IntersectionPoint,
50 typename RobustPolicy,
51 typename CalculationType = void
53 struct intersection_strategies
56 // for development BOOST_STATIC_ASSERT((! boost::is_same<RobustPolicy, void>::type::value));
58 typedef typename geometry::point_type<Geometry1>::type point1_type;
59 typedef typename geometry::point_type<Geometry2>::type point2_type;
60 typedef typename model::referring_segment<point1_type const> segment1_type;
61 typedef typename model::referring_segment<point2_type const> segment2_type;
63 typedef segment_intersection_points
66 typename geometry::segment_ratio_type
68 IntersectionPoint, RobustPolicy
73 typedef typename strategy::intersection::services::default_strategy
76 policies::relate::segments_tupled
78 policies::relate::segments_intersection_points
82 policies::relate::segments_direction
85 >::type segment_intersection_strategy_type;
87 typedef typename strategy::side::services::default_strategy
91 >::type side_strategy_type;
93 typedef RobustPolicy rescale_policy_type;
97 }} // namespace boost::geometry
100 #endif // BOOST_GEOMETRY_STRATEGIES_INTERSECTION_HPP