Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2025-01-18 09:36:40

0001 // Boost.Geometry
0002 
0003 // Copyright (c) 2017-2018, Oracle and/or its affiliates.
0004 // Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
0005 
0006 // Use, modification and distribution is subject to the Boost Software License,
0007 // Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
0008 // http://www.boost.org/LICENSE_1_0.txt)
0009 
0010 #ifndef BOOST_GEOMETRY_PROJECTIONS_INVALID_POINT_HPP
0011 #define BOOST_GEOMETRY_PROJECTIONS_INVALID_POINT_HPP
0012 
0013 
0014 #include <cmath>
0015 
0016 #include <boost/geometry/core/access.hpp>
0017 
0018 
0019 namespace boost { namespace geometry { namespace projections
0020 {
0021 
0022 // Originally in pj_transform()
0023 template <typename Point>
0024 inline void set_invalid_point(Point & point)
0025 {
0026     geometry::set<0>(point, HUGE_VAL);
0027     geometry::set<1>(point, HUGE_VAL);
0028 }
0029 
0030 template <typename Point>
0031 inline bool is_invalid_point(Point const& point)
0032 {
0033     return geometry::get<0>(point) == HUGE_VAL;
0034 }
0035 
0036 }}} // namespace boost::geometry::projections
0037 
0038 #endif // BOOST_GEOMETRY_PROJECTIONS_INVALID_POINT_HPP