do_reverse.hpp 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647
  1. // Boost.Geometry (aka GGL, Generic Geometry Library)
  2. // Copyright (c) 2007-2012 Barend Gehrels, Amsterdam, the Netherlands.
  3. // Copyright (c) 2013 Adam Wulkiewicz, Lodz, Poland
  4. // Use, modification and distribution is subject to the Boost Software License,
  5. // Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
  6. // http://www.boost.org/LICENSE_1_0.txt)
  7. #ifndef BOOST_GEOMETRY_ALGORITHMS_DETAIL_OVERLAY_DO_REVERSE_HPP
  8. #define BOOST_GEOMETRY_ALGORITHMS_DETAIL_OVERLAY_DO_REVERSE_HPP
  9. #include <boost/geometry/core/point_order.hpp>
  10. namespace boost { namespace geometry
  11. {
  12. #ifndef DOXYGEN_NO_DETAIL
  13. namespace detail { namespace overlay
  14. {
  15. // Metafunction helper for intersection and union
  16. template <order_selector Selector, bool Reverse = false>
  17. struct do_reverse {};
  18. template <>
  19. struct do_reverse<clockwise, false> : boost::false_type {};
  20. template <>
  21. struct do_reverse<clockwise, true> : boost::true_type {};
  22. template <>
  23. struct do_reverse<counterclockwise, false> : boost::true_type {};
  24. template <>
  25. struct do_reverse<counterclockwise, true> : boost::false_type {};
  26. }} // namespace detail::overlay
  27. #endif // DOXYGEN_NO_DETAIL
  28. }} // namespace boost::geometry
  29. #endif // BOOST_GEOMETRY_ALGORITHMS_DETAIL_OVERLAY_DO_REVERSE_HPP