course.hpp 1.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940
  1. // Boost.Geometry (aka GGL, Generic Geometry Library)
  2. // Copyright (c) 2007-2012 Barend Gehrels, Amsterdam, the Netherlands.
  3. // This file was modified by Oracle on 2014.
  4. // Modifications copyright (c) 2014, Oracle and/or its affiliates.
  5. // Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
  6. // Use, modification and distribution is subject to the Boost Software License,
  7. // Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
  8. // http://www.boost.org/LICENSE_1_0.txt)
  9. #ifndef BOOST_GEOMETRY_ALGORITHMS_DETAIL_COURSE_HPP
  10. #define BOOST_GEOMETRY_ALGORITHMS_DETAIL_COURSE_HPP
  11. #include <boost/geometry/algorithms/detail/azimuth.hpp>
  12. namespace boost { namespace geometry
  13. {
  14. #ifndef DOXYGEN_NO_DETAIL
  15. namespace detail
  16. {
  17. /// Calculate course (bearing) between two points.
  18. ///
  19. /// NOTE: left for convenience and temporary backward compatibility
  20. template <typename ReturnType, typename Point1, typename Point2>
  21. inline ReturnType course(Point1 const& p1, Point2 const& p2)
  22. {
  23. return azimuth<ReturnType>(p1, p2);
  24. }
  25. } // namespace detail
  26. #endif // DOXYGEN_NO_DETAIL
  27. }} // namespace boost::geometry
  28. #endif // BOOST_GEOMETRY_ALGORITHMS_DETAIL_COURSE_HPP