Merge branch 'develop' into bg-prepare

Conflicts due to moving projections from extensions and changes in
dissolve.
This commit is contained in:
Adam Wulkiewicz
2018-02-23 22:05:16 +01:00
292 changed files with 62433 additions and 1402 deletions

View File

@@ -3,9 +3,10 @@
// Copyright (c) 2007-2012 Barend Gehrels, Amsterdam, the Netherlands.
// Copyright (c) 2008-2012 Bruno Lalande, Paris, France.
// Copyright (c) 2009-2012 Mateusz Loskot, London, UK.
// Copyright (c) 2017 Adam Wulkiewicz, Lodz, Poland.
// This file was modified by Oracle on 2017.
// Modifications copyright (c) 2017 Oracle and/or its affiliates.
// This file was modified by Oracle on 2017, 2018.
// Modifications copyright (c) 2017-2018 Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
// Parts of Boost.Geometry are redesigned from Geodan's Geographic Library
@@ -19,7 +20,6 @@
#define BOOST_GEOMETRY_ALGORITHMS_AREA_HPP
#include <boost/concept_check.hpp>
#include <boost/mpl/if.hpp>
#include <boost/range/functions.hpp>
#include <boost/range/metafunctions.hpp>
@@ -43,7 +43,9 @@
#include <boost/geometry/algorithms/detail/multi_sum.hpp>
#include <boost/geometry/strategies/area.hpp>
#include <boost/geometry/strategies/area_result.hpp>
#include <boost/geometry/strategies/default_area_result.hpp>
#include <boost/geometry/strategies/default_strategy.hpp>
#include <boost/geometry/strategies/concepts/area_concept.hpp>
@@ -56,6 +58,7 @@
namespace boost { namespace geometry
{
#ifndef DOXYGEN_NO_DETAIL
namespace detail { namespace area
{
@@ -83,10 +86,10 @@ template
struct ring_area
{
template <typename Ring, typename Strategy>
static inline typename Strategy::return_type
static inline typename area_result<Ring, Strategy>::type
apply(Ring const& ring, Strategy const& strategy)
{
BOOST_CONCEPT_ASSERT( (geometry::concepts::AreaStrategy<Strategy>) );
BOOST_CONCEPT_ASSERT( (geometry::concepts::AreaStrategy<Ring, Strategy>) );
assert_dimension<Ring, 2>();
// Ignore warning (because using static method sometimes) on strategy
@@ -98,7 +101,7 @@ struct ring_area
if (boost::size(ring)
< core_detail::closure::minimum_ring_size<Closure>::value)
{
return typename Strategy::return_type();
return typename area_result<Ring, Strategy>::type();
}
typedef typename reversible_view<Ring const, Direction>::type rview_type;
@@ -110,7 +113,7 @@ struct ring_area
rview_type rview(ring);
view_type view(rview);
typename Strategy::state_type state;
typename Strategy::template state<Ring> state;
iterator_type it = boost::begin(view);
iterator_type end = boost::end(view);
@@ -144,9 +147,13 @@ template
struct area : detail::calculate_null
{
template <typename Strategy>
static inline typename Strategy::return_type apply(Geometry const& geometry, Strategy const& strategy)
static inline typename area_result<Geometry, Strategy>::type
apply(Geometry const& geometry, Strategy const& strategy)
{
return calculate_null::apply<typename Strategy::return_type>(geometry, strategy);
return calculate_null::apply
<
typename area_result<Geometry, Strategy>::type
>(geometry, strategy);
}
};
@@ -170,10 +177,11 @@ template <typename Polygon>
struct area<Polygon, polygon_tag> : detail::calculate_polygon_sum
{
template <typename Strategy>
static inline typename Strategy::return_type apply(Polygon const& polygon, Strategy const& strategy)
static inline typename area_result<Polygon, Strategy>::type
apply(Polygon const& polygon, Strategy const& strategy)
{
return calculate_polygon_sum::apply<
typename Strategy::return_type,
typename area_result<Polygon, Strategy>::type,
detail::area::ring_area
<
order_as_direction<geometry::point_order<Polygon>::value>::value,
@@ -188,12 +196,12 @@ template <typename MultiGeometry>
struct area<MultiGeometry, multi_polygon_tag> : detail::multi_sum
{
template <typename Strategy>
static inline typename Strategy::return_type
static inline typename area_result<MultiGeometry, Strategy>::type
apply(MultiGeometry const& multi, Strategy const& strategy)
{
return multi_sum::apply
<
typename Strategy::return_type,
typename area_result<MultiGeometry, Strategy>::type,
area<typename boost::range_value<MultiGeometry>::type>
>(multi, strategy);
}
@@ -204,39 +212,73 @@ struct area<MultiGeometry, multi_polygon_tag> : detail::multi_sum
#endif // DOXYGEN_NO_DISPATCH
namespace resolve_variant {
namespace resolve_strategy
{
struct area
{
template <typename Geometry, typename Strategy>
static inline typename area_result<Geometry, Strategy>::type
apply(Geometry const& geometry, Strategy const& strategy)
{
return dispatch::area<Geometry>::apply(geometry, strategy);
}
template <typename Geometry>
static inline typename area_result<Geometry>::type
apply(Geometry const& geometry, default_strategy)
{
typedef typename strategy::area::services::default_strategy
<
typename cs_tag<Geometry>::type
>::type strategy_type;
return dispatch::area<Geometry>::apply(geometry, strategy_type());
}
};
} // namespace resolve_strategy
namespace resolve_variant
{
template <typename Geometry>
struct area
{
template <typename Strategy>
static inline typename Strategy::return_type apply(Geometry const& geometry,
Strategy const& strategy)
static inline typename area_result<Geometry, Strategy>::type
apply(Geometry const& geometry, Strategy const& strategy)
{
return dispatch::area<Geometry>::apply(geometry, strategy);
return resolve_strategy::area::apply(geometry, strategy);
}
};
template <BOOST_VARIANT_ENUM_PARAMS(typename T)>
struct area<boost::variant<BOOST_VARIANT_ENUM_PARAMS(T)> >
{
typedef boost::variant<BOOST_VARIANT_ENUM_PARAMS(T)> variant_type;
template <typename Strategy>
struct visitor: boost::static_visitor<typename Strategy::return_type>
struct visitor
: boost::static_visitor<typename area_result<variant_type, Strategy>::type>
{
Strategy const& m_strategy;
visitor(Strategy const& strategy): m_strategy(strategy) {}
template <typename Geometry>
typename Strategy::return_type operator()(Geometry const& geometry) const
typename area_result<variant_type, Strategy>::type
operator()(Geometry const& geometry) const
{
return area<Geometry>::apply(geometry, m_strategy);
}
};
template <typename Strategy>
static inline typename Strategy::return_type
apply(boost::variant<BOOST_VARIANT_ENUM_PARAMS(T)> const& geometry,
static inline typename area_result<variant_type, Strategy>::type
apply(variant_type const& geometry,
Strategy const& strategy)
{
return boost::apply_visitor(visitor<Strategy>(strategy), geometry);
@@ -268,22 +310,14 @@ and Geographic as well.
\qbk{[area] [area_output]}
*/
template <typename Geometry>
inline typename default_area_result<Geometry>::type area(Geometry const& geometry)
inline typename area_result<Geometry>::type
area(Geometry const& geometry)
{
concepts::check<Geometry const>();
// TODO put this into a resolve_strategy stage
// (and take the return type from resolve_variant)
typedef typename point_type<Geometry>::type point_type;
typedef typename strategy::area::services::default_strategy
<
typename cs_tag<point_type>::type,
point_type
>::type strategy_type;
// detail::throw_on_empty_input(geometry);
return resolve_variant::area<Geometry>::apply(geometry, strategy_type());
return resolve_variant::area<Geometry>::apply(geometry, default_strategy());
}
/*!
@@ -301,19 +335,19 @@ inline typename default_area_result<Geometry>::type area(Geometry const& geometr
\qbk{
[include reference/algorithms/area.qbk]
[heading Available Strategies]
\* [link geometry.reference.strategies.strategy_area_cartesian Cartesian]
\* [link geometry.reference.strategies.strategy_area_spherical Spherical]
\* [link geometry.reference.strategies.strategy_area_geographic Geographic]
[heading Example]
[area_with_strategy]
[area_with_strategy_output]
[heading Available Strategies]
\* [link geometry.reference.strategies.strategy_area_surveyor Surveyor (cartesian)]
\* [link geometry.reference.strategies.strategy_area_spherical Spherical]
[/link geometry.reference.strategies.strategy_area_geographic Geographic]
}
*/
template <typename Geometry, typename Strategy>
inline typename Strategy::return_type area(
Geometry const& geometry, Strategy const& strategy)
inline typename area_result<Geometry, Strategy>::type
area(Geometry const& geometry, Strategy const& strategy)
{
concepts::check<Geometry const>();

View File

@@ -5,6 +5,10 @@
// Copyright (c) 2009-2012 Mateusz Loskot, London, UK.
// Copyright (c) 2014 Adam Wulkiewicz, Lodz, Poland.
// This file was modified by Oracle on 2017.
// Modifications copyright (c) 2017, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
// Parts of Boost.Geometry are redesigned from Geodan's Geographic Library
// (geolib/GGL), copyright (c) 1995-2010 Geodan, Amsterdam, the Netherlands.
@@ -29,10 +33,8 @@
#include <boost/geometry/arithmetic/arithmetic.hpp>
#include <boost/geometry/algorithms/not_implemented.hpp>
#include <boost/geometry/algorithms/append.hpp>
#include <boost/geometry/algorithms/clear.hpp>
#include <boost/geometry/algorithms/for_each.hpp>
#include <boost/geometry/algorithms/detail/assign_values.hpp>
#include <boost/geometry/algorithms/detail/assign_box_corners.hpp>
#include <boost/geometry/algorithms/detail/assign_indexed_point.hpp>
#include <boost/geometry/algorithms/detail/convert_point_to_point.hpp>
@@ -153,7 +155,23 @@ struct range_to_range
geometry::closure<Range1>::value
>::type view_type;
struct default_policy
{
template <typename Point1, typename Point2>
static inline void apply(Point1 const& point1, Point2 & point2)
{
geometry::detail::conversion::convert_point_to_point(point1, point2);
}
};
static inline void apply(Range1 const& source, Range2& destination)
{
apply(source, destination, default_policy());
}
template <typename ConvertPointPolicy>
static inline ConvertPointPolicy apply(Range1 const& source, Range2& destination,
ConvertPointPolicy convert_point)
{
geometry::clear(destination);
@@ -179,8 +197,12 @@ struct range_to_range
it != boost::end(view) && i < n;
++it, ++i)
{
geometry::append(destination, *it);
typename boost::range_value<Range2>::type point;
convert_point.apply(*it, point);
range::push_back(destination, point);
}
return convert_point;
}
};

View File

@@ -3,7 +3,7 @@
// Copyright (c) 2007-2012 Barend Gehrels, Amsterdam, the Netherlands.
// Copyright (c) 2008-2012 Bruno Lalande, Paris, France.
// Copyright (c) 2009-2012 Mateusz Loskot, London, UK.
// Copyright (c) 2014 Adam Wulkiewicz, Lodz, Poland.
// Copyright (c) 2014-2017 Adam Wulkiewicz, Lodz, Poland.
// This file was modified by Oracle on 2017.
// Modifications copyright (c) 2017 Oracle and/or its affiliates.
@@ -144,7 +144,7 @@ struct correct_ring
detail::correct_closure::close_or_open_ring<Ring>::apply(r);
// Check area
typedef typename Strategy::return_type area_result_type;
typedef typename area_result<Ring, Strategy>::type area_result_type;
Predicate<area_result_type> predicate;
area_result_type const zero = 0;
if (predicate(ring_area_type::apply(r, strategy), zero))
@@ -322,8 +322,7 @@ inline void correct(Geometry& geometry)
typedef typename strategy::area::services::default_strategy
<
typename cs_tag<point_type>::type,
point_type
typename cs_tag<point_type>::type
>::type strategy_type;
resolve_variant::correct<Geometry>::apply(geometry, strategy_type());

View File

@@ -0,0 +1,425 @@
// Boost.Geometry
// Copyright (c) 2017-2018, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
// Licensed under the Boost Software License version 1.0.
// http://www.boost.org/users/license.html
#ifndef BOOST_GEOMETRY_ALGORITHMS_DENSIFY_HPP
#define BOOST_GEOMETRY_ALGORITHMS_DENSIFY_HPP
#include <boost/geometry/algorithms/clear.hpp>
#include <boost/geometry/algorithms/detail/convert_point_to_point.hpp>
#include <boost/geometry/algorithms/not_implemented.hpp>
#include <boost/geometry/core/closure.hpp>
#include <boost/geometry/core/exception.hpp>
#include <boost/geometry/core/point_type.hpp>
#include <boost/geometry/core/tag.hpp>
#include <boost/geometry/core/tags.hpp>
#include <boost/geometry/strategies/default_strategy.hpp>
#include <boost/geometry/strategies/densify.hpp>
#include <boost/geometry/util/condition.hpp>
#include <boost/geometry/util/range.hpp>
#include <boost/range/size.hpp>
#include <boost/range/value_type.hpp>
#include <boost/throw_exception.hpp>
namespace boost { namespace geometry
{
#ifndef DOXYGEN_NO_DETAIL
namespace detail { namespace densify
{
template <typename Range>
struct push_back_policy
{
typedef typename boost::range_value<Range>::type point_type;
inline explicit push_back_policy(Range & rng)
: m_rng(rng)
{}
inline void apply(point_type const& p)
{
range::push_back(m_rng, p);
}
private:
Range & m_rng;
};
template <typename Range, typename Point>
inline void convert_and_push_back(Range & range, Point const& p)
{
typename boost::range_value<Range>::type p2;
geometry::detail::conversion::convert_point_to_point(p, p2);
range::push_back(range, p2);
}
template <bool AppendLastPoint = true>
struct densify_range
{
template <typename FwdRng, typename MutRng, typename T, typename Strategy>
static inline void apply(FwdRng const& rng, MutRng & rng_out,
T const& len, Strategy const& strategy)
{
typedef typename boost::range_iterator<FwdRng const>::type iterator_t;
typedef typename boost::range_value<FwdRng>::type point_t;
iterator_t it = boost::begin(rng);
iterator_t end = boost::end(rng);
if (it == end) // empty(rng)
{
return;
}
push_back_policy<MutRng> policy(rng_out);
iterator_t prev = it;
for ( ++it ; it != end ; prev = it++)
{
point_t const& p0 = *prev;
point_t const& p1 = *it;
convert_and_push_back(rng_out, p0);
strategy.apply(p0, p1, policy, len);
}
if (BOOST_GEOMETRY_CONDITION(AppendLastPoint))
{
convert_and_push_back(rng_out, *prev); // back(rng)
}
}
};
template <bool IsClosed1, bool IsClosed2> // false, X
struct densify_ring
{
template <typename Geometry, typename GeometryOut, typename T, typename Strategy>
static inline void apply(Geometry const& ring, GeometryOut & ring_out,
T const& len, Strategy const& strategy)
{
geometry::detail::densify::densify_range<true>
::apply(ring, ring_out, len, strategy);
if (boost::size(ring) <= 1)
return;
typedef typename point_type<Geometry>::type point_t;
point_t const& p0 = range::back(ring);
point_t const& p1 = range::front(ring);
push_back_policy<GeometryOut> policy(ring_out);
strategy.apply(p0, p1, policy, len);
if (BOOST_GEOMETRY_CONDITION(IsClosed2))
{
convert_and_push_back(ring_out, p1);
}
}
};
template <>
struct densify_ring<true, true>
: densify_range<true>
{};
template <>
struct densify_ring<true, false>
: densify_range<false>
{};
}} // namespace detail::densify
#endif // DOXYGEN_NO_DETAIL
#ifndef DOXYGEN_NO_DISPATCH
namespace dispatch
{
template
<
typename Geometry,
typename GeometryOut,
typename Tag1 = typename tag<Geometry>::type,
typename Tag2 = typename tag<GeometryOut>::type
>
struct densify
: not_implemented<Tag1, Tag2>
{};
template <typename Geometry, typename GeometryOut>
struct densify<Geometry, GeometryOut, linestring_tag, linestring_tag>
: geometry::detail::densify::densify_range<>
{};
template <typename Geometry, typename GeometryOut>
struct densify<Geometry, GeometryOut, multi_linestring_tag, multi_linestring_tag>
{
template <typename T, typename Strategy>
static void apply(Geometry const& mls, GeometryOut & mls_out,
T const& len, Strategy const& strategy)
{
std::size_t count = boost::size(mls);
range::resize(mls_out, count);
for (std::size_t i = 0 ; i < count ; ++i)
{
geometry::detail::densify::densify_range<>
::apply(range::at(mls, i), range::at(mls_out, i),
len, strategy);
}
}
};
template <typename Geometry, typename GeometryOut>
struct densify<Geometry, GeometryOut, ring_tag, ring_tag>
: geometry::detail::densify::densify_ring
<
geometry::closure<Geometry>::value != geometry::open,
geometry::closure<GeometryOut>::value != geometry::open
>
{};
template <typename Geometry, typename GeometryOut>
struct densify<Geometry, GeometryOut, polygon_tag, polygon_tag>
{
template <typename T, typename Strategy>
static void apply(Geometry const& poly, GeometryOut & poly_out,
T const& len, Strategy const& strategy)
{
apply_ring(exterior_ring(poly), exterior_ring(poly_out),
len, strategy);
std::size_t count = boost::size(interior_rings(poly));
range::resize(interior_rings(poly_out), count);
for (std::size_t i = 0 ; i < count ; ++i)
{
apply_ring(range::at(interior_rings(poly), i),
range::at(interior_rings(poly_out), i),
len, strategy);
}
}
template <typename Ring, typename RingOut, typename T, typename Strategy>
static void apply_ring(Ring const& ring, RingOut & ring_out,
T const& len, Strategy const& strategy)
{
densify<Ring, RingOut, ring_tag, ring_tag>
::apply(ring, ring_out, len, strategy);
}
};
template <typename Geometry, typename GeometryOut>
struct densify<Geometry, GeometryOut, multi_polygon_tag, multi_polygon_tag>
{
template <typename T, typename Strategy>
static void apply(Geometry const& mpoly, GeometryOut & mpoly_out,
T const& len, Strategy const& strategy)
{
std::size_t count = boost::size(mpoly);
range::resize(mpoly_out, count);
for (std::size_t i = 0 ; i < count ; ++i)
{
apply_poly(range::at(mpoly, i),
range::at(mpoly_out, i),
len, strategy);
}
}
template <typename Poly, typename PolyOut, typename T, typename Strategy>
static void apply_poly(Poly const& poly, PolyOut & poly_out,
T const& len, Strategy const& strategy)
{
densify<Poly, PolyOut, polygon_tag, polygon_tag>::
apply(poly, poly_out, len, strategy);
}
};
} // namespace dispatch
#endif // DOXYGEN_NO_DISPATCH
namespace resolve_strategy
{
struct densify
{
template <typename Geometry, typename Distance, typename Strategy>
static inline void apply(Geometry const& geometry,
Geometry& out,
Distance const& max_distance,
Strategy const& strategy)
{
dispatch::densify<Geometry, Geometry>
::apply(geometry, out, max_distance, strategy);
}
template <typename Geometry, typename Distance>
static inline void apply(Geometry const& geometry,
Geometry& out,
Distance const& max_distance,
default_strategy)
{
typedef typename strategy::densify::services::default_strategy
<
typename cs_tag<Geometry>::type
>::type strategy_type;
/*BOOST_CONCEPT_ASSERT(
(concepts::DensifyStrategy<strategy_type>)
);*/
apply(geometry, out, max_distance, strategy_type());
}
};
} // namespace resolve_strategy
namespace resolve_variant {
template <typename Geometry>
struct densify
{
template <typename Distance, typename Strategy>
static inline void apply(Geometry const& geometry,
Geometry& out,
Distance const& max_distance,
Strategy const& strategy)
{
resolve_strategy::densify::apply(geometry, out, max_distance, strategy);
}
};
template <BOOST_VARIANT_ENUM_PARAMS(typename T)>
struct densify<boost::variant<BOOST_VARIANT_ENUM_PARAMS(T)> >
{
template <typename Distance, typename Strategy>
struct visitor: boost::static_visitor<void>
{
Distance const& m_max_distance;
Strategy const& m_strategy;
visitor(Distance const& max_distance, Strategy const& strategy)
: m_max_distance(max_distance)
, m_strategy(strategy)
{}
template <typename Geometry>
void operator()(Geometry const& geometry, Geometry& out) const
{
densify<Geometry>::apply(geometry, out, m_max_distance, m_strategy);
}
};
template <typename Distance, typename Strategy>
static inline void
apply(boost::variant<BOOST_VARIANT_ENUM_PARAMS(T)> const& geometry,
boost::variant<BOOST_VARIANT_ENUM_PARAMS(T)>& out,
Distance const& max_distance,
Strategy const& strategy)
{
boost::apply_visitor(
visitor<Distance, Strategy>(max_distance, strategy),
geometry,
out
);
}
};
} // namespace resolve_variant
/*!
\brief Densify a geometry using a specified strategy
\ingroup densify
\tparam Geometry \tparam_geometry
\tparam Distance A numerical distance measure
\tparam Strategy A type fulfilling a DensifyStrategy concept
\param geometry Input geometry, to be densified
\param out Output geometry, densified version of the input geometry
\param max_distance Distance threshold (in units depending on strategy)
\param strategy Densify strategy to be used for densification
\qbk{distinguish,with strategy}
\qbk{[include reference/algorithms/densify.qbk]}
\qbk{
[heading Available Strategies]
\* [link geometry.reference.strategies.strategy_densify_cartesian Cartesian]
\* [link geometry.reference.strategies.strategy_densify_spherical Spherical]
\* [link geometry.reference.strategies.strategy_densify_geographic Geographic]
[heading Example]
[densify_strategy]
[densify_strategy_output]
}
*/
template <typename Geometry, typename Distance, typename Strategy>
inline void densify(Geometry const& geometry,
Geometry& out,
Distance const& max_distance,
Strategy const& strategy)
{
concepts::check<Geometry>();
if (max_distance <= Distance(0))
{
BOOST_THROW_EXCEPTION(geometry::invalid_input_exception());
}
geometry::clear(out);
resolve_variant::densify
<
Geometry
>::apply(geometry, out, max_distance, strategy);
}
/*!
\brief Densify a geometry
\ingroup densify
\tparam Geometry \tparam_geometry
\tparam Distance A numerical distance measure
\param geometry Input geometry, to be densified
\param out Output geometry, densified version of the input geometry
\param max_distance Distance threshold (in units depending on coordinate system)
\qbk{[include reference/algorithms/densify.qbk]}
\qbk{
[heading Example]
[densify]
[densify_output]
}
*/
template <typename Geometry, typename Distance>
inline void densify(Geometry const& geometry,
Geometry& out,
Distance const& max_distance)
{
densify(geometry, out, max_distance, default_strategy());
}
}} // namespace boost::geometry
#endif // BOOST_GEOMETRY_ALGORITHMS_DENSIFY_HPP

View File

@@ -15,18 +15,22 @@
#ifndef BOOST_GEOMETRY_ALGORITHMS_DETAIL_AZIMUTH_HPP
#define BOOST_GEOMETRY_ALGORITHMS_DETAIL_AZIMUTH_HPP
#include <boost/geometry/algorithms/not_implemented.hpp>
#include <boost/geometry/core/cs.hpp>
#include <boost/geometry/core/access.hpp>
#include <boost/geometry/core/radian_access.hpp>
#include <boost/geometry/core/tags.hpp>
#include <boost/geometry/util/math.hpp>
#include <boost/geometry/algorithms/not_implemented.hpp>
#include <boost/geometry/formulas/spherical.hpp>
#include <boost/geometry/formulas/vincenty_inverse.hpp>
#include <boost/geometry/srs/spheroid.hpp>
#include <boost/geometry/util/math.hpp>
namespace boost { namespace geometry
{

View File

@@ -41,10 +41,6 @@
#include <boost/geometry/views/detail/normalized_view.hpp>
#if defined(BOOST_GEOMETRY_BUFFER_SIMPLIFY_WITH_AX)
#include <boost/geometry/strategies/cartesian/distance_projected_point_ax.hpp>
#endif
namespace boost { namespace geometry
{
@@ -67,45 +63,21 @@ inline void simplify_input(Range const& range,
// sensitive to small scale input features, however the result will
// look better.
// It also gets rid of duplicate points
#if ! defined(BOOST_GEOMETRY_BUFFER_SIMPLIFY_WITH_AX)
geometry::simplify(range, simplified, distance.simplify_distance());
#else
typedef typename boost::range_value<Range>::type point_type;
typedef strategy::distance::detail::projected_point_ax<> ax_type;
typedef typename strategy::distance::services::return_type
typedef typename geometry::point_type<Range>::type point_type;
typedef typename strategy::distance::services::default_strategy
<
strategy::distance::detail::projected_point_ax<>,
point_type,
point_type
>::type return_type;
typedef strategy::distance::detail::projected_point_ax_less
point_tag, segment_tag, point_type
>::type ds_strategy_type;
typedef strategy::simplify::douglas_peucker
<
return_type
> comparator_type;
point_type, ds_strategy_type
> strategy_type;
typedef strategy::simplify::detail::douglas_peucker
<
point_type,
strategy::distance::detail::projected_point_ax<>,
comparator_type
> dp_ax;
geometry::detail::simplify::simplify_range<2>::apply(range,
simplified, distance.simplify_distance(),
strategy_type());
return_type max_distance(distance.simplify_distance() * 2.0,
distance.simplify_distance());
comparator_type comparator(max_distance);
dp_ax strategy(comparator);
geometry::simplify(range, simplified, max_distance, strategy);
#endif
if (boost::size(simplified) == 2
&& geometry::equals(geometry::range::front(simplified),
geometry::range::back(simplified)))
{
traits::resize<Range>::apply(simplified, 1);
}
}

View File

@@ -127,6 +127,10 @@ public :
void visit_traverse_reject(Turns const& , Turn const& , Operation const& ,
detail::overlay::traverse_error_type )
{}
template <typename Rings>
void visit_generated_rings(Rings const& )
{}
};

View File

@@ -1,6 +1,7 @@
// Boost.Geometry (aka GGL, Generic Geometry Library)
// Copyright (c) 2012-2014 Barend Gehrels, Amsterdam, the Netherlands.
// Copyright (c) 2017 Adam Wulkiewicz, Lodz, Poland.
// This file was modified by Oracle on 2016-2017.
// Modifications copyright (c) 2016-2017 Oracle and/or its affiliates.
@@ -155,8 +156,14 @@ struct buffered_piece_collection
robust_point_type
>::type robust_area_strategy_type;
typedef typename area_strategy_type::return_type area_result_type;
typedef typename robust_area_strategy_type::return_type robust_area_result_type;
typedef typename area_strategy_type::template result_type
<
point_type
>::type area_result_type;
typedef typename robust_area_strategy_type::template result_type
<
robust_point_type
>::type robust_area_result_type;
typedef typename geometry::rescale_policy_type
<

View File

@@ -36,6 +36,8 @@
#if defined(BOOST_GEOMETRY_BUFFER_USE_SIDE_OF_INTERSECTION)
#include <boost/geometry/strategies/cartesian/side_of_intersection.hpp>
#else
#include <boost/geometry/strategies/agnostic/point_in_poly_winding.hpp>
#endif

View File

@@ -193,6 +193,7 @@ struct distance
>
{};
template <typename MultiPoint, typename Linear, typename Strategy>
struct distance
<

View File

@@ -27,7 +27,6 @@
#include <boost/geometry/core/coordinate_system.hpp>
#include <boost/geometry/core/coordinate_type.hpp>
#include <boost/geometry/core/cs.hpp>
#include <boost/geometry/core/srs.hpp>
#include <boost/geometry/core/point_type.hpp>
#include <boost/geometry/core/radian_access.hpp>
#include <boost/geometry/core/tags.hpp>

View File

@@ -1,5 +1,7 @@
// Boost.Geometry (aka GGL, Generic Geometry Library)
// Copyright (c) 2017 Adam Wulkiewicz, Lodz, Poland.
// Copyright (c) 2014-2017, Oracle and/or its affiliates.
// Contributed and/or modified by Menelaos Karavelas, on behalf of Oracle
@@ -107,8 +109,6 @@ struct is_properly_oriented
{
boost::ignore_unused(visitor);
typedef typename point_type<Ring>::type point_type;
typedef detail::area::ring_area
<
order_as_direction<geometry::point_order<Ring>::value>::value,
@@ -117,8 +117,8 @@ struct is_properly_oriented
typedef typename Strategy::template area_strategy
<
point_type
>::type::return_type area_result_type;
Ring
>::type::template result_type<Ring>::type area_result_type;
typename ring_area_predicate
<
@@ -129,7 +129,7 @@ struct is_properly_oriented
area_result_type const zero = 0;
area_result_type const area
= ring_area_type::apply(ring,
strategy.template get_area_strategy<point_type>());
strategy.template get_area_strategy<Ring>());
if (predicate(area, zero))
{
return visitor.template apply<no_failure>();

View File

@@ -1,6 +1,7 @@
// Boost.Geometry (aka GGL, Generic Geometry Library)
// Copyright (c) 2007-2012 Barend Gehrels, Amsterdam, the Netherlands.
// Copyright (c) 2017 Adam Wulkiewicz, Lodz, Poland.
// This file was modified by Oracle on 2017.
// Modifications copyright (c) 2017, Oracle and/or its affiliates.
@@ -94,7 +95,10 @@ inline OutputIterator add_rings(SelectionMap const& map,
add_rings_error_handling error_handling = add_rings_ignore_unordered)
{
typedef typename SelectionMap::const_iterator iterator;
typedef typename AreaStrategy::return_type area_type;
typedef typename AreaStrategy::template result_type
<
GeometryOut
>::type area_type;
area_type const zero = 0;
std::size_t const min_num_points = core_detail::closure::minimum_ring_size

View File

@@ -102,6 +102,43 @@ inline void append_no_dups_or_spikes(Range& range, Point const& point,
}
}
template <typename Range, typename Point, typename SideStrategy, typename RobustPolicy>
inline void append_no_collinear(Range& range, Point const& point,
SideStrategy const& strategy,
RobustPolicy const& robust_policy)
{
// Stricter version, not allowing any point in a linear row
// (spike, continuation or same point)
// The code below this condition checks all spikes/dups
// for geometries >= 3 points.
// So we have to check the first potential duplicate differently
if (boost::size(range) == 1
&& points_equal_or_close(*(boost::begin(range)), point, robust_policy))
{
return;
}
traits::push_back<Range>::apply(range, point);
// If a point is equal, or forming a spike, remove the pen-ultimate point
// because this one caused the spike.
// If so, the now-new-pen-ultimate point can again cause a spike
// (possibly at a corner). So keep doing this.
// Besides spikes it will also avoid adding duplicates.
while(boost::size(range) >= 3
&& point_is_collinear(point,
*(boost::end(range) - 3),
*(boost::end(range) - 2),
strategy,
robust_policy))
{
// Use the Concept/traits, so resize and append again
traits::resize<Range>::apply(range, boost::size(range) - 2);
traits::push_back<Range>::apply(range, point);
}
}
template <typename Range, typename SideStrategy, typename RobustPolicy>
inline void clean_closing_dups_and_spikes(Range& range,
SideStrategy const& strategy,
@@ -137,8 +174,8 @@ inline void clean_closing_dups_and_spikes(Range& range,
}
// Check if closing point is a spike (this is so if the second point is
// considered as a spike w.r.t. the last segment)
if (point_is_spike_or_equal(*second, *ultimate, *first, strategy, robust_policy))
// considered as collinear w.r.t. the last segment)
if (point_is_collinear(*second, *ultimate, *first, strategy, robust_policy))
{
range::erase(range, first);
if (BOOST_GEOMETRY_CONDITION(closed))

View File

@@ -1,6 +1,7 @@
// Boost.Geometry (aka GGL, Generic Geometry Library)
// Copyright (c) 2007-2012 Barend Gehrels, Amsterdam, the Netherlands.
// Copyright (c) 2017 Adam Wulkiewicz, Lodz, Poland.
// This file was modified by Oracle on 2017.
// Modifications copyright (c) 2017 Oracle and/or its affiliates.
@@ -238,7 +239,7 @@ inline void assign_parents(Geometry1 const& geometry1,
typedef typename Strategy::template area_strategy
<
point_type
>::type::return_type area_result_type;
>::type::template result_type<point_type>::type area_result_type;
typedef typename RingMap::iterator map_iterator_type;

View File

@@ -104,7 +104,8 @@ inline void enrich_sort(Operations& operations,
template <typename Operations, typename Turns>
inline void enrich_assign(Operations& operations, Turns& turns)
inline void enrich_assign(Operations& operations, Turns& turns,
bool check_turns)
{
typedef typename boost::range_value<Turns>::type turn_type;
typedef typename turn_type::turn_operation_type op_type;
@@ -125,14 +126,17 @@ inline void enrich_assign(Operations& operations, Turns& turns)
turn_type& turn = turns[it->turn_index];
op_type& op = turn.operations[it->operation_index];
// Normal behaviour: next should point at next turn:
if (it->turn_index == next->turn_index)
if (check_turns && it->turn_index == next->turn_index)
{
// Normal behaviour: next points at next turn, increase next.
// For dissolve this should not be done, turn_index is often
// the same for two consecutive operations
++next;
}
// Cluster behaviour: next should point after cluster, unless
// their seg_ids are not the same
// (For dissolve, this is still to be examined - TODO)
while (turn.is_clustered()
&& it->turn_index != next->turn_index
&& turn.cluster_id == turns[next->turn_index].cluster_id
@@ -157,6 +161,11 @@ inline void enrich_assign(Operations& operations, Turns& turns)
// (this is one not circular therefore fraction is considered)
op.enriched.next_ip_index = static_cast<signed_size_type>(next->turn_index);
}
if (! check_turns)
{
++next;
}
}
}
@@ -507,7 +516,7 @@ inline void enrich_intersection_points(Turns& turns,
detail::overlay::enrich_adapt(mit->second, turns);
}
detail::overlay::enrich_assign(mit->second, turns);
detail::overlay::enrich_assign(mit->second, turns, ! is_dissolve);
}
if (has_colocations)

View File

@@ -31,6 +31,7 @@
#include <boost/geometry/algorithms/detail/overlay/turn_info.hpp>
#include <boost/geometry/algorithms/detail/ring_identifier.hpp>
#include <boost/geometry/algorithms/detail/overlay/segment_identifier.hpp>
#include <boost/geometry/util/condition.hpp>
#if defined(BOOST_GEOMETRY_DEBUG_HANDLE_COLOCATIONS)
# include <iostream>
@@ -313,17 +314,17 @@ inline void assign_cluster_to_turns(Turns& turns,
{
turn_operation_type const& op = turn.operations[i];
segment_fraction_type seg_frac(op.seg_id, op.fraction);
typename ClusterPerSegment::const_iterator it = cluster_per_segment.find(seg_frac);
if (it != cluster_per_segment.end())
typename ClusterPerSegment::const_iterator cit = cluster_per_segment.find(seg_frac);
if (cit != cluster_per_segment.end())
{
#if defined(BOOST_GEOMETRY_DEBUG_HANDLE_COLOCATIONS)
if (turn.is_clustered()
&& turn.cluster_id != it->second)
&& turn.cluster_id != cit->second)
{
std::cout << " CONFLICT " << std::endl;
}
#endif
turn.cluster_id = it->second;
turn.cluster_id = cit->second;
clusters[turn.cluster_id].turn_indices.insert(turn_index);
}
}
@@ -680,7 +681,7 @@ inline bool handle_colocations(Turns& turns, Clusters& clusters,
// on turns which are discarded afterwards
set_colocation<OverlayType>(turns, clusters);
if (target_operation == operation_intersection)
if (BOOST_GEOMETRY_CONDITION(target_operation == operation_intersection))
{
discard_interior_exterior_turns
<

View File

@@ -1,7 +1,7 @@
// Boost.Geometry (aka GGL, Generic Geometry Library)
// Copyright (c) 2007-2015 Barend Gehrels, Amsterdam, the Netherlands.
// Copyright (c) 2013-2015 Adam Wulkiewicz, Lodz, Poland
// Copyright (c) 2013-2017 Adam Wulkiewicz, Lodz, Poland
// This file was modified by Oracle on 2015, 2017.
// Modifications copyright (c) 2015-2017, Oracle and/or its affiliates.
@@ -49,6 +49,7 @@
#include <boost/geometry/policies/robustness/segment_ratio_type.hpp>
#include <boost/geometry/util/condition.hpp>
#ifdef BOOST_GEOMETRY_DEBUG_ASSEMBLE
# include <boost/geometry/io/dsv/write.hpp>
@@ -88,6 +89,10 @@ struct overlay_null_visitor
template <typename Turns, typename Turn, typename Operation>
void visit_traverse_reject(Turns const& , Turn const& , Operation const& , traverse_error_type )
{}
template <typename Rings>
void visit_generated_rings(Rings const& )
{}
};
template
@@ -135,9 +140,9 @@ inline void get_ring_turn_info(TurnInfoMap& turn_info_map, Turns const& turns, C
if (! is_self_turn<OverlayType>(turn)
&& (
(target_operation == operation_union
(BOOST_GEOMETRY_CONDITION(target_operation == operation_union)
&& op.enriched.count_left > 0)
|| (target_operation == operation_intersection
|| (BOOST_GEOMETRY_CONDITION(target_operation == operation_intersection)
&& op.enriched.count_right <= 2)))
{
// Avoid including untraversed rings which have polygons on
@@ -205,7 +210,7 @@ inline OutputIterator return_if_one_input_is_empty(Geometry1 const& geometry1,
typename Strategy::template area_strategy
<
point_type1
>::type::return_type
>::type::template result_type<point_type1>::type
> properties;
// Silence warning C4127: conditional expression is constant
@@ -362,7 +367,7 @@ std::cout << "traverse" << std::endl;
typedef ring_properties
<
point_type,
typename area_strategy_type::return_type
typename area_strategy_type::template result_type<point_type>::type
> properties;
// Select all rings which are NOT touched by any intersection point

View File

@@ -23,6 +23,7 @@
#include <boost/geometry/algorithms/detail/overlay/turn_info.hpp>
#include <boost/geometry/core/access.hpp>
#include <boost/geometry/core/assert.hpp>
#include <boost/geometry/util/condition.hpp>
#if defined(BOOST_GEOMETRY_DEBUG_INTERSECTION) \
|| defined(BOOST_GEOMETRY_OVERLAY_REPORT_WKT) \
@@ -296,6 +297,51 @@ struct traversal
|| turn.has(operation_continue);
}
inline std::size_t get_shortcut_level(turn_operation_type const& op,
signed_size_type start_turn_index,
signed_size_type origin_turn_index,
std::size_t level = 1) const
{
signed_size_type next_turn_index = op.enriched.get_next_turn_index();
if (next_turn_index == -1)
{
return 0;
}
if (next_turn_index == start_turn_index)
{
// This operation finishes the ring
return 0;
}
if (next_turn_index == origin_turn_index)
{
// This operation travels to itself
return level;
}
if (level > 10)
{
// Avoid infinite recursion
return 0;
}
turn_type const& next_turn = m_turns[next_turn_index];
for (int i = 0; i < 2; i++)
{
turn_operation_type const& next_op = next_turn.operations[i];
if (next_op.operation == target_operation
&& ! next_op.visited.finished()
&& ! next_op.visited.visited())
{
// Recursively continue verifying
if (get_shortcut_level(next_op, start_turn_index,
origin_turn_index, level + 1))
{
return level + 1;
}
}
}
return 0;
}
inline
bool select_cc_operation(turn_type const& turn,
signed_size_type start_turn_index,
@@ -369,12 +415,14 @@ struct traversal
inline
bool select_preferred_operation(turn_type const& turn,
signed_size_type turn_index,
signed_size_type start_turn_index,
int& selected_op_index) const
{
bool option[2] = {0};
bool finishing[2] = {0};
bool preferred[2] = {0};
std::size_t shortcut_level[2] = {0};
for (int i = 0; i < 2; i++)
{
turn_operation_type const& op = turn.operations[i];
@@ -388,6 +436,12 @@ struct traversal
{
finishing[i] = true;
}
else
{
shortcut_level[i] = get_shortcut_level(op, start_turn_index,
turn_index);
}
if (op.enriched.prefer_start)
{
preferred[i] = true;
@@ -405,14 +459,21 @@ struct traversal
if (option[0] && option[1])
{
// Both operations are acceptable
if (finishing[0] != finishing[1])
{
// Only one operation can finish the ring
// Prefer operation finishing the ring
selected_op_index = finishing[0] ? 0 : 1;
return true;
}
if (shortcut_level[0] != shortcut_level[1])
{
// If a turn can travel to itself again (without closing the
// ring), take the shortest one
selected_op_index = shortcut_level[0] < shortcut_level[1] ? 0 : 1;
return true;
}
if (preferred[0] != preferred[1])
{
// Only one operation is preferred (== was not intersection)
@@ -435,6 +496,7 @@ struct traversal
inline
bool select_operation(const turn_type& turn,
signed_size_type turn_index,
signed_size_type start_turn_index,
segment_identifier const& previous_seg_id,
int& selected_op_index) const
@@ -448,8 +510,8 @@ struct traversal
}
else if (OverlayType == overlay_dissolve)
{
result = select_preferred_operation(turn, start_turn_index,
selected_op_index);
result = select_preferred_operation(turn, turn_index,
start_turn_index, selected_op_index);
}
else
{
@@ -842,7 +904,7 @@ struct traversal
{
turn_type const& current_turn = m_turns[turn_index];
if (target_operation == operation_intersection)
if (BOOST_GEOMETRY_CONDITION(target_operation == operation_intersection))
{
bool const back_at_start_cluster
= current_turn.is_clustered()
@@ -890,7 +952,7 @@ struct traversal
return false;
}
if (! select_operation(current_turn,
if (! select_operation(current_turn, turn_index,
start_turn_index,
previous_seg_id,
op_index))

View File

@@ -162,7 +162,7 @@ struct traversal_ring_creator
// Update registration and append point
turn_type& current_turn = m_turns[turn_index];
turn_operation_type& op = current_turn.operations[op_index];
detail::overlay::append_no_dups_or_spikes(current_ring, current_turn.point,
detail::overlay::append_no_collinear(current_ring, current_turn.point,
m_intersection_strategy.get_side_strategy(),
m_robust_policy);
@@ -180,7 +180,7 @@ struct traversal_ring_creator
turn_type const& start_turn = m_turns[start_turn_index];
turn_operation_type& start_op = m_turns[start_turn_index].operations[start_op_index];
detail::overlay::append_no_dups_or_spikes(ring, start_turn.point,
detail::overlay::append_no_collinear(ring, start_turn.point,
m_intersection_strategy.get_side_strategy(),
m_robust_policy);

View File

@@ -20,6 +20,7 @@
#include <boost/geometry/algorithms/detail/overlay/turn_info.hpp>
#include <boost/geometry/core/access.hpp>
#include <boost/geometry/core/assert.hpp>
#include <boost/geometry/util/condition.hpp>
namespace boost { namespace geometry
{
@@ -495,7 +496,7 @@ struct traversal_switch_detector
return ! (turn.both(operation_union) || turn.both(operation_intersection));
}
if (target_operation == operation_union)
if (BOOST_GEOMETRY_CONDITION(target_operation == operation_union))
{
// It is a cluster, check zones
// (assigned by sort_by_side/handle colocations) of both operations
@@ -590,7 +591,8 @@ struct traversal_switch_detector
{
turn_type const& turn = m_turns[turn_index];
if (turn.discarded && target_operation == operation_intersection)
if (turn.discarded
&& BOOST_GEOMETRY_CONDITION(target_operation == operation_intersection))
{
// Discarded turn (union currently still needs it to determine regions)
continue;

View File

@@ -37,8 +37,8 @@ namespace detail
template <typename Point1, typename Point2, typename Point3>
inline bool collinear_point_is_spike_or_equal(Point1 const& last_point,
Point2 const& segment_a,
Point3 const& segment_b)
Point2 const& segment_a,
Point3 const& segment_b)
{
// Check if segment is equal
int const sgn_x1 = sign_of_difference<0>(last_point, segment_b);
@@ -70,10 +70,10 @@ template
typename Point1, typename Point2, typename Point3,
typename SideStrategy
>
static inline bool point_is_spike_or_equal(Point1 const& last_point, // prev | back
Point2 const& segment_a, // next | back - 2
Point3 const& segment_b, // curr | back - 1 | spike's vertex
SideStrategy const& strategy)
inline bool point_is_spike_or_equal(Point1 const& last_point, // prev | back
Point2 const& segment_a, // next | back - 2
Point3 const& segment_b, // curr | back - 1 | spike's vertex
SideStrategy const& strategy)
{
int const side = strategy.apply(segment_a, segment_b, last_point);
if (side == 0)
@@ -100,7 +100,7 @@ template
typename SideStrategy,
typename RobustPolicy
>
static inline bool point_is_spike_or_equal(Point1 const& last_point,
inline bool point_is_spike_or_equal(Point1 const& last_point,
Point2 const& segment_a,
Point3 const& segment_b,
SideStrategy const& strategy,
@@ -137,6 +137,48 @@ static inline bool point_is_spike_or_equal(Point1 const& last_point,
);
}
template
<
typename Point1,
typename Point2,
typename Point3,
typename SideStrategy,
typename RobustPolicy
>
inline bool point_is_collinear(Point1 const& last_point,
Point2 const& segment_a,
Point3 const& segment_b,
SideStrategy const& strategy,
RobustPolicy const& robust_policy)
{
int const side = strategy.apply(segment_a, segment_b, last_point);
if (side == 0)
{
return true;
}
// This part (or whole method, because it is then trivial)
// will be removed after rescaling
if (BOOST_GEOMETRY_CONDITION(! RobustPolicy::enabled))
{
return false;
}
// Redo, using specified robust policy
typedef typename geometry::robust_point_type
<
Point1,
RobustPolicy
>::type robust_point_type;
robust_point_type last_point_rob, segment_a_rob, segment_b_rob;
geometry::recalculate(last_point_rob, last_point, robust_policy);
geometry::recalculate(segment_a_rob, segment_a, robust_policy);
geometry::recalculate(segment_b_rob, segment_b, robust_policy);
int const side_rob = strategy.apply(segment_a_rob, segment_b_rob, last_point_rob);
return side_rob == 0;
}
} // namespace detail
#endif

View File

@@ -51,6 +51,7 @@
#include <boost/geometry/algorithms/detail/multi_sum.hpp>
// #include <boost/geometry/algorithms/detail/throw_on_empty_input.hpp>
#include <boost/geometry/views/closeable_view.hpp>
#include <boost/geometry/strategies/default_strategy.hpp>
#include <boost/geometry/strategies/distance.hpp>
#include <boost/geometry/strategies/default_length_result.hpp>
@@ -184,6 +185,33 @@ struct length<MultiLinestring, multi_linestring_tag> : detail::multi_sum
#endif // DOXYGEN_NO_DISPATCH
namespace resolve_strategy {
struct length
{
template <typename Geometry, typename Strategy>
static inline typename default_length_result<Geometry>::type
apply(Geometry const& geometry, Strategy const& strategy)
{
return dispatch::length<Geometry>::apply(geometry, strategy);
}
template <typename Geometry>
static inline typename default_length_result<Geometry>::type
apply(Geometry const& geometry, default_strategy)
{
typedef typename strategy::distance::services::default_strategy
<
point_tag, point_tag, typename point_type<Geometry>::type
>::type strategy_type;
return dispatch::length<Geometry>::apply(geometry, strategy_type());
}
};
} // namespace resolve_strategy
namespace resolve_variant {
template <typename Geometry>
@@ -193,7 +221,7 @@ struct length
static inline typename default_length_result<Geometry>::type
apply(Geometry const& geometry, Strategy const& strategy)
{
return dispatch::length<Geometry>::apply(geometry, strategy);
return resolve_strategy::length::apply(geometry, strategy);
}
};
@@ -255,13 +283,7 @@ length(Geometry const& geometry)
// detail::throw_on_empty_input(geometry);
// TODO put this into a resolve_strategy stage
typedef typename strategy::distance::services::default_strategy
<
point_tag, point_tag, typename point_type<Geometry>::type
>::type strategy_type;
return resolve_variant::length<Geometry>::apply(geometry, strategy_type());
return resolve_variant::length<Geometry>::apply(geometry, default_strategy());
}

View File

@@ -36,9 +36,13 @@
#include <boost/geometry/strategies/default_strategy.hpp>
#include <boost/geometry/strategies/distance.hpp>
#include <boost/geometry/algorithms/area.hpp>
#include <boost/geometry/algorithms/clear.hpp>
#include <boost/geometry/algorithms/convert.hpp>
#include <boost/geometry/algorithms/detail/equals/point_point.hpp>
#include <boost/geometry/algorithms/not_implemented.hpp>
#include <boost/geometry/algorithms/is_empty.hpp>
#include <boost/geometry/algorithms/perimeter.hpp>
#include <boost/geometry/algorithms/detail/distance/default_strategies.hpp>
@@ -49,6 +53,14 @@ namespace boost { namespace geometry
namespace detail { namespace simplify
{
template <typename Range>
inline bool is_degenerate(Range const& range)
{
return boost::size(range) == 2
&& detail::equals::equals_point_point(geometry::range::front(range),
geometry::range::back(range));
}
struct simplify_range_insert
{
template<typename Range, typename Strategy, typename OutputIterator, typename Distance>
@@ -57,7 +69,11 @@ struct simplify_range_insert
{
boost::ignore_unused(strategy);
if (boost::size(range) <= 2 || max_distance < 0)
if (is_degenerate(range))
{
std::copy(boost::begin(range), boost::begin(range) + 1, out);
}
else if (boost::size(range) <= 2 || max_distance < 0)
{
std::copy(boost::begin(range), boost::end(range), out);
}
@@ -71,41 +87,32 @@ struct simplify_range_insert
struct simplify_copy
{
template <typename Range, typename Strategy, typename Distance>
static inline void apply(Range const& range, Range& out,
template <typename RangeIn, typename RangeOut, typename Strategy, typename Distance>
static inline void apply(RangeIn const& range, RangeOut& out,
Distance const& , Strategy const& )
{
std::copy
(
boost::begin(range), boost::end(range), geometry::range::back_inserter(out)
boost::begin(range), boost::end(range),
geometry::range::back_inserter(out)
);
}
};
template<std::size_t Minimum>
template <std::size_t MinimumToUseStrategy>
struct simplify_range
{
template <typename Range, typename Strategy, typename Distance>
static inline void apply(Range const& range, Range& out,
template <typename RangeIn, typename RangeOut, typename Strategy, typename Distance>
static inline void apply(RangeIn const& range, RangeOut& out,
Distance const& max_distance, Strategy const& strategy)
{
// Call do_container for a linestring / ring
// For a RING:
// Note that, especially if max_distance is too large,
// the output ring might be self intersecting while the input ring is
// not, although chances are low in normal polygons
/* For a RING:
The first/last point (the closing point of the ring) should maybe
be excluded because it lies on a line with second/one but last.
Here it is never excluded.
Note also that, especially if max_distance is too large,
the output ring might be self intersecting while the input ring is
not, although chances are low in normal polygons
Finally the inputring might have 3 (open) or 4 (closed) points (=correct),
the output < 3 or 4(=wrong)
*/
if (boost::size(range) <= int(Minimum) || max_distance < 0.0)
if (boost::size(range) <= MinimumToUseStrategy || max_distance < 0)
{
simplify_copy::apply(range, out, max_distance, strategy);
}
@@ -116,34 +123,172 @@ struct simplify_range
range, geometry::range::back_inserter(out), max_distance, strategy
);
}
// Verify the two remaining points are equal. If so, remove one of them.
// This can cause the output being under the minimum size
if (is_degenerate(out))
{
range::resize(out, 1);
}
}
};
struct simplify_ring
{
private :
template <typename Area>
static inline int area_sign(Area const& area)
{
return area > 0 ? 1 : area < 0 ? -1 : 0;
}
template <typename Strategy, typename Ring>
static std::size_t get_opposite(std::size_t index, Ring const& ring)
{
typename Strategy::distance_strategy_type distance_strategy;
// Verify if it is NOT the case that all points are less than the
// simplifying distance. If so, output is empty.
typename Strategy::distance_type max_distance(-1);
typename geometry::point_type<Ring>::type point = range::at(ring, index);
std::size_t i = 0;
for (typename boost::range_iterator<Ring const>::type
it = boost::begin(ring); it != boost::end(ring); ++it, ++i)
{
// This actually is point-segment distance but will result
// in point-point distance
typename Strategy::distance_type dist = distance_strategy.apply(*it, point, point);
if (dist > max_distance)
{
max_distance = dist;
index = i;
}
}
return index;
}
public :
template <typename Ring, typename Strategy, typename Distance>
static inline void apply(Ring const& ring, Ring& out,
Distance const& max_distance, Strategy const& strategy)
{
std::size_t const size = boost::size(ring);
if (size == 0)
{
return;
}
int const input_sign = area_sign(geometry::area(ring));
std::set<std::size_t> visited_indexes;
// Rotate it into a copied vector
// (vector, because source type might not support rotation)
// (duplicate end point will be simplified away)
typedef typename geometry::point_type<Ring>::type point_type;
std::vector<point_type> rotated(size);
// Closing point (but it will not start here)
std::size_t index = 0;
// Iterate (usually one iteration is enough)
for (std::size_t iteration = 0; iteration < 4u; iteration++)
{
// Always take the opposite. Opposite guarantees that no point
// "halfway" is chosen, creating an artefact (very narrow triangle)
// Iteration 0: opposite to closing point (1/2, = on convex hull)
// (this will start simplification with that point
// and its opposite ~0)
// Iteration 1: move a quarter on that ring, then opposite to 1/4
// (with its opposite 3/4)
// Iteration 2: move an eight on that ring, then opposite (1/8)
// Iteration 3: again move a quarter, then opposite (7/8)
// So finally 8 "sides" of the ring have been examined (if it were
// a semi-circle). Most probably, there are only 0 or 1 iterations.
switch (iteration)
{
case 1 : index = (index + size / 4) % size; break;
case 2 : index = (index + size / 8) % size; break;
case 3 : index = (index + size / 4) % size; break;
}
index = get_opposite<Strategy>(index, ring);
if (visited_indexes.count(index) > 0)
{
// Avoid trying the same starting point more than once
continue;
}
std::rotate_copy(boost::begin(ring), range::pos(ring, index),
boost::end(ring), rotated.begin());
// Close the rotated copy
rotated.push_back(range::at(ring, index));
simplify_range<0>::apply(rotated, out, max_distance, strategy);
// Verify that what was positive, stays positive (or goes to 0)
// and what was negative stays negative (or goes to 0)
int const output_sign = area_sign(geometry::area(out));
if (output_sign == input_sign)
{
// Result is considered as satisfactory (usually this is the
// first iteration - only for small rings, having a scale
// similar to simplify_distance, next iterations are tried
return;
}
// Original is simplified away. Possibly there is a solution
// when another starting point is used
geometry::clear(out);
if (iteration == 0
&& geometry::perimeter(ring) < 3 * max_distance)
{
// Check if it is useful to iterate. A minimal triangle has a
// perimeter of a bit more than 3 times the simplify distance
return;
}
// Prepare next try
visited_indexes.insert(index);
rotated.resize(size);
}
}
};
struct simplify_polygon
{
private:
template
<
std::size_t Minimum,
typename IteratorIn,
typename IteratorOut,
typename InteriorRingsOut,
typename Distance,
typename Strategy
>
static inline void iterate(IteratorIn begin, IteratorIn end,
IteratorOut it_out,
InteriorRingsOut& interior_rings_out,
Distance const& max_distance, Strategy const& strategy)
{
for (IteratorIn it_in = begin; it_in != end; ++it_in, ++it_out)
typedef typename boost::range_value<InteriorRingsOut>::type single_type;
for (IteratorIn it = begin; it != end; ++it)
{
simplify_range<Minimum>::apply(*it_in, *it_out, max_distance, strategy);
single_type out;
simplify_ring::apply(*it, out, max_distance, strategy);
if (! geometry::is_empty(out))
{
range::push_back(interior_rings_out, out);
}
}
}
template
<
std::size_t Minimum,
typename InteriorRingsIn,
typename InteriorRingsOut,
typename Distance,
@@ -154,12 +299,11 @@ private:
InteriorRingsOut& interior_rings_out,
Distance const& max_distance, Strategy const& strategy)
{
traits::resize<InteriorRingsOut>::apply(interior_rings_out,
boost::size(interior_rings_in));
range::clear(interior_rings_out);
iterate<Minimum>(
iterate(
boost::begin(interior_rings_in), boost::end(interior_rings_in),
boost::begin(interior_rings_out),
interior_rings_out,
max_distance, strategy);
}
@@ -168,21 +312,14 @@ public:
static inline void apply(Polygon const& poly_in, Polygon& poly_out,
Distance const& max_distance, Strategy const& strategy)
{
std::size_t const minimum = core_detail::closure::minimum_ring_size
<
geometry::closure<Polygon>::value
>::value;
// Note that if there are inner rings, and distance is too large,
// they might intersect with the outer ring in the output,
// while it didn't in the input.
simplify_range<minimum>::apply(exterior_ring(poly_in),
exterior_ring(poly_out),
max_distance, strategy);
simplify_ring::apply(exterior_ring(poly_in), exterior_ring(poly_out),
max_distance, strategy);
apply_interior_rings<minimum>(interior_rings(poly_in),
interior_rings(poly_out),
max_distance, strategy);
apply_interior_rings(interior_rings(poly_in),
interior_rings(poly_out), max_distance, strategy);
}
};
@@ -194,16 +331,19 @@ struct simplify_multi
static inline void apply(MultiGeometry const& multi, MultiGeometry& out,
Distance const& max_distance, Strategy const& strategy)
{
traits::resize<MultiGeometry>::apply(out, boost::size(multi));
range::clear(out);
typedef typename boost::range_value<MultiGeometry>::type single_type;
typename boost::range_iterator<MultiGeometry>::type it_out
= boost::begin(out);
for (typename boost::range_iterator<MultiGeometry const>::type
it_in = boost::begin(multi);
it_in != boost::end(multi);
++it_in, ++it_out)
it = boost::begin(multi); it != boost::end(multi); ++it)
{
Policy::apply(*it_in, *it_out, max_distance, strategy);
single_type single_out;
Policy::apply(*it, single_out, max_distance, strategy);
if (! geometry::is_empty(single_out))
{
range::push_back(out, single_out);
}
}
}
};
@@ -236,7 +376,7 @@ struct simplify<Point, point_tag>
}
};
// Linestring, keep 2 points (unless those points are the same)
template <typename Linestring>
struct simplify<Linestring, linestring_tag>
: detail::simplify::simplify_range<2>
@@ -244,13 +384,7 @@ struct simplify<Linestring, linestring_tag>
template <typename Ring>
struct simplify<Ring, ring_tag>
: detail::simplify::simplify_range
<
core_detail::closure::minimum_ring_size
<
geometry::closure<Ring>::value
>::value
>
: detail::simplify::simplify_ring
{};
template <typename Polygon>

View File

@@ -223,8 +223,8 @@ template <typename Geometry, std::size_t Dimension>
struct radius_access<srs_sphere_tag, Geometry, Dimension, boost::false_type>
: detail::radius_access<srs_sphere_tag, Geometry, Dimension>
{
BOOST_STATIC_ASSERT(Dimension == 0);
//BOOST_STATIC_ASSERT(Dimension < 3);
//BOOST_STATIC_ASSERT(Dimension == 0);
BOOST_STATIC_ASSERT(Dimension < 3);
};
template <typename Geometry>
@@ -237,8 +237,8 @@ template <typename Geometry, std::size_t Dimension>
struct radius_access<srs_spheroid_tag, Geometry, Dimension, boost::false_type>
: detail::radius_access<srs_spheroid_tag, Geometry, Dimension>
{
BOOST_STATIC_ASSERT(Dimension == 0 || Dimension == 2);
//BOOST_STATIC_ASSERT(Dimension < 3);
//BOOST_STATIC_ASSERT(Dimension == 0 || Dimension == 2);
BOOST_STATIC_ASSERT(Dimension < 3);
};
} // namespace core_dispatch

View File

@@ -17,7 +17,6 @@
#include <boost/math/constants/constants.hpp>
#include <boost/geometry/core/radius.hpp>
#include <boost/geometry/core/srs.hpp>
#include <boost/geometry/util/condition.hpp>
#include <boost/geometry/util/math.hpp>

View File

@@ -14,7 +14,6 @@
#include <boost/math/constants/constants.hpp>
#include <boost/geometry/core/radius.hpp>
#include <boost/geometry/core/srs.hpp>
#include <boost/geometry/util/condition.hpp>
#include <boost/geometry/util/math.hpp>
@@ -46,14 +45,45 @@ public :
bool meridian;
};
template <typename T>
static bool meridian_not_crossing_pole(T lat1, T lat2, CT diff)
{
CT half_pi = math::pi<CT>()/CT(2);
return math::equals(diff, CT(0)) ||
(math::equals(lat2, half_pi) && math::equals(lat1, -half_pi));
}
static bool meridian_crossing_pole(CT diff)
{
return math::equals(math::abs(diff), math::pi<CT>());
}
template <typename T, typename Spheroid>
static CT meridian_not_crossing_pole_dist(T lat1, T lat2, Spheroid const& spheroid)
{
return math::abs(apply(lat2, spheroid) - apply(lat1, spheroid));
}
template <typename T, typename Spheroid>
static CT meridian_crossing_pole_dist(T lat1, T lat2, Spheroid const& spheroid)
{
CT c0 = 0;
CT half_pi = math::pi<CT>()/CT(2);
CT lat_sign = 1;
if (lat1+lat2 < c0)
{
lat_sign = CT(-1);
}
return math::abs(lat_sign * CT(2) * apply(half_pi, spheroid)
- apply(lat1, spheroid) - apply(lat2, spheroid));
}
template <typename T, typename Spheroid>
static result apply(T lon1, T lat1, T lon2, T lat2, Spheroid const& spheroid)
{
result res;
CT c0 = 0;
CT pi = math::pi<CT>();
CT half_pi = pi/CT(2);
CT diff = geometry::math::longitude_distance_signed<geometry::radian>(lon1, lon2);
if (lat1 > lat2)
@@ -61,24 +91,14 @@ public :
std::swap(lat1, lat2);
}
if ( math::equals(diff, c0) ||
(math::equals(lat2, half_pi) && math::equals(lat1, -half_pi)) )
if ( meridian_not_crossing_pole(lat1, lat2, diff) )
{
// single meridian not crossing pole
res.distance = apply(lat2, spheroid) - apply(lat1, spheroid);
res.distance = meridian_not_crossing_pole_dist(lat1, lat2, spheroid);
res.meridian = true;
}
if (math::equals(math::abs(diff), pi))
else if ( meridian_crossing_pole(diff) )
{
// meridian crosses pole
CT lat_sign = 1;
if (lat1+lat2 < c0)
{
lat_sign = CT(-1);
}
res.distance = math::abs(lat_sign * CT(2) * apply(half_pi, spheroid)
- apply(lat1, spheroid) - apply(lat2, spheroid));
res.distance = meridian_crossing_pole_dist(lat1, lat2, spheroid);
res.meridian = true;
}
return res;

View File

@@ -15,7 +15,6 @@
#include <boost/math/constants/constants.hpp>
#include <boost/geometry/core/radius.hpp>
#include <boost/geometry/core/srs.hpp>
#include <boost/geometry/util/condition.hpp>
#include <boost/geometry/util/math.hpp>

View File

@@ -15,7 +15,6 @@
#include <boost/math/constants/constants.hpp>
#include <boost/geometry/core/radius.hpp>
#include <boost/geometry/core/srs.hpp>
#include <boost/geometry/util/condition.hpp>
#include <boost/geometry/util/math.hpp>

View File

@@ -1,6 +1,6 @@
// Boost.Geometry
// Copyright (c) 2015-2016 Oracle and/or its affiliates.
// Copyright (c) 2015-2017 Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
@@ -15,7 +15,6 @@
#include <boost/math/constants/constants.hpp>
#include <boost/geometry/core/radius.hpp>
#include <boost/geometry/core/srs.hpp>
#include <boost/geometry/util/condition.hpp>
#include <boost/geometry/util/math.hpp>

View File

@@ -12,11 +12,13 @@
#ifndef BOOST_GEOMETRY_FORMULAS_MAXIMUM_LATITUDE_HPP
#define BOOST_GEOMETRY_FORMULAS_MAXIMUM_LATITUDE_HPP
#include <boost/geometry/core/srs.hpp>
#include <boost/geometry/formulas/flattening.hpp>
#include <boost/geometry/formulas/spherical.hpp>
#include <boost/mpl/assert.hpp>
namespace boost { namespace geometry { namespace formula
{

View File

@@ -14,7 +14,7 @@
#include <boost/geometry/formulas/spherical.hpp>
#include <boost/geometry/formulas/flattening.hpp>
#include <boost/geometry/core/srs.hpp>
#include <boost/mpl/assert.hpp>
#include <boost/math/special_functions/hypot.hpp>

View File

@@ -2,8 +2,8 @@
// Copyright (c) 2007-2012 Barend Gehrels, Amsterdam, the Netherlands.
// This file was modified by Oracle on 2014, 2016.
// Modifications copyright (c) 2014-2016 Oracle and/or its affiliates.
// This file was modified by Oracle on 2014, 2016, 2017.
// Modifications copyright (c) 2014-2017 Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
@@ -18,7 +18,6 @@
#include <boost/math/constants/constants.hpp>
#include <boost/geometry/core/radius.hpp>
#include <boost/geometry/core/srs.hpp>
#include <boost/geometry/util/condition.hpp>
#include <boost/geometry/util/math.hpp>

View File

@@ -19,7 +19,6 @@
#include <boost/math/constants/constants.hpp>
#include <boost/geometry/core/radius.hpp>
#include <boost/geometry/core/srs.hpp>
#include <boost/geometry/util/condition.hpp>
#include <boost/geometry/util/math.hpp>

View File

@@ -3,7 +3,7 @@
// Copyright (c) 2007-2012 Barend Gehrels, Amsterdam, the Netherlands.
// Copyright (c) 2008-2012 Bruno Lalande, Paris, France.
// Copyright (c) 2009-2012 Mateusz Loskot, London, UK.
// Copyright (c) 2014 Adam Wulkiewicz, Lodz, Poland.
// Copyright (c) 2014-2018 Adam Wulkiewicz, Lodz, Poland.
// Parts of Boost.Geometry are redesigned from Geodan's Geographic Library
// (geolib/GGL), copyright (c) 1995-2010 Geodan, Amsterdam, the Netherlands.
@@ -47,9 +47,9 @@ namespace model
\tparam Closed true for closed polygons (last point == first point),
false open points
\tparam PointList container type for points,
for example std::vector, std::list, std::deque
for example std::vector, std::deque
\tparam RingList container type for inner rings,
for example std::vector, std::list, std::deque
for example std::vector, std::deque
\tparam PointAlloc container-allocator-type, for the points
\tparam RingAlloc container-allocator-type, for the rings
\note The container collecting the points in the rings can be different

View File

@@ -4,8 +4,8 @@
// Copyright (c) 2008-2015 Bruno Lalande, Paris, France.
// Copyright (c) 2009-2015 Mateusz Loskot, London, UK.
// This file was modified by Oracle on 2014, 2015, 2016.
// Modifications copyright (c) 2014-2016 Oracle and/or its affiliates.
// This file was modified by Oracle on 2014-2018.
// Modifications copyright (c) 2014-2018 Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
// Contributed and/or modified by Menelaos Karavelas, on behalf of Oracle
@@ -31,7 +31,6 @@
#include <boost/geometry/core/point_order.hpp>
#include <boost/geometry/core/point_type.hpp>
#include <boost/geometry/core/ring_type.hpp>
#include <boost/geometry/core/srs.hpp>
#include <boost/geometry/core/tag.hpp>
#include <boost/geometry/core/tag_cast.hpp>
#include <boost/geometry/core/tags.hpp>
@@ -61,6 +60,7 @@
#include <boost/geometry/algorithms/correct.hpp>
#include <boost/geometry/algorithms/covered_by.hpp>
#include <boost/geometry/algorithms/crosses.hpp>
#include <boost/geometry/algorithms/densify.hpp>
#include <boost/geometry/algorithms/difference.hpp>
#include <boost/geometry/algorithms/disjoint.hpp>
#include <boost/geometry/algorithms/distance.hpp>
@@ -96,6 +96,8 @@
// check includes all concepts
#include <boost/geometry/geometries/concepts/check.hpp>
#include <boost/geometry/srs/srs.hpp>
#include <boost/geometry/util/for_each_coordinate.hpp>
#include <boost/geometry/util/math.hpp>
#include <boost/geometry/util/select_coordinate_type.hpp>

View File

@@ -52,42 +52,9 @@ struct segments_intersection_points
{
return_type result;
result.count = 1;
sinfo.calculate(result.intersections[0], s1, s2);
bool use_a = true;
// Prefer one segment if one is on or near an endpoint
bool const a_near_end = sinfo.robust_ra.near_end();
bool const b_near_end = sinfo.robust_rb.near_end();
if (a_near_end && ! b_near_end)
{
use_a = true;
}
else if (b_near_end && ! a_near_end)
{
use_a = false;
}
else
{
// Prefer shorter segment
typedef typename SegmentIntersectionInfo::promoted_type ptype;
ptype const len_a = sinfo.comparable_length_a();
ptype const len_b = sinfo.comparable_length_b();
if (len_b < len_a)
{
use_a = false;
}
// else use_a is true but was already assigned like that
}
if (use_a)
{
sinfo.assign_a(result.intersections[0], s1, s2);
}
else
{
sinfo.assign_b(result.intersections[0], s1, s2);
}
// Temporary - this should go later
result.fractions[0].assign(sinfo);
return result;

View File

@@ -0,0 +1,82 @@
// Boost.Geometry
// Copyright (c) 2017, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
#ifndef BOOST_GEOMETRY_SRS_EPSG_HPP
#define BOOST_GEOMETRY_SRS_EPSG_HPP
#include <boost/geometry/srs/projection.hpp>
#include <boost/geometry/srs/projections/epsg.hpp>
#include <boost/geometry/srs/projections/epsg_params.hpp>
#include <boost/geometry/srs/projections/epsg_traits.hpp>
namespace boost { namespace geometry
{
namespace projections
{
template <typename CT>
struct dynamic_parameters<srs::epsg, CT>
{
static inline projections::parameters<CT> apply(srs::epsg const& params)
{
return projections::detail::pj_init_plus<CT>(
srs::dynamic(),
projections::detail::epsg_to_string(params.code),
false);
}
};
template <int Code, typename CT>
class proj_wrapper<srs::static_epsg<Code>, CT>
: public static_proj_wrapper_base
<
typename projections::detail::epsg_traits<Code>::static_parameters_type,
CT
>
{
typedef projections::detail::epsg_traits<Code> epsg_traits;
typedef typename epsg_traits::static_parameters_type static_parameters_type;
typedef static_proj_wrapper_base<static_parameters_type, CT> base_t;
public:
proj_wrapper()
: base_t(epsg_traits::s_par(), epsg_traits::par())
{}
};
} // namespace projections
namespace srs
{
template <int Code, typename CT>
class projection<srs::static_epsg<Code>, CT>
: public projections::projection<srs::static_epsg<Code>, CT>
{
typedef projections::projection<srs::static_epsg<Code>, CT> base_t;
public:
projection()
{}
};
} // namespace srs
}} // namespace boost::geometry
#endif // BOOST_GEOMETRY_SRS_EPSG_HPP

View File

@@ -0,0 +1,82 @@
// Boost.Geometry
// Copyright (c) 2017, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
#ifndef BOOST_GEOMETRY_SRS_ESRI_HPP
#define BOOST_GEOMETRY_SRS_ESRI_HPP
#include <boost/geometry/srs/projection.hpp>
#include <boost/geometry/srs/projections/esri.hpp>
#include <boost/geometry/srs/projections/esri_params.hpp>
#include <boost/geometry/srs/projections/esri_traits.hpp>
namespace boost { namespace geometry
{
namespace projections
{
template <typename CT>
struct dynamic_parameters<srs::esri, CT>
{
static inline projections::parameters<CT> apply(srs::esri const& params)
{
return projections::detail::pj_init_plus<CT>(
srs::dynamic(),
projections::detail::esri_to_string(params.code),
false);
}
};
template <int Code, typename CT>
class proj_wrapper<srs::static_esri<Code>, CT>
: public static_proj_wrapper_base
<
typename projections::detail::esri_traits<Code>::static_parameters_type,
CT
>
{
typedef projections::detail::esri_traits<Code> esri_traits;
typedef typename esri_traits::static_parameters_type static_parameters_type;
typedef static_proj_wrapper_base<static_parameters_type, CT> base_t;
public:
proj_wrapper()
: base_t(esri_traits::s_par(), esri_traits::par())
{}
};
} // namespace projections
namespace srs
{
template <int Code, typename CT>
class projection<srs::static_esri<Code>, CT>
: public projections::projection<srs::static_esri<Code>, CT>
{
typedef projections::projection<srs::static_esri<Code>, CT> base_t;
public:
projection()
{}
};
} // namespace srs
}} // namespace boost::geometry
#endif // BOOST_GEOMETRY_SRS_ESRI_HPP

View File

@@ -0,0 +1,82 @@
// Boost.Geometry
// Copyright (c) 2017, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
#ifndef BOOST_GEOMETRY_SRS_IAU2000_HPP
#define BOOST_GEOMETRY_SRS_IAU2000_HPP
#include <boost/geometry/srs/projection.hpp>
#include <boost/geometry/srs/projections/iau2000.hpp>
#include <boost/geometry/srs/projections/iau2000_params.hpp>
#include <boost/geometry/srs/projections/iau2000_traits.hpp>
namespace boost { namespace geometry
{
namespace projections
{
template <typename CT>
struct dynamic_parameters<srs::iau2000, CT>
{
static inline projections::parameters<CT> apply(srs::iau2000 const& params)
{
return projections::detail::pj_init_plus<CT>(
srs::dynamic(),
projections::detail::iau2000_to_string(params.code),
false);
}
};
template <int Code, typename CT>
class proj_wrapper<srs::static_iau2000<Code>, CT>
: public static_proj_wrapper_base
<
typename projections::detail::iau2000_traits<Code>::static_parameters_type,
CT
>
{
typedef projections::detail::iau2000_traits<Code> iau2000_traits;
typedef typename iau2000_traits::static_parameters_type static_parameters_type;
typedef static_proj_wrapper_base<static_parameters_type, CT> base_t;
public:
proj_wrapper()
: base_t(iau2000_traits::s_par(), iau2000_traits::par())
{}
};
} // namespace projections
namespace srs
{
template <int Code, typename CT>
class projection<srs::static_iau2000<Code>, CT>
: public projections::projection<srs::static_iau2000<Code>, CT>
{
typedef projections::projection<srs::static_iau2000<Code>, CT> base_t;
public:
projection()
{}
};
} // namespace srs
}} // namespace boost::geometry
#endif // BOOST_GEOMETRY_SRS_IAU2000_HPP

View File

@@ -0,0 +1,591 @@
// Boost.Geometry (aka GGL, Generic Geometry Library)
// Copyright (c) 2008-2012 Barend Gehrels, Amsterdam, the Netherlands.
// This file was modified by Oracle on 2017.
// Modifications copyright (c) 2017, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
#ifndef BOOST_GEOMETRY_SRS_PROJECTION_HPP
#define BOOST_GEOMETRY_SRS_PROJECTION_HPP
#include <string>
#include <boost/geometry/algorithms/convert.hpp>
#include <boost/geometry/algorithms/detail/convert_point_to_point.hpp>
#include <boost/geometry/core/coordinate_dimension.hpp>
#include <boost/geometry/srs/projections/exception.hpp>
#include <boost/geometry/srs/projections/factory.hpp>
#include <boost/geometry/srs/projections/impl/base_dynamic.hpp>
#include <boost/geometry/srs/projections/impl/base_static.hpp>
#include <boost/geometry/srs/projections/impl/pj_init.hpp>
#include <boost/geometry/srs/projections/invalid_point.hpp>
#include <boost/geometry/srs/projections/par4.hpp>
#include <boost/geometry/srs/projections/proj4.hpp>
#include <boost/geometry/views/detail/indexed_point_view.hpp>
#include <boost/mpl/assert.hpp>
#include <boost/mpl/if.hpp>
#include <boost/smart_ptr/shared_ptr.hpp>
#include <boost/throw_exception.hpp>
#include <boost/type_traits/is_integral.hpp>
#include <boost/type_traits/is_same.hpp>
namespace boost { namespace geometry
{
namespace projections
{
#ifndef DOXYGEN_NO_DETAIL
namespace detail
{
template <typename G1, typename G2>
struct same_tags
{
static const bool value = boost::is_same
<
typename geometry::tag<G1>::type,
typename geometry::tag<G2>::type
>::value;
};
template <typename CT>
struct promote_to_double
{
typedef typename boost::mpl::if_c
<
boost::is_integral<CT>::value || boost::is_same<CT, float>::value,
double, CT
>::type type;
};
// Copy coordinates of dimensions >= MinDim
template <std::size_t MinDim, typename Point1, typename Point2>
inline void copy_higher_dimensions(Point1 const& point1, Point2 & point2)
{
static const std::size_t dim1 = geometry::dimension<Point1>::value;
static const std::size_t dim2 = geometry::dimension<Point2>::value;
static const std::size_t lesser_dim = dim1 < dim2 ? dim1 : dim2;
BOOST_MPL_ASSERT_MSG((lesser_dim >= MinDim),
THE_DIMENSION_OF_POINTS_IS_TOO_SMALL,
(Point1, Point2));
geometry::detail::conversion::point_to_point
<
Point1, Point2, MinDim, lesser_dim
> ::apply(point1, point2);
// TODO: fill point2 with zeros if dim1 < dim2 ?
// currently no need because equal dimensions are checked
}
struct forward_point_projection_policy
{
template <typename LL, typename XY, typename Proj>
static inline bool apply(LL const& ll, XY & xy, Proj const& proj)
{
return proj.forward(ll, xy);
}
};
struct inverse_point_projection_policy
{
template <typename XY, typename LL, typename Proj>
static inline bool apply(XY const& xy, LL & ll, Proj const& proj)
{
return proj.inverse(xy, ll);
}
};
template <typename PointPolicy>
struct project_point
{
template <typename P1, typename P2, typename Proj>
static inline bool apply(P1 const& p1, P2 & p2, Proj const& proj)
{
// (Geographic -> Cartesian) will be projected, rest will be copied.
// So first copy third or higher dimensions
projections::detail::copy_higher_dimensions<2>(p1, p2);
if (! PointPolicy::apply(p1, p2, proj))
{
// For consistency with transformation
set_invalid_point(p2);
return false;
}
return true;
}
};
template <typename PointPolicy>
struct project_range
{
template <typename Proj>
struct convert_policy
{
explicit convert_policy(Proj const& proj)
: m_proj(proj)
, m_result(true)
{}
template <typename Point1, typename Point2>
inline void apply(Point1 const& point1, Point2 & point2)
{
if (! project_point<PointPolicy>::apply(point1, point2, m_proj) )
m_result = false;
}
bool result() const
{
return m_result;
}
private:
Proj const& m_proj;
bool m_result;
};
template <typename R1, typename R2, typename Proj>
static inline bool apply(R1 const& r1, R2 & r2, Proj const& proj)
{
return geometry::detail::conversion::range_to_range
<
R1, R2,
geometry::point_order<R1>::value != geometry::point_order<R2>::value
>::apply(r1, r2, convert_policy<Proj>(proj)).result();
}
};
template <typename Policy>
struct project_multi
{
template <typename G1, typename G2, typename Proj>
static inline bool apply(G1 const& g1, G2 & g2, Proj const& proj)
{
range::resize(g2, boost::size(g1));
return apply(boost::begin(g1), boost::end(g1),
boost::begin(g2),
proj);
}
private:
template <typename It1, typename It2, typename Proj>
static inline bool apply(It1 g1_first, It1 g1_last, It2 g2_first, Proj const& proj)
{
bool result = true;
for ( ; g1_first != g1_last ; ++g1_first, ++g2_first )
{
if (! Policy::apply(*g1_first, *g2_first, proj))
{
result = false;
}
}
return result;
}
};
template
<
typename Geometry,
typename PointPolicy,
typename Tag = typename geometry::tag<Geometry>::type
>
struct project_geometry
{};
template <typename Geometry, typename PointPolicy>
struct project_geometry<Geometry, PointPolicy, point_tag>
: project_point<PointPolicy>
{};
template <typename Geometry, typename PointPolicy>
struct project_geometry<Geometry, PointPolicy, multi_point_tag>
: project_range<PointPolicy>
{};
template <typename Geometry, typename PointPolicy>
struct project_geometry<Geometry, PointPolicy, segment_tag>
{
template <typename G1, typename G2, typename Proj>
static inline bool apply(G1 const& g1, G2 & g2, Proj const& proj)
{
bool r1 = apply<0>(g1, g2, proj);
bool r2 = apply<1>(g1, g2, proj);
return r1 && r2;
}
private:
template <std::size_t Index, typename G1, typename G2, typename Proj>
static inline bool apply(G1 const& g1, G2 & g2, Proj const& proj)
{
geometry::detail::indexed_point_view<G1 const, Index> pt1(g1);
geometry::detail::indexed_point_view<G2, Index> pt2(g2);
return project_point<PointPolicy>::apply(pt1, pt2, proj);
}
};
template <typename Geometry, typename PointPolicy>
struct project_geometry<Geometry, PointPolicy, linestring_tag>
: project_range<PointPolicy>
{};
template <typename Geometry, typename PointPolicy>
struct project_geometry<Geometry, PointPolicy, multi_linestring_tag>
: project_multi< project_range<PointPolicy> >
{};
template <typename Geometry, typename PointPolicy>
struct project_geometry<Geometry, PointPolicy, ring_tag>
: project_range<PointPolicy>
{};
template <typename Geometry, typename PointPolicy>
struct project_geometry<Geometry, PointPolicy, polygon_tag>
{
template <typename G1, typename G2, typename Proj>
static inline bool apply(G1 const& g1, G2 & g2, Proj const& proj)
{
bool r1 = project_range
<
PointPolicy
>::apply(geometry::exterior_ring(g1),
geometry::exterior_ring(g2),
proj);
bool r2 = project_multi
<
project_range<PointPolicy>
>::apply(geometry::interior_rings(g1),
geometry::interior_rings(g2),
proj);
return r1 && r2;
}
};
template <typename MultiPolygon, typename PointPolicy>
struct project_geometry<MultiPolygon, PointPolicy, multi_polygon_tag>
: project_multi
<
project_geometry
<
typename boost::range_value<MultiPolygon>::type,
PointPolicy,
polygon_tag
>
>
{};
} // namespace detail
#endif // DOXYGEN_NO_DETAIL
template <typename Params, typename CT>
struct dynamic_parameters
{
BOOST_MPL_ASSERT_MSG((false),
NOT_IMPLEMENTED_FOR_THESE_PARAMETERS,
(Params));
};
template <typename CT>
struct dynamic_parameters<srs::proj4, CT>
{
static inline projections::parameters<CT> apply(srs::proj4 const& params)
{
return projections::detail::pj_init_plus<CT>(srs::dynamic(), params.str);
}
};
// proj_wrapper class and its specializations wrapps the internal projection
// representation and implements transparent creation of projection object
template <typename Proj, typename CT>
class proj_wrapper
{
BOOST_MPL_ASSERT_MSG((false),
NOT_IMPLEMENTED_FOR_THIS_PROJECTION,
(Proj));
};
template <typename CT>
class proj_wrapper<srs::dynamic, CT>
{
// Some projections do not work with float -> wrong results
// select <double> from int/float/double and else selects T
typedef typename projections::detail::promote_to_double<CT>::type calc_t;
typedef projections::parameters<calc_t> parameters_type;
typedef projections::detail::base_v<calc_t, parameters_type> vprj_t;
public:
template <typename Params>
proj_wrapper(Params const& params)
: m_ptr(create(projections::dynamic_parameters<Params, calc_t>::apply(params)))
{}
vprj_t const& proj() const { return *m_ptr; }
vprj_t & mutable_proj() { return *m_ptr; }
private:
static vprj_t* create(parameters_type const& pj_params)
{
vprj_t* result = projections::detail::create_new(pj_params);
if (result == NULL)
{
if (pj_params.name.empty())
{
BOOST_THROW_EXCEPTION(projection_not_named_exception());
}
else
{
BOOST_THROW_EXCEPTION(projection_unknown_id_exception(pj_params.name));
}
}
return result;
}
boost::shared_ptr<vprj_t> m_ptr;
};
template <typename StaticParameters, typename CT>
class static_proj_wrapper_base
{
typedef typename projections::detail::promote_to_double<CT>::type calc_t;
typedef projections::parameters<calc_t> parameters_type;
typedef typename srs::par4::detail::pick_proj_tag
<
StaticParameters
>::type proj_tag;
typedef typename srs::par4::detail::pick_ellps
<
StaticParameters
>::type ellps_type;
typedef typename projections::detail::static_projection_type
<
proj_tag,
typename geometry::tag
<
typename srs::par4::detail::ellps_traits
<
ellps_type
>::model_type
>::type,
StaticParameters,
calc_t,
parameters_type
>::type projection_type;
public:
projection_type const& proj() const { return m_proj; }
projection_type & mutable_proj() { return m_proj; }
protected:
explicit static_proj_wrapper_base(StaticParameters const& s_params,
bool use_defaults = true)
: m_proj(get_parameters(s_params, "", use_defaults))
{}
static_proj_wrapper_base(StaticParameters const& s_params,
srs::proj4 const& params,
bool use_defaults = true)
: m_proj(get_parameters(s_params, params.str, use_defaults))
{}
private:
static parameters_type get_parameters(StaticParameters const& s_params,
std::string const& params_str,
bool use_defaults)
{
return projections::detail::pj_init_plus<calc_t>(s_params, params_str, use_defaults);
}
projection_type m_proj;
};
template <BOOST_GEOMETRY_PROJECTIONS_DETAIL_TYPENAME_PX, typename CT>
class proj_wrapper<srs::static_proj4<BOOST_GEOMETRY_PROJECTIONS_DETAIL_PX>, CT>
: public static_proj_wrapper_base<srs::static_proj4<BOOST_GEOMETRY_PROJECTIONS_DETAIL_PX>, CT>
{
typedef srs::static_proj4<BOOST_GEOMETRY_PROJECTIONS_DETAIL_PX>
static_parameters_type;
typedef static_proj_wrapper_base
<
static_parameters_type,
CT
> base_t;
public:
proj_wrapper()
: base_t(static_parameters_type())
{}
proj_wrapper(static_parameters_type const& s_params)
: base_t(s_params)
{}
proj_wrapper(srs::proj4 const& params)
: base_t(static_parameters_type(), params)
{}
proj_wrapper(static_parameters_type const& s_params,
srs::proj4 const& params)
: base_t(s_params, params)
{}
};
// projection class implements transparent forward/inverse projection interface
template <typename Proj, typename CT>
class projection
: private proj_wrapper<Proj, CT>
{
typedef proj_wrapper<Proj, CT> base_t;
public:
projection()
{}
template <typename Params>
explicit projection(Params const& params)
: base_t(params)
{}
template <typename SParams, typename Params>
projection(SParams const& s_params, Params const& params)
: base_t(s_params, params)
{}
/// Forward projection, from Latitude-Longitude to Cartesian
template <typename LL, typename XY>
inline bool forward(LL const& ll, XY& xy) const
{
BOOST_MPL_ASSERT_MSG((projections::detail::same_tags<LL, XY>::value),
NOT_SUPPORTED_COMBINATION_OF_GEOMETRIES,
(LL, XY));
concepts::check_concepts_and_equal_dimensions<LL const, XY>();
return projections::detail::project_geometry
<
LL,
projections::detail::forward_point_projection_policy
>::apply(ll, xy, base_t::proj());
}
/// Inverse projection, from Cartesian to Latitude-Longitude
template <typename XY, typename LL>
inline bool inverse(XY const& xy, LL& ll) const
{
BOOST_MPL_ASSERT_MSG((projections::detail::same_tags<XY, LL>::value),
NOT_SUPPORTED_COMBINATION_OF_GEOMETRIES,
(XY, LL));
concepts::check_concepts_and_equal_dimensions<XY const, LL>();
return projections::detail::project_geometry
<
XY,
projections::detail::inverse_point_projection_policy
>::apply(xy, ll, base_t::proj());
}
};
} // namespace projections
namespace srs
{
/*!
\brief Representation of projection
\details Either dynamic or static projection representation
\ingroup projection
\tparam Proj default_dynamic or static projection parameters
\tparam CT calculation type used internally
*/
template
<
typename Proj = srs::dynamic,
typename CT = double
>
class projection
{
BOOST_MPL_ASSERT_MSG((false),
NOT_IMPLEMENTED_FOR_THIS_PROJECTION,
(Proj));
};
template <typename CT>
class projection<srs::dynamic, CT>
: public projections::projection<srs::dynamic, CT>
{
typedef projections::projection<srs::dynamic, CT> base_t;
public:
/*!
\ingroup projection
\brief Initializes a projection as a string, using the format with + and =
\details The projection can be initialized with a string (with the same format as the PROJ4 package) for
convenient initialization from, for example, the command line
\par Example
<tt>+proj=labrd +ellps=intl +lon_0=46d26'13.95E +lat_0=18d54S +azi=18d54 +k_0=.9995 +x_0=400000 +y_0=800000</tt>
for the Madagascar projection.
\note Parameters are described in the group
*/
template <typename Params>
projection(Params const& params)
: base_t(params)
{}
};
template <BOOST_GEOMETRY_PROJECTIONS_DETAIL_TYPENAME_PX, typename CT>
class projection<srs::static_proj4<BOOST_GEOMETRY_PROJECTIONS_DETAIL_PX>, CT>
: public projections::projection<srs::static_proj4<BOOST_GEOMETRY_PROJECTIONS_DETAIL_PX>, CT>
{
typedef projections::projection<srs::static_proj4<BOOST_GEOMETRY_PROJECTIONS_DETAIL_PX>, CT> base_t;
public:
projection()
{}
projection(srs::static_proj4<BOOST_GEOMETRY_PROJECTIONS_DETAIL_PX> const& params)
: base_t(params)
{}
#ifdef BOOST_GEOMETRY_SRS_ENABLE_STATIC_PROJECTION_HYBRID_INTERFACE
projection(srs::proj4 const& params)
: base_t(params)
{}
projection(srs::static_proj4<BOOST_GEOMETRY_PROJECTIONS_DETAIL_PX> const& s_params,
srs::proj4 const& params)
: base_t(s_params, params)
{}
#endif
};
} // namespace srs
}} // namespace boost::geometry
#endif // BOOST_GEOMETRY_SRS_PROJECTION_HPP

View File

@@ -0,0 +1,56 @@
// Boost.Geometry
// Copyright (c) 2017, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
#ifndef BOOST_GEOMETRY_PROJECTIONS_CODE_HPP
#define BOOST_GEOMETRY_PROJECTIONS_CODE_HPP
#include <algorithm>
#include <string>
namespace boost { namespace geometry { namespace projections
{
#ifndef DOXYGEN_NO_DETAIL
namespace detail
{
struct code_element
{
int code;
std::string proj4_str;
};
struct code_element_less
{
inline bool operator()(code_element const& l, code_element const& r) const
{
return l.code < r.code;
}
};
template<typename RandIt>
inline RandIt binary_find_code_element(RandIt first, RandIt last, int code)
{
code_element_less comp;
code_element value;
value.code = code;
first = std::lower_bound(first, last, value, code_element_less());
return first != last && !comp(value, *first) ? first : last;
}
}
#endif // DOXYGEN_NO_DETAIL
}}} // namespace boost::geometry::projections
#endif

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,48 @@
// Boost.Geometry
// Copyright (c) 2017, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
#ifndef BOOST_GEOMETRY_SRS_PROJECTIONS_EPSG_PARAMS_HPP
#define BOOST_GEOMETRY_SRS_PROJECTIONS_EPSG_PARAMS_HPP
#include <string>
#include <boost/geometry/srs/spheroid.hpp>
namespace boost { namespace geometry
{
namespace srs
{
struct epsg
{
explicit epsg(int c)
: code(c)
{}
int code;
};
template <int Code>
struct static_epsg
{
static const int code = Code;
};
} // namespace srs
}} // namespace boost::geometry
#endif // BOOST_GEOMETRY_SRS_PROJECTIONS_EPSG_PARAMS_HPP

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,491 @@
// Boost.Geometry
// Copyright (c) 2017, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
#ifndef BOOST_GEOMETRY_PROJECTIONS_ESRI_HPP
#define BOOST_GEOMETRY_PROJECTIONS_ESRI_HPP
#include <boost/geometry/srs/projections/code.hpp>
namespace boost { namespace geometry { namespace projections
{
#ifndef DOXYGEN_NO_DETAIL
namespace detail
{
inline std::string esri_to_string(int code)
{
static const code_element arr[] = {
{37001, "+proj=longlat +ellps=WGS66 +no_defs"},
{37002, "+proj=longlat +a=6378166 +b=6356784.283607107 +no_defs"},
{37003, "+proj=longlat +a=6378150 +b=6356768.337244385 +no_defs"},
{37004, "+proj=longlat +ellps=fschr60m +no_defs"},
{37005, "+proj=longlat +a=6378270 +b=6356794.343434343 +no_defs"},
{37006, "+proj=longlat +a=6377295.664 +b=6356094.667915204 +no_defs"},
{37007, "+proj=longlat +a=6376896 +b=6355834.846687363 +no_defs"},
{37008, "+proj=longlat +a=6370997 +b=6370997 +no_defs"},
{37201, "+proj=longlat +ellps=intl +no_defs"},
{37202, "+proj=longlat +a=6377276.345 +b=6356075.41314024 +no_defs"},
{37203, "+proj=longlat +a=6377301.243 +b=6356100.230165384 +no_defs"},
{37204, "+proj=longlat +ellps=intl +no_defs"},
{37205, "+proj=longlat +ellps=intl +no_defs"},
{37206, "+proj=longlat +ellps=clrk80 +no_defs"},
{37207, "+proj=longlat +ellps=fschr60m +no_defs"},
{37208, "+proj=longlat +ellps=clrk80 +no_defs"},
{37211, "+proj=longlat +ellps=clrk80 +no_defs"},
{37212, "+proj=longlat +ellps=intl +no_defs"},
{37213, "+proj=longlat +ellps=intl +no_defs"},
{37214, "+proj=longlat +ellps=intl +no_defs"},
{37215, "+proj=longlat +ellps=intl +no_defs"},
{37216, "+proj=longlat +ellps=intl +no_defs"},
{37217, "+proj=longlat +ellps=intl +no_defs"},
{37218, "+proj=longlat +ellps=intl +no_defs"},
{37219, "+proj=longlat +ellps=intl +no_defs"},
{37220, "+proj=longlat +ellps=clrk66 +no_defs"},
{37221, "+proj=longlat +ellps=intl +no_defs"},
{37222, "+proj=longlat +ellps=intl +no_defs"},
{37223, "+proj=longlat +a=6378249.2 +b=6356514.999904194 +no_defs"},
{37224, "+proj=longlat +ellps=intl +no_defs"},
{37226, "+proj=longlat +ellps=intl +no_defs"},
{37227, "+proj=longlat +ellps=intl +no_defs"},
{37228, "+proj=longlat +ellps=clrk80 +no_defs"},
{37229, "+proj=longlat +a=6378270 +b=6356794.343434343 +no_defs"},
{37230, "+proj=longlat +ellps=intl +no_defs"},
{37231, "+proj=longlat +ellps=aust_SA +no_defs"},
{37232, "+proj=longlat +ellps=intl +no_defs"},
{37233, "+proj=longlat +ellps=intl +no_defs"},
{37234, "+proj=longlat +ellps=intl +no_defs"},
{37235, "+proj=longlat +ellps=intl +no_defs"},
{37237, "+proj=longlat +ellps=intl +no_defs"},
{37238, "+proj=longlat +ellps=intl +no_defs"},
{37239, "+proj=longlat +ellps=clrk66 +no_defs"},
{37240, "+proj=longlat +ellps=clrk80 +no_defs"},
{37241, "+proj=longlat +ellps=intl +no_defs"},
{37242, "+proj=longlat +ellps=intl +no_defs"},
{37243, "+proj=longlat +ellps=clrk66 +no_defs"},
{37245, "+proj=longlat +ellps=intl +no_defs"},
{37246, "+proj=longlat +ellps=intl +no_defs"},
{37247, "+proj=longlat +ellps=intl +no_defs"},
{37249, "+proj=longlat +ellps=intl +no_defs"},
{37250, "+proj=longlat +ellps=intl +no_defs"},
{37251, "+proj=longlat +ellps=intl +no_defs"},
{37252, "+proj=longlat +ellps=clrk66 +no_defs"},
{37253, "+proj=longlat +ellps=intl +no_defs"},
{37254, "+proj=longlat +ellps=clrk80 +no_defs"},
{37255, "+proj=longlat +ellps=bessel +no_defs"},
{37257, "+proj=longlat +ellps=krass +no_defs"},
{37259, "+proj=longlat +ellps=intl +no_defs"},
{37260, "+proj=longlat +ellps=clrk66 +no_defs"},
//{53001, ""},
{53002, "+proj=eqc +lat_ts=60 +lat_0=0 +lon_0=0 +x_0=0 +y_0=0 +a=6371000 +b=6371000 +units=m +no_defs"},
{53003, "+proj=mill +lat_0=0 +lon_0=0 +x_0=0 +y_0=0 +R_A +a=6371000 +b=6371000 +units=m +no_defs"},
{53004, "+proj=merc +lon_0=0 +k=1 +x_0=0 +y_0=0 +a=6371000 +b=6371000 +units=m +no_defs"},
{53008, "+proj=sinu +lon_0=0 +x_0=0 +y_0=0 +a=6371000 +b=6371000 +units=m +no_defs"},
{53009, "+proj=moll +lon_0=0 +x_0=0 +y_0=0 +a=6371000 +b=6371000 +units=m +no_defs"},
{53010, "+proj=eck6 +lon_0=0 +x_0=0 +y_0=0 +a=6371000 +b=6371000 +units=m +no_defs"},
//{53011, ""},
{53012, "+proj=eck4 +lon_0=0 +x_0=0 +y_0=0 +a=6371000 +b=6371000 +units=m +no_defs"},
//{53013, ""},
//{53014, ""},
//{53015, ""},
{53016, "+proj=gall +lon_0=0 +x_0=0 +y_0=0 +a=6371000 +b=6371000 +units=m +no_defs"},
//{53017, ""},
//{53018, ""},
//{53019, ""},
{53021, "+proj=poly +lat_0=0 +lon_0=0 +x_0=0 +y_0=0 +a=6371000 +b=6371000 +units=m +no_defs"},
//{53022, ""},
//{53023, ""},
{53024, "+proj=bonne +lon_0=0 +lat_1=60 +x_0=0 +y_0=0 +a=6371000 +b=6371000 +units=m +no_defs"},
{53025, "+proj=omerc +lat_0=40 +lon_1=0 +lat_1=0 +lon_2=0 +lat_2=0 +k=1 +x_0=0 +y_0=0 +a=6371000 +b=6371000 +units=m +no_defs"},
{53026, "+proj=stere +lat_0=0 +lon_0=0 +k=1 +x_0=0 +y_0=0 +a=6371000 +b=6371000 +units=m +no_defs"},
{53027, "+proj=eqdc +lat_0=0 +lon_0=0 +lat_1=60 +lat_2=60 +x_0=0 +y_0=0 +a=6371000 +b=6371000 +units=m +no_defs"},
{53028, "+proj=cass +lat_0=0 +lon_0=0 +x_0=0 +y_0=0 +a=6371000 +b=6371000 +units=m +no_defs"},
{53029, "+proj=vandg +lon_0=0 +x_0=0 +y_0=0 +R_A +a=6371000 +b=6371000 +units=m +no_defs"},
{53030, "+proj=robin +lon_0=0 +x_0=0 +y_0=0 +a=6371000 +b=6371000 +units=m +no_defs"},
{53031, "+proj=tpeqd +lat_1=0 +lon_1=0 +lat_2=60 +lon_2=60 +x_0=0 +y_0=0 +a=6371000 +b=6371000 +units=m +no_defs"},
{53032, "+proj=aeqd +lat_0=0 +lon_0=0 +x_0=0 +y_0=0 +a=6371000 +b=6371000 +units=m +no_defs"},
//{54001, ""},
{54002, "+proj=eqc +lat_ts=60 +lat_0=0 +lon_0=0 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs"},
{54003, "+proj=mill +lat_0=0 +lon_0=0 +x_0=0 +y_0=0 +R_A +ellps=WGS84 +datum=WGS84 +units=m +no_defs"},
{54004, "+proj=merc +lon_0=0 +k=1 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs"},
{54008, "+proj=sinu +lon_0=0 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs"},
{54009, "+proj=moll +lon_0=0 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs"},
{54010, "+proj=eck6 +lon_0=0 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs"},
//{54011, ""},
{54012, "+proj=eck4 +lon_0=0 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs"},
//{54013, ""},
//{54014, ""},
//{54015, ""},
{54016, "+proj=gall +lon_0=0 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs"},
//{54017, ""},
//{54018, ""},
//{54019, ""},
{54021, "+proj=poly +lat_0=0 +lon_0=0 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs"},
//{54022, ""},
//{54023, ""},
{54024, "+proj=bonne +lon_0=0 +lat_1=60 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs"},
{54025, "+proj=omerc +lat_0=40 +lon_1=0 +lat_1=0 +lon_2=0 +lat_2=0 +k=1 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs"},
{54026, "+proj=stere +lat_0=0 +lon_0=0 +k=1 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs"},
{54027, "+proj=eqdc +lat_0=0 +lon_0=0 +lat_1=60 +lat_2=60 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs"},
{54028, "+proj=cass +lat_0=0 +lon_0=0 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs"},
{54029, "+proj=vandg +lon_0=0 +x_0=0 +y_0=0 +R_A +ellps=WGS84 +datum=WGS84 +units=m +no_defs"},
{54030, "+proj=robin +lon_0=0 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs"},
{54031, "+proj=tpeqd +lat_1=0 +lon_1=0 +lat_2=60 +lon_2=60 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs"},
{54032, "+proj=aeqd +lat_0=0 +lon_0=0 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs"},
{65061, "+proj=poly +lat_0=13.47246635277778 +lon_0=-144.7487507055556 +x_0=50000.00000000001 +y_0=50000.00000000001 +ellps=clrk66 +datum=NAD27 +to_meter=0.3048006096012192 +no_defs"},
{65161, "+proj=poly +lat_0=13.47246635277778 +lon_0=-144.7487507055556 +x_0=50000 +y_0=50000 +ellps=GRS80 +datum=NAD83 +units=m +no_defs"},
{102001, "+proj=aea +lat_1=50 +lat_2=70 +lat_0=40 +lon_0=-96 +x_0=0 +y_0=0 +ellps=GRS80 +datum=NAD83 +units=m +no_defs"},
{102002, "+proj=lcc +lat_1=50 +lat_2=70 +lat_0=40 +lon_0=-96 +x_0=0 +y_0=0 +ellps=GRS80 +datum=NAD83 +units=m +no_defs"},
{102003, "+proj=aea +lat_1=29.5 +lat_2=45.5 +lat_0=37.5 +lon_0=-96 +x_0=0 +y_0=0 +ellps=GRS80 +datum=NAD83 +units=m +no_defs"},
{102004, "+proj=lcc +lat_1=33 +lat_2=45 +lat_0=39 +lon_0=-96 +x_0=0 +y_0=0 +ellps=GRS80 +datum=NAD83 +units=m +no_defs"},
{102005, "+proj=eqdc +lat_0=0 +lon_0=0 +lat_1=33 +lat_2=45 +x_0=0 +y_0=0 +ellps=GRS80 +datum=NAD83 +units=m +no_defs"},
{102006, "+proj=aea +lat_1=55 +lat_2=65 +lat_0=50 +lon_0=-154 +x_0=0 +y_0=0 +ellps=GRS80 +datum=NAD83 +units=m +no_defs"},
{102007, "+proj=aea +lat_1=8 +lat_2=18 +lat_0=13 +lon_0=-157 +x_0=0 +y_0=0 +ellps=GRS80 +datum=NAD83 +units=m +no_defs"},
{102008, "+proj=aea +lat_1=20 +lat_2=60 +lat_0=40 +lon_0=-96 +x_0=0 +y_0=0 +ellps=GRS80 +datum=NAD83 +units=m +no_defs"},
{102009, "+proj=lcc +lat_1=20 +lat_2=60 +lat_0=40 +lon_0=-96 +x_0=0 +y_0=0 +ellps=GRS80 +datum=NAD83 +units=m +no_defs"},
{102010, "+proj=eqdc +lat_0=0 +lon_0=0 +lat_1=20 +lat_2=60 +x_0=0 +y_0=0 +ellps=GRS80 +datum=NAD83 +units=m +no_defs"},
{102011, "+proj=sinu +lon_0=0 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs"},
{102012, "+proj=lcc +lat_1=30 +lat_2=62 +lat_0=0 +lon_0=105 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs"},
{102013, "+proj=aea +lat_1=43 +lat_2=62 +lat_0=30 +lon_0=10 +x_0=0 +y_0=0 +ellps=intl +units=m +no_defs"},
{102014, "+proj=lcc +lat_1=43 +lat_2=62 +lat_0=30 +lon_0=10 +x_0=0 +y_0=0 +ellps=intl +units=m +no_defs"},
{102015, "+proj=lcc +lat_1=-5 +lat_2=-42 +lat_0=-32 +lon_0=-60 +x_0=0 +y_0=0 +ellps=aust_SA +units=m +no_defs"},
{102016, "+proj=aeqd +lat_0=90 +lon_0=0 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs"},
{102017, "+proj=laea +lat_0=90 +lon_0=0 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs"},
{102018, "+proj=stere +lat_0=90 +lon_0=0 +k=1 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs"},
{102019, "+proj=aeqd +lat_0=-90 +lon_0=0 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs"},
{102020, "+proj=laea +lat_0=-90 +lon_0=0 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs"},
{102021, "+proj=stere +lat_0=-90 +lon_0=0 +k=1 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs"},
{102022, "+proj=aea +lat_1=20 +lat_2=-23 +lat_0=0 +lon_0=25 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs"},
{102023, "+proj=eqdc +lat_0=0 +lon_0=0 +lat_1=20 +lat_2=-23 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs"},
{102024, "+proj=lcc +lat_1=20 +lat_2=-23 +lat_0=0 +lon_0=25 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs"},
{102025, "+proj=aea +lat_1=15 +lat_2=65 +lat_0=30 +lon_0=95 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs"},
{102026, "+proj=eqdc +lat_0=0 +lon_0=0 +lat_1=15 +lat_2=65 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs"},
{102027, "+proj=lcc +lat_1=15 +lat_2=65 +lat_0=30 +lon_0=95 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs"},
{102028, "+proj=aea +lat_1=7 +lat_2=-32 +lat_0=-15 +lon_0=125 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs"},
{102029, "+proj=eqdc +lat_0=0 +lon_0=0 +lat_1=7 +lat_2=-32 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs"},
{102030, "+proj=lcc +lat_1=7 +lat_2=-32 +lat_0=-15 +lon_0=125 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs"},
{102031, "+proj=eqdc +lat_0=0 +lon_0=0 +lat_1=43 +lat_2=62 +x_0=0 +y_0=0 +ellps=intl +units=m +no_defs"},
{102032, "+proj=eqdc +lat_0=0 +lon_0=0 +lat_1=-5 +lat_2=-42 +x_0=0 +y_0=0 +ellps=aust_SA +units=m +no_defs"},
{102033, "+proj=aea +lat_1=-5 +lat_2=-42 +lat_0=-32 +lon_0=-60 +x_0=0 +y_0=0 +ellps=aust_SA +units=m +no_defs"},
{102065, "+proj=krovak +lat_0=49.5 +lon_0=24.83333333333333 +alpha=30.28813975277778 +k=0.9999 +x_0=0 +y_0=0 +ellps=bessel +units=m +no_defs"},
{102066, "+proj=krovak +lat_0=49.5 +lon_0=42.5 +alpha=30.28813975277778 +k=0.9999 +x_0=0 +y_0=0 +ellps=bessel +pm=-17.66666666666667 +units=m +no_defs"},
{102067, "+proj=krovak +lat_0=49.5 +lon_0=24.83333333333333 +alpha=30.28813975277778 +k=0.9999 +x_0=0 +y_0=0 +ellps=bessel +units=m +no_defs"},
{102091, "+proj=tmerc +lat_0=0 +lon_0=9 +k=0.9996 +x_0=1500000 +y_0=0 +ellps=intl +units=m +no_defs"},
{102092, "+proj=tmerc +lat_0=0 +lon_0=15 +k=0.9996 +x_0=2520000 +y_0=0 +ellps=intl +units=m +no_defs"},
{102101, "+proj=tmerc +lat_0=58 +lon_0=6.05625 +k=1 +x_0=0 +y_0=0 +a=6377492.018 +b=6356173.508712696 +units=m +no_defs"},
{102102, "+proj=tmerc +lat_0=58 +lon_0=8.389583333333333 +k=1 +x_0=0 +y_0=0 +a=6377492.018 +b=6356173.508712696 +units=m +no_defs"},
{102103, "+proj=tmerc +lat_0=58 +lon_0=10.72291666666667 +k=1 +x_0=0 +y_0=0 +a=6377492.018 +b=6356173.508712696 +units=m +no_defs"},
{102104, "+proj=tmerc +lat_0=58 +lon_0=13.22291666666667 +k=1 +x_0=0 +y_0=0 +a=6377492.018 +b=6356173.508712696 +units=m +no_defs"},
{102105, "+proj=tmerc +lat_0=58 +lon_0=16.88958333333333 +k=1 +x_0=0 +y_0=0 +a=6377492.018 +b=6356173.508712696 +units=m +no_defs"},
{102106, "+proj=tmerc +lat_0=58 +lon_0=20.88958333333333 +k=1 +x_0=0 +y_0=0 +a=6377492.018 +b=6356173.508712696 +units=m +no_defs"},
{102107, "+proj=tmerc +lat_0=58 +lon_0=24.88958333333333 +k=1 +x_0=0 +y_0=0 +a=6377492.018 +b=6356173.508712696 +units=m +no_defs"},
{102108, "+proj=tmerc +lat_0=58 +lon_0=29.05625 +k=1 +x_0=0 +y_0=0 +a=6377492.018 +b=6356173.508712696 +units=m +no_defs"},
{102110, "+proj=lcc +lat_1=44 +lat_2=49 +lat_0=46.5 +lon_0=3 +x_0=700000 +y_0=6600000 +ellps=GRS80 +units=m +no_defs"},
{102114, "+proj=utm +zone=4 +ellps=clrk66 +units=m +no_defs"},
{102115, "+proj=utm +zone=5 +ellps=clrk66 +units=m +no_defs"},
{102120, "+proj=omerc +lat_0=45.30916666666666 +lonc=-86 +alpha=337.255555555556 +k=0.9996 +x_0=2546731.495961392 +y_0=-4354009.816002033 +ellps=clrk66 +datum=NAD27 +to_meter=0.3048006096012192 +no_defs"},
{102121, "+proj=omerc +lat_0=45.30916666666666 +lonc=-86 +alpha=337.255555555556 +k=0.9996 +x_0=2546731.495961392 +y_0=-4354009.816002033 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102122, "+proj=omerc +lat_0=45.30916666666666 +lonc=-86 +alpha=337.255555555556 +k=0.9996 +x_0=2546731.496 +y_0=-4354009.816 +ellps=clrk66 +datum=NAD27 +units=m +no_defs"},
{102123, "+proj=omerc +lat_0=45.30916666666666 +lonc=-86 +alpha=337.255555555556 +k=0.9996 +x_0=2546731.496 +y_0=-4354009.816 +ellps=GRS80 +datum=NAD83 +units=m +no_defs"},
{102132, "+proj=utm +zone=32 +a=6377492.018 +b=6356173.508712696 +units=m +no_defs"},
{102133, "+proj=utm +zone=33 +a=6377492.018 +b=6356173.508712696 +units=m +no_defs"},
{102134, "+proj=utm +zone=34 +a=6377492.018 +b=6356173.508712696 +units=m +no_defs"},
{102135, "+proj=utm +zone=35 +a=6377492.018 +b=6356173.508712696 +units=m +no_defs"},
{102140, "+proj=tmerc +lat_0=22.31213333333334 +lon_0=114.1785555555556 +k=1 +x_0=836694.05 +y_0=819069.8 +ellps=intl +units=m +no_defs"},
{102141, "+proj=utm +zone=49 +ellps=intl +units=m +no_defs"},
{102142, "+proj=utm +zone=50 +ellps=intl +units=m +no_defs"},
{102151, "+proj=utm +zone=51 +ellps=bessel +units=m +no_defs"},
{102152, "+proj=utm +zone=52 +ellps=bessel +units=m +no_defs"},
{102153, "+proj=utm +zone=53 +ellps=bessel +units=m +no_defs"},
{102154, "+proj=utm +zone=54 +ellps=bessel +units=m +no_defs"},
{102155, "+proj=utm +zone=55 +ellps=bessel +units=m +no_defs"},
{102156, "+proj=utm +zone=56 +ellps=bessel +units=m +no_defs"},
{102160, "+proj=tmerc +lat_0=39.66666666666666 +lon_0=-8.131906111111112 +k=1 +x_0=200180.598 +y_0=299913.01 +ellps=intl +units=m +no_defs"},
{102161, "+proj=tmerc +lat_0=39.66666666666666 +lon_0=-8.131906111111112 +k=1 +x_0=180.598 +y_0=-86.98999999999999 +ellps=intl +units=m +no_defs"},
{102162, "+proj=utm +zone=26 +ellps=intl +units=m +no_defs"},
{102163, "+proj=bonne +lon_0=-8.131906111111112 +lat_1=39.66666666666666 +x_0=0 +y_0=0 +ellps=bessel +units=m +no_defs"},
{102164, "+proj=tmerc +lat_0=39.66666666666666 +lon_0=-8.131906111111112 +k=1 +x_0=200000 +y_0=300000 +ellps=intl +units=m +no_defs"},
{102165, "+proj=tmerc +lat_0=39.66666666666666 +lon_0=-8.131906111111112 +k=1 +x_0=0 +y_0=0 +ellps=intl +units=m +no_defs"},
{102166, "+proj=utm +zone=25 +ellps=intl +units=m +no_defs"},
{102167, "+proj=utm +zone=28 +ellps=intl +units=m +no_defs"},
{102168, "+proj=utm +zone=26 +ellps=intl +units=m +no_defs"},
{102169, "+proj=utm +zone=28 +ellps=intl +units=m +no_defs"},
{102191, "+proj=lcc +lat_1=33.3 +lat_0=33.3 +lon_0=-5.4 +k_0=0.999625769 +x_0=500000 +y_0=300000 +a=6378249.2 +b=6356514.999904194 +units=m +no_defs"},
{102192, "+proj=lcc +lat_1=29.7 +lat_0=29.7 +lon_0=-5.4 +k_0=0.9996155960000001 +x_0=500000 +y_0=300000 +a=6378249.2 +b=6356514.999904194 +units=m +no_defs"},
{102193, "+proj=lcc +lat_1=26.1 +lat_0=26.1 +lon_0=-5.4 +k_0=0.9996 +x_0=1200000 +y_0=400000 +a=6378249.2 +b=6356514.999904194 +units=m +no_defs"},
{102229, "+proj=tmerc +lat_0=30.5 +lon_0=-85.83333333333333 +k=0.99996 +x_0=200000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102230, "+proj=tmerc +lat_0=30 +lon_0=-87.5 +k=0.9999333333333333 +x_0=600000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102241, "+proj=lcc +lat_1=40 +lat_2=41.66666666666666 +lat_0=39.33333333333334 +lon_0=-122 +x_0=2000000 +y_0=500000 +ellps=GRS80 +units=m +no_defs"},
{102242, "+proj=lcc +lat_1=38.33333333333334 +lat_2=39.83333333333334 +lat_0=37.66666666666666 +lon_0=-122 +x_0=2000000 +y_0=500000 +ellps=GRS80 +units=m +no_defs"},
{102243, "+proj=lcc +lat_1=37.06666666666667 +lat_2=38.43333333333333 +lat_0=36.5 +lon_0=-120.5 +x_0=2000000 +y_0=500000 +ellps=GRS80 +units=m +no_defs"},
{102244, "+proj=lcc +lat_1=36 +lat_2=37.25 +lat_0=35.33333333333334 +lon_0=-119 +x_0=2000000 +y_0=500000 +ellps=GRS80 +units=m +no_defs"},
{102245, "+proj=lcc +lat_1=34.03333333333333 +lat_2=35.46666666666667 +lat_0=33.5 +lon_0=-118 +x_0=2000000 +y_0=500000 +ellps=GRS80 +units=m +no_defs"},
{102246, "+proj=lcc +lat_1=32.78333333333333 +lat_2=33.88333333333333 +lat_0=32.16666666666666 +lon_0=-116.25 +x_0=2000000 +y_0=500000 +ellps=GRS80 +units=m +no_defs"},
{102248, "+proj=tmerc +lat_0=31 +lon_0=-110.1666666666667 +k=0.9999 +x_0=213360 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102249, "+proj=tmerc +lat_0=31 +lon_0=-111.9166666666667 +k=0.9999 +x_0=213360 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102250, "+proj=tmerc +lat_0=31 +lon_0=-113.75 +k=0.9999333333333333 +x_0=213360 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102251, "+proj=lcc +lat_1=34.93333333333333 +lat_2=36.23333333333333 +lat_0=34.33333333333334 +lon_0=-92 +x_0=400000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102252, "+proj=lcc +lat_1=33.3 +lat_2=34.76666666666667 +lat_0=32.66666666666666 +lon_0=-92 +x_0=400000 +y_0=400000 +ellps=GRS80 +units=m +no_defs"},
{102253, "+proj=lcc +lat_1=39.71666666666667 +lat_2=40.78333333333333 +lat_0=39.33333333333334 +lon_0=-105.5 +x_0=914401.8289 +y_0=304800.6096 +ellps=GRS80 +units=m +no_defs"},
{102254, "+proj=lcc +lat_1=38.45 +lat_2=39.75 +lat_0=37.83333333333334 +lon_0=-105.5 +x_0=914401.8289 +y_0=304800.6096 +ellps=GRS80 +units=m +no_defs"},
{102255, "+proj=lcc +lat_1=37.23333333333333 +lat_2=38.43333333333333 +lat_0=36.66666666666666 +lon_0=-105.5 +x_0=914401.8289 +y_0=304800.6096 +ellps=GRS80 +units=m +no_defs"},
{102256, "+proj=lcc +lat_1=41.2 +lat_2=41.86666666666667 +lat_0=40.83333333333334 +lon_0=-72.75 +x_0=304800.6096 +y_0=152400.3048 +ellps=GRS80 +units=m +no_defs"},
{102257, "+proj=tmerc +lat_0=38 +lon_0=-75.41666666666667 +k=0.999995 +x_0=200000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102258, "+proj=tmerc +lat_0=24.33333333333333 +lon_0=-81 +k=0.9999411764705882 +x_0=200000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102259, "+proj=tmerc +lat_0=24.33333333333333 +lon_0=-82 +k=0.9999411764705882 +x_0=200000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102260, "+proj=lcc +lat_1=29.58333333333333 +lat_2=30.75 +lat_0=29 +lon_0=-84.5 +x_0=600000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102261, "+proj=tmerc +lat_0=18.83333333333333 +lon_0=-155.5 +k=0.9999666666666667 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102262, "+proj=tmerc +lat_0=20.33333333333333 +lon_0=-156.6666666666667 +k=0.9999666666666667 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102263, "+proj=tmerc +lat_0=21.16666666666667 +lon_0=-158 +k=0.99999 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102264, "+proj=tmerc +lat_0=21.83333333333333 +lon_0=-159.5 +k=0.99999 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102265, "+proj=tmerc +lat_0=21.66666666666667 +lon_0=-160.1666666666667 +k=1 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102266, "+proj=tmerc +lat_0=30 +lon_0=-82.16666666666667 +k=0.9999 +x_0=200000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102267, "+proj=tmerc +lat_0=30 +lon_0=-84.16666666666667 +k=0.9999 +x_0=700000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102268, "+proj=tmerc +lat_0=41.66666666666666 +lon_0=-112.1666666666667 +k=0.9999473684210526 +x_0=200000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102269, "+proj=tmerc +lat_0=41.66666666666666 +lon_0=-114 +k=0.9999473684210526 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102270, "+proj=tmerc +lat_0=41.66666666666666 +lon_0=-115.75 +k=0.9999333333333333 +x_0=800000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102271, "+proj=tmerc +lat_0=36.66666666666666 +lon_0=-88.33333333333333 +k=0.9999749999999999 +x_0=300000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102272, "+proj=tmerc +lat_0=36.66666666666666 +lon_0=-90.16666666666667 +k=0.9999411764705882 +x_0=700000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102273, "+proj=tmerc +lat_0=37.5 +lon_0=-85.66666666666667 +k=0.9999666666666667 +x_0=100000 +y_0=250000 +ellps=GRS80 +units=m +no_defs"},
{102274, "+proj=tmerc +lat_0=37.5 +lon_0=-87.08333333333333 +k=0.9999666666666667 +x_0=900000 +y_0=250000 +ellps=GRS80 +units=m +no_defs"},
{102277, "+proj=lcc +lat_1=38.71666666666667 +lat_2=39.78333333333333 +lat_0=38.33333333333334 +lon_0=-98 +x_0=400000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102278, "+proj=lcc +lat_1=37.26666666666667 +lat_2=38.56666666666667 +lat_0=36.66666666666666 +lon_0=-98.5 +x_0=400000 +y_0=400000 +ellps=GRS80 +units=m +no_defs"},
{102279, "+proj=lcc +lat_1=37.96666666666667 +lat_2=38.96666666666667 +lat_0=37.5 +lon_0=-84.25 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102280, "+proj=lcc +lat_1=36.73333333333333 +lat_2=37.93333333333333 +lat_0=36.33333333333334 +lon_0=-85.75 +x_0=500000 +y_0=500000 +ellps=GRS80 +units=m +no_defs"},
{102281, "+proj=lcc +lat_1=31.16666666666667 +lat_2=32.66666666666666 +lat_0=30.5 +lon_0=-92.5 +x_0=1000000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102282, "+proj=lcc +lat_1=29.3 +lat_2=30.7 +lat_0=28.5 +lon_0=-91.33333333333333 +x_0=1000000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102283, "+proj=tmerc +lat_0=43.66666666666666 +lon_0=-68.5 +k=0.9999 +x_0=300000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102284, "+proj=tmerc +lat_0=42.83333333333334 +lon_0=-70.16666666666667 +k=0.9999666666666667 +x_0=900000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102285, "+proj=lcc +lat_1=38.3 +lat_2=39.45 +lat_0=37.66666666666666 +lon_0=-77 +x_0=400000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102286, "+proj=lcc +lat_1=41.71666666666667 +lat_2=42.68333333333333 +lat_0=41 +lon_0=-71.5 +x_0=200000 +y_0=750000 +ellps=GRS80 +units=m +no_defs"},
{102287, "+proj=lcc +lat_1=41.28333333333333 +lat_2=41.48333333333333 +lat_0=41 +lon_0=-70.5 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102288, "+proj=lcc +lat_1=45.48333333333333 +lat_2=47.08333333333334 +lat_0=44.78333333333333 +lon_0=-87 +x_0=8000000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102289, "+proj=lcc +lat_1=44.18333333333333 +lat_2=45.7 +lat_0=43.31666666666667 +lon_0=-84.36666666666666 +x_0=6000000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102290, "+proj=lcc +lat_1=42.1 +lat_2=43.66666666666666 +lat_0=41.5 +lon_0=-84.36666666666666 +x_0=4000000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102291, "+proj=lcc +lat_1=47.03333333333333 +lat_2=48.63333333333333 +lat_0=46.5 +lon_0=-93.09999999999999 +x_0=800000 +y_0=100000 +ellps=GRS80 +units=m +no_defs"},
{102292, "+proj=lcc +lat_1=45.61666666666667 +lat_2=47.05 +lat_0=45 +lon_0=-94.25 +x_0=800000 +y_0=100000 +ellps=GRS80 +units=m +no_defs"},
{102293, "+proj=lcc +lat_1=43.78333333333333 +lat_2=45.21666666666667 +lat_0=43 +lon_0=-94 +x_0=800000 +y_0=100000 +ellps=GRS80 +units=m +no_defs"},
{102294, "+proj=tmerc +lat_0=29.5 +lon_0=-88.83333333333333 +k=0.99995 +x_0=300000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102295, "+proj=tmerc +lat_0=29.5 +lon_0=-90.33333333333333 +k=0.99995 +x_0=700000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102296, "+proj=tmerc +lat_0=35.83333333333334 +lon_0=-90.5 +k=0.9999333333333333 +x_0=250000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102297, "+proj=tmerc +lat_0=35.83333333333334 +lon_0=-92.5 +k=0.9999333333333333 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102298, "+proj=tmerc +lat_0=36.16666666666666 +lon_0=-94.5 +k=0.9999411764705882 +x_0=850000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102300, "+proj=lcc +lat_1=45 +lat_2=49 +lat_0=44.25 +lon_0=-109.5 +x_0=600000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102304, "+proj=lcc +lat_1=40 +lat_2=43 +lat_0=39.83333333333334 +lon_0=-100 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102307, "+proj=tmerc +lat_0=34.75 +lon_0=-115.5833333333333 +k=0.9999 +x_0=200000 +y_0=8000000 +ellps=GRS80 +units=m +no_defs"},
{102308, "+proj=tmerc +lat_0=34.75 +lon_0=-116.6666666666667 +k=0.9999 +x_0=500000 +y_0=6000000 +ellps=GRS80 +units=m +no_defs"},
{102309, "+proj=tmerc +lat_0=34.75 +lon_0=-118.5833333333333 +k=0.9999 +x_0=800000 +y_0=4000000 +ellps=GRS80 +units=m +no_defs"},
{102310, "+proj=tmerc +lat_0=42.5 +lon_0=-71.66666666666667 +k=0.9999666666666667 +x_0=300000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102311, "+proj=tmerc +lat_0=38.83333333333334 +lon_0=-74.5 +k=0.9999 +x_0=150000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102312, "+proj=tmerc +lat_0=31 +lon_0=-104.3333333333333 +k=0.9999090909090909 +x_0=165000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102313, "+proj=tmerc +lat_0=31 +lon_0=-106.25 +k=0.9999 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102314, "+proj=tmerc +lat_0=31 +lon_0=-107.8333333333333 +k=0.9999166666666667 +x_0=830000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102315, "+proj=tmerc +lat_0=38.83333333333334 +lon_0=-74.5 +k=0.9999 +x_0=150000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102316, "+proj=tmerc +lat_0=40 +lon_0=-76.58333333333333 +k=0.9999375 +x_0=250000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102317, "+proj=tmerc +lat_0=40 +lon_0=-78.58333333333333 +k=0.9999375 +x_0=350000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102318, "+proj=lcc +lat_1=40.66666666666666 +lat_2=41.03333333333333 +lat_0=40.16666666666666 +lon_0=-74 +x_0=300000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102320, "+proj=lcc +lat_1=47.43333333333333 +lat_2=48.73333333333333 +lat_0=47 +lon_0=-100.5 +x_0=600000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102321, "+proj=lcc +lat_1=46.18333333333333 +lat_2=47.48333333333333 +lat_0=45.66666666666666 +lon_0=-100.5 +x_0=600000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102322, "+proj=lcc +lat_1=40.43333333333333 +lat_2=41.7 +lat_0=39.66666666666666 +lon_0=-82.5 +x_0=600000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102323, "+proj=lcc +lat_1=38.73333333333333 +lat_2=40.03333333333333 +lat_0=38 +lon_0=-82.5 +x_0=600000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102324, "+proj=lcc +lat_1=35.56666666666667 +lat_2=36.76666666666667 +lat_0=35 +lon_0=-98 +x_0=600000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102325, "+proj=lcc +lat_1=33.93333333333333 +lat_2=35.23333333333333 +lat_0=33.33333333333334 +lon_0=-98 +x_0=600000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102326, "+proj=lcc +lat_1=44.33333333333334 +lat_2=46 +lat_0=43.66666666666666 +lon_0=-120.5 +x_0=2500000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102327, "+proj=lcc +lat_1=42.33333333333334 +lat_2=44 +lat_0=41.66666666666666 +lon_0=-120.5 +x_0=1500000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102330, "+proj=tmerc +lat_0=41.08333333333334 +lon_0=-71.5 +k=0.99999375 +x_0=100000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102334, "+proj=lcc +lat_1=44.41666666666666 +lat_2=45.68333333333333 +lat_0=43.83333333333334 +lon_0=-100 +x_0=600000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102335, "+proj=lcc +lat_1=42.83333333333334 +lat_2=44.4 +lat_0=42.33333333333334 +lon_0=-100.3333333333333 +x_0=600000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102336, "+proj=lcc +lat_1=35.25 +lat_2=36.41666666666666 +lat_0=34.33333333333334 +lon_0=-86 +x_0=600000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102337, "+proj=lcc +lat_1=34.65 +lat_2=36.18333333333333 +lat_0=34 +lon_0=-101.5 +x_0=200000 +y_0=1000000 +ellps=GRS80 +units=m +no_defs"},
{102338, "+proj=lcc +lat_1=32.13333333333333 +lat_2=33.96666666666667 +lat_0=31.66666666666667 +lon_0=-98.5 +x_0=600000 +y_0=2000000 +ellps=GRS80 +units=m +no_defs"},
{102339, "+proj=lcc +lat_1=30.11666666666667 +lat_2=31.88333333333333 +lat_0=29.66666666666667 +lon_0=-100.3333333333333 +x_0=700000 +y_0=3000000 +ellps=GRS80 +units=m +no_defs"},
{102340, "+proj=lcc +lat_1=28.38333333333333 +lat_2=30.28333333333334 +lat_0=27.83333333333333 +lon_0=-99 +x_0=600000 +y_0=4000000 +ellps=GRS80 +units=m +no_defs"},
{102341, "+proj=lcc +lat_1=26.16666666666667 +lat_2=27.83333333333333 +lat_0=25.66666666666667 +lon_0=-98.5 +x_0=300000 +y_0=5000000 +ellps=GRS80 +units=m +no_defs"},
{102342, "+proj=lcc +lat_1=40.71666666666667 +lat_2=41.78333333333333 +lat_0=40.33333333333334 +lon_0=-111.5 +x_0=500000 +y_0=1000000 +ellps=GRS80 +units=m +no_defs"},
{102343, "+proj=lcc +lat_1=39.01666666666667 +lat_2=40.65 +lat_0=38.33333333333334 +lon_0=-111.5 +x_0=500000 +y_0=2000000 +ellps=GRS80 +units=m +no_defs"},
{102344, "+proj=lcc +lat_1=37.21666666666667 +lat_2=38.35 +lat_0=36.66666666666666 +lon_0=-111.5 +x_0=500000 +y_0=3000000 +ellps=GRS80 +units=m +no_defs"},
{102345, "+proj=tmerc +lat_0=42.5 +lon_0=-72.5 +k=0.9999642857142857 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102346, "+proj=lcc +lat_1=38.03333333333333 +lat_2=39.2 +lat_0=37.66666666666666 +lon_0=-78.5 +x_0=3500000 +y_0=2000000 +ellps=GRS80 +units=m +no_defs"},
{102347, "+proj=lcc +lat_1=36.76666666666667 +lat_2=37.96666666666667 +lat_0=36.33333333333334 +lon_0=-78.5 +x_0=3500000 +y_0=1000000 +ellps=GRS80 +units=m +no_defs"},
{102348, "+proj=lcc +lat_1=47.5 +lat_2=48.73333333333333 +lat_0=47 +lon_0=-120.8333333333333 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102349, "+proj=lcc +lat_1=45.83333333333334 +lat_2=47.33333333333334 +lat_0=45.33333333333334 +lon_0=-120.5 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102350, "+proj=lcc +lat_1=39 +lat_2=40.25 +lat_0=38.5 +lon_0=-79.5 +x_0=600000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102351, "+proj=lcc +lat_1=37.48333333333333 +lat_2=38.88333333333333 +lat_0=37 +lon_0=-81 +x_0=600000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102352, "+proj=lcc +lat_1=45.56666666666667 +lat_2=46.76666666666667 +lat_0=45.16666666666666 +lon_0=-90 +x_0=600000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102353, "+proj=lcc +lat_1=44.25 +lat_2=45.5 +lat_0=43.83333333333334 +lon_0=-90 +x_0=600000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102354, "+proj=lcc +lat_1=42.73333333333333 +lat_2=44.06666666666667 +lat_0=42 +lon_0=-90 +x_0=600000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102355, "+proj=tmerc +lat_0=40.5 +lon_0=-105.1666666666667 +k=0.9999375 +x_0=200000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102356, "+proj=tmerc +lat_0=40.5 +lon_0=-107.3333333333333 +k=0.9999375 +x_0=400000 +y_0=100000 +ellps=GRS80 +units=m +no_defs"},
{102357, "+proj=tmerc +lat_0=40.5 +lon_0=-108.75 +k=0.9999375 +x_0=600000 +y_0=0 +ellps=GRS80 +units=m +no_defs"},
{102358, "+proj=tmerc +lat_0=40.5 +lon_0=-110.0833333333333 +k=0.9999375 +x_0=800000 +y_0=100000 +ellps=GRS80 +units=m +no_defs"},
{102361, "+proj=lcc +lat_1=18.03333333333334 +lat_2=18.43333333333333 +lat_0=17.83333333333333 +lon_0=-66.43333333333334 +x_0=200000 +y_0=200000 +ellps=GRS80 +units=m +no_defs"},
{102491, "+proj=lcc +lat_1=36 +lat_0=36 +lon_0=2.7 +k_0=0.999625544 +x_0=500000 +y_0=300000 +a=6378249.2 +b=6356514.999904194 +units=m +no_defs"},
{102492, "+proj=lcc +lat_1=33.3 +lat_0=33.3 +lon_0=2.7 +k_0=0.999625769 +x_0=500000 +y_0=300000 +a=6378249.2 +b=6356514.999904194 +units=m +no_defs"},
{102581, "+proj=lcc +lat_1=49.5 +lat_0=49.5 +lon_0=2.337229166666667 +k_0=0.999877341 +x_0=600000 +y_0=1200000 +a=6378249.2 +b=6356514.999904194 +units=m +no_defs"},
{102582, "+proj=lcc +lat_1=46.8 +lat_0=46.8 +lon_0=2.337229166666667 +k_0=0.99987742 +x_0=600000 +y_0=2200000 +a=6378249.2 +b=6356514.999904194 +units=m +no_defs"},
{102583, "+proj=lcc +lat_1=44.1 +lat_0=44.1 +lon_0=2.337229166666667 +k_0=0.999877499 +x_0=600000 +y_0=3200000 +a=6378249.2 +b=6356514.999904194 +units=m +no_defs"},
{102584, "+proj=lcc +lat_1=42.165 +lat_0=42.165 +lon_0=2.337229166666667 +k_0=0.99994471 +x_0=234.358 +y_0=4185861.369 +a=6378249.2 +b=6356514.999904194 +units=m +no_defs"},
{102591, "+proj=lcc +lat_1=36 +lat_0=36 +lon_0=2.7 +k_0=0.999625544 +x_0=500135 +y_0=300090 +ellps=clrk80 +units=m +no_defs"},
{102592, "+proj=lcc +lat_1=33.3 +lat_0=33.3 +lon_0=2.7 +k_0=0.999625769 +x_0=500135 +y_0=300090 +ellps=clrk80 +units=m +no_defs"},
{102629, "+proj=tmerc +lat_0=30.5 +lon_0=-85.83333333333333 +k=0.99996 +x_0=200000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102630, "+proj=tmerc +lat_0=30 +lon_0=-87.5 +k=0.9999333333333333 +x_0=600000.0000000001 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102631, "+proj=omerc +lat_0=57 +lonc=-133.6666666666667 +alpha=-36.86989764583333 +k=0.9999 +x_0=4999999.999999999 +y_0=-4999999.999999999 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102632, "+proj=tmerc +lat_0=54 +lon_0=-142 +k=0.9999 +x_0=500000.0000000002 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102633, "+proj=tmerc +lat_0=54 +lon_0=-146 +k=0.9999 +x_0=500000.0000000002 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102634, "+proj=tmerc +lat_0=54 +lon_0=-150 +k=0.9999 +x_0=500000.0000000002 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102635, "+proj=tmerc +lat_0=54 +lon_0=-154 +k=0.9999 +x_0=500000.0000000002 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102636, "+proj=tmerc +lat_0=54 +lon_0=-158 +k=0.9999 +x_0=500000.0000000002 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102637, "+proj=tmerc +lat_0=54 +lon_0=-162 +k=0.9999 +x_0=500000.0000000002 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102638, "+proj=tmerc +lat_0=54 +lon_0=-166 +k=0.9999 +x_0=500000.0000000002 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102639, "+proj=tmerc +lat_0=54 +lon_0=-170 +k=0.9999 +x_0=500000.0000000002 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102640, "+proj=lcc +lat_1=51.83333333333334 +lat_2=53.83333333333334 +lat_0=51 +lon_0=-176 +x_0=1000000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102641, "+proj=lcc +lat_1=40 +lat_2=41.66666666666666 +lat_0=39.33333333333334 +lon_0=-122 +x_0=2000000 +y_0=500000.0000000002 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102642, "+proj=lcc +lat_1=38.33333333333334 +lat_2=39.83333333333334 +lat_0=37.66666666666666 +lon_0=-122 +x_0=2000000 +y_0=500000.0000000002 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102643, "+proj=lcc +lat_1=37.06666666666667 +lat_2=38.43333333333333 +lat_0=36.5 +lon_0=-120.5 +x_0=2000000 +y_0=500000.0000000002 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102644, "+proj=lcc +lat_1=36 +lat_2=37.25 +lat_0=35.33333333333334 +lon_0=-119 +x_0=2000000 +y_0=500000.0000000002 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102645, "+proj=lcc +lat_1=34.03333333333333 +lat_2=35.46666666666667 +lat_0=33.5 +lon_0=-118 +x_0=2000000 +y_0=500000.0000000002 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102646, "+proj=lcc +lat_1=32.78333333333333 +lat_2=33.88333333333333 +lat_0=32.16666666666666 +lon_0=-116.25 +x_0=2000000 +y_0=500000.0000000002 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102648, "+proj=tmerc +lat_0=31 +lon_0=-110.1666666666667 +k=0.9999 +x_0=213360 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102649, "+proj=tmerc +lat_0=31 +lon_0=-111.9166666666667 +k=0.9999 +x_0=213360 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102650, "+proj=tmerc +lat_0=31 +lon_0=-113.75 +k=0.9999333333333333 +x_0=213360 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102651, "+proj=lcc +lat_1=34.93333333333333 +lat_2=36.23333333333333 +lat_0=34.33333333333334 +lon_0=-92 +x_0=399999.9999999999 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102652, "+proj=lcc +lat_1=33.3 +lat_2=34.76666666666667 +lat_0=32.66666666666666 +lon_0=-92 +x_0=399999.9999999999 +y_0=399999.9999999999 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102653, "+proj=lcc +lat_1=39.71666666666667 +lat_2=40.78333333333333 +lat_0=39.33333333333334 +lon_0=-105.5 +x_0=914401.8289 +y_0=304800.6096 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102654, "+proj=lcc +lat_1=38.45 +lat_2=39.75 +lat_0=37.83333333333334 +lon_0=-105.5 +x_0=914401.8289 +y_0=304800.6096 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102655, "+proj=lcc +lat_1=37.23333333333333 +lat_2=38.43333333333333 +lat_0=36.66666666666666 +lon_0=-105.5 +x_0=914401.8289 +y_0=304800.6096 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102656, "+proj=lcc +lat_1=41.2 +lat_2=41.86666666666667 +lat_0=40.83333333333334 +lon_0=-72.75 +x_0=304800.6096 +y_0=152400.3048 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102657, "+proj=tmerc +lat_0=38 +lon_0=-75.41666666666667 +k=0.999995 +x_0=200000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102658, "+proj=tmerc +lat_0=24.33333333333333 +lon_0=-81 +k=0.9999411764705882 +x_0=200000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102659, "+proj=tmerc +lat_0=24.33333333333333 +lon_0=-82 +k=0.9999411764705882 +x_0=200000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102660, "+proj=lcc +lat_1=29.58333333333333 +lat_2=30.75 +lat_0=29 +lon_0=-84.5 +x_0=600000.0000000001 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102661, "+proj=tmerc +lat_0=18.83333333333333 +lon_0=-155.5 +k=0.9999666666666667 +x_0=500000.0000000002 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102662, "+proj=tmerc +lat_0=20.33333333333333 +lon_0=-156.6666666666667 +k=0.9999666666666667 +x_0=500000.0000000002 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102663, "+proj=tmerc +lat_0=21.16666666666667 +lon_0=-158 +k=0.99999 +x_0=500000.0000000002 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102664, "+proj=tmerc +lat_0=21.83333333333333 +lon_0=-159.5 +k=0.99999 +x_0=500000.0000000002 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102665, "+proj=tmerc +lat_0=21.66666666666667 +lon_0=-160.1666666666667 +k=1 +x_0=500000.0000000002 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102666, "+proj=tmerc +lat_0=30 +lon_0=-82.16666666666667 +k=0.9999 +x_0=200000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102667, "+proj=tmerc +lat_0=30 +lon_0=-84.16666666666667 +k=0.9999 +x_0=700000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102668, "+proj=tmerc +lat_0=41.66666666666666 +lon_0=-112.1666666666667 +k=0.9999473684210526 +x_0=200000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102669, "+proj=tmerc +lat_0=41.66666666666666 +lon_0=-114 +k=0.9999473684210526 +x_0=500000.0000000002 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102670, "+proj=tmerc +lat_0=41.66666666666666 +lon_0=-115.75 +k=0.9999333333333333 +x_0=799999.9999999999 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102671, "+proj=tmerc +lat_0=36.66666666666666 +lon_0=-88.33333333333333 +k=0.9999749999999999 +x_0=300000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102672, "+proj=tmerc +lat_0=36.66666666666666 +lon_0=-90.16666666666667 +k=0.9999411764705882 +x_0=700000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102673, "+proj=tmerc +lat_0=37.5 +lon_0=-85.66666666666667 +k=0.9999666666666667 +x_0=100000 +y_0=250000 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102674, "+proj=tmerc +lat_0=37.5 +lon_0=-87.08333333333333 +k=0.9999666666666667 +x_0=900000.0000000001 +y_0=250000 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102675, "+proj=lcc +lat_1=42.06666666666667 +lat_2=43.26666666666667 +lat_0=41.5 +lon_0=-93.5 +x_0=1500000 +y_0=1000000 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102676, "+proj=lcc +lat_1=40.61666666666667 +lat_2=41.78333333333333 +lat_0=40 +lon_0=-93.5 +x_0=500000.0000000002 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102677, "+proj=lcc +lat_1=38.71666666666667 +lat_2=39.78333333333333 +lat_0=38.33333333333334 +lon_0=-98 +x_0=399999.9999999999 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102678, "+proj=lcc +lat_1=37.26666666666667 +lat_2=38.56666666666667 +lat_0=36.66666666666666 +lon_0=-98.5 +x_0=399999.9999999999 +y_0=399999.9999999999 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102679, "+proj=lcc +lat_1=37.96666666666667 +lat_2=38.96666666666667 +lat_0=37.5 +lon_0=-84.25 +x_0=500000.0000000002 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102680, "+proj=lcc +lat_1=36.73333333333333 +lat_2=37.93333333333333 +lat_0=36.33333333333334 +lon_0=-85.75 +x_0=500000.0000000002 +y_0=500000.0000000002 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102681, "+proj=lcc +lat_1=31.16666666666667 +lat_2=32.66666666666666 +lat_0=30.5 +lon_0=-92.5 +x_0=1000000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102682, "+proj=lcc +lat_1=29.3 +lat_2=30.7 +lat_0=28.5 +lon_0=-91.33333333333333 +x_0=1000000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102683, "+proj=tmerc +lat_0=43.66666666666666 +lon_0=-68.5 +k=0.9999 +x_0=300000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102684, "+proj=tmerc +lat_0=42.83333333333334 +lon_0=-70.16666666666667 +k=0.9999666666666667 +x_0=900000.0000000001 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102685, "+proj=lcc +lat_1=38.3 +lat_2=39.45 +lat_0=37.66666666666666 +lon_0=-77 +x_0=399999.9999999999 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102686, "+proj=lcc +lat_1=41.71666666666667 +lat_2=42.68333333333333 +lat_0=41 +lon_0=-71.5 +x_0=200000 +y_0=750000.0000000001 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102687, "+proj=lcc +lat_1=41.28333333333333 +lat_2=41.48333333333333 +lat_0=41 +lon_0=-70.5 +x_0=500000.0000000002 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102688, "+proj=lcc +lat_1=45.48333333333333 +lat_2=47.08333333333334 +lat_0=44.78333333333333 +lon_0=-87 +x_0=7999999.999999999 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102689, "+proj=lcc +lat_1=44.18333333333333 +lat_2=45.7 +lat_0=43.31666666666667 +lon_0=-84.36666666666666 +x_0=6000000.000000001 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102690, "+proj=lcc +lat_1=42.1 +lat_2=43.66666666666666 +lat_0=41.5 +lon_0=-84.36666666666666 +x_0=4000000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102691, "+proj=lcc +lat_1=47.03333333333333 +lat_2=48.63333333333333 +lat_0=46.5 +lon_0=-93.09999999999999 +x_0=799999.9999999999 +y_0=100000 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102692, "+proj=lcc +lat_1=45.61666666666667 +lat_2=47.05 +lat_0=45 +lon_0=-94.25 +x_0=799999.9999999999 +y_0=100000 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102693, "+proj=lcc +lat_1=43.78333333333333 +lat_2=45.21666666666667 +lat_0=43 +lon_0=-94 +x_0=799999.9999999999 +y_0=100000 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102694, "+proj=tmerc +lat_0=29.5 +lon_0=-88.83333333333333 +k=0.99995 +x_0=300000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102695, "+proj=tmerc +lat_0=29.5 +lon_0=-90.33333333333333 +k=0.99995 +x_0=700000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102696, "+proj=tmerc +lat_0=35.83333333333334 +lon_0=-90.5 +k=0.9999333333333333 +x_0=250000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102697, "+proj=tmerc +lat_0=35.83333333333334 +lon_0=-92.5 +k=0.9999333333333333 +x_0=500000.0000000002 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102698, "+proj=tmerc +lat_0=36.16666666666666 +lon_0=-94.5 +k=0.9999411764705882 +x_0=850000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102700, "+proj=lcc +lat_1=45 +lat_2=49 +lat_0=44.25 +lon_0=-109.5 +x_0=600000.0000000001 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102704, "+proj=lcc +lat_1=40 +lat_2=43 +lat_0=39.83333333333334 +lon_0=-100 +x_0=500000.0000000002 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102707, "+proj=tmerc +lat_0=34.75 +lon_0=-115.5833333333333 +k=0.9999 +x_0=200000 +y_0=7999999.999999999 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102708, "+proj=tmerc +lat_0=34.75 +lon_0=-116.6666666666667 +k=0.9999 +x_0=500000.0000000002 +y_0=6000000.000000001 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102709, "+proj=tmerc +lat_0=34.75 +lon_0=-118.5833333333333 +k=0.9999 +x_0=799999.9999999999 +y_0=4000000 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102710, "+proj=tmerc +lat_0=42.5 +lon_0=-71.66666666666667 +k=0.9999666666666667 +x_0=300000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102711, "+proj=tmerc +lat_0=38.83333333333334 +lon_0=-74.5 +k=0.9999 +x_0=150000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102712, "+proj=tmerc +lat_0=31 +lon_0=-104.3333333333333 +k=0.9999090909090909 +x_0=165000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102713, "+proj=tmerc +lat_0=31 +lon_0=-106.25 +k=0.9999 +x_0=500000.0000000002 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102714, "+proj=tmerc +lat_0=31 +lon_0=-107.8333333333333 +k=0.9999166666666667 +x_0=829999.9999999999 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102715, "+proj=tmerc +lat_0=38.83333333333334 +lon_0=-74.5 +k=0.9999 +x_0=150000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102716, "+proj=tmerc +lat_0=40 +lon_0=-76.58333333333333 +k=0.9999375 +x_0=250000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102717, "+proj=tmerc +lat_0=40 +lon_0=-78.58333333333333 +k=0.9999375 +x_0=350000.0000000001 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102718, "+proj=lcc +lat_1=40.66666666666666 +lat_2=41.03333333333333 +lat_0=40.16666666666666 +lon_0=-74 +x_0=300000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102719, "+proj=lcc +lat_1=34.33333333333334 +lat_2=36.16666666666666 +lat_0=33.75 +lon_0=-79 +x_0=609601.2199999999 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102720, "+proj=lcc +lat_1=47.43333333333333 +lat_2=48.73333333333333 +lat_0=47 +lon_0=-100.5 +x_0=600000.0000000001 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102721, "+proj=lcc +lat_1=46.18333333333333 +lat_2=47.48333333333333 +lat_0=45.66666666666666 +lon_0=-100.5 +x_0=600000.0000000001 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102722, "+proj=lcc +lat_1=40.43333333333333 +lat_2=41.7 +lat_0=39.66666666666666 +lon_0=-82.5 +x_0=600000.0000000001 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102723, "+proj=lcc +lat_1=38.73333333333333 +lat_2=40.03333333333333 +lat_0=38 +lon_0=-82.5 +x_0=600000.0000000001 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102724, "+proj=lcc +lat_1=35.56666666666667 +lat_2=36.76666666666667 +lat_0=35 +lon_0=-98 +x_0=600000.0000000001 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102725, "+proj=lcc +lat_1=33.93333333333333 +lat_2=35.23333333333333 +lat_0=33.33333333333334 +lon_0=-98 +x_0=600000.0000000001 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102726, "+proj=lcc +lat_1=44.33333333333334 +lat_2=46 +lat_0=43.66666666666666 +lon_0=-120.5 +x_0=2500000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102727, "+proj=lcc +lat_1=42.33333333333334 +lat_2=44 +lat_0=41.66666666666666 +lon_0=-120.5 +x_0=1500000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102728, "+proj=lcc +lat_1=40.88333333333333 +lat_2=41.95 +lat_0=40.16666666666666 +lon_0=-77.75 +x_0=600000.0000000001 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102729, "+proj=lcc +lat_1=39.93333333333333 +lat_2=40.96666666666667 +lat_0=39.33333333333334 +lon_0=-77.75 +x_0=600000.0000000001 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102730, "+proj=tmerc +lat_0=41.08333333333334 +lon_0=-71.5 +k=0.99999375 +x_0=100000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102733, "+proj=lcc +lat_1=32.5 +lat_2=34.83333333333334 +lat_0=31.83333333333333 +lon_0=-81 +x_0=609600.0000000001 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102734, "+proj=lcc +lat_1=44.41666666666666 +lat_2=45.68333333333333 +lat_0=43.83333333333334 +lon_0=-100 +x_0=600000.0000000001 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102735, "+proj=lcc +lat_1=42.83333333333334 +lat_2=44.4 +lat_0=42.33333333333334 +lon_0=-100.3333333333333 +x_0=600000.0000000001 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102736, "+proj=lcc +lat_1=35.25 +lat_2=36.41666666666666 +lat_0=34.33333333333334 +lon_0=-86 +x_0=600000.0000000001 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102737, "+proj=lcc +lat_1=34.65 +lat_2=36.18333333333333 +lat_0=34 +lon_0=-101.5 +x_0=200000 +y_0=1000000 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102738, "+proj=lcc +lat_1=32.13333333333333 +lat_2=33.96666666666667 +lat_0=31.66666666666667 +lon_0=-98.5 +x_0=600000.0000000001 +y_0=2000000 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102739, "+proj=lcc +lat_1=30.11666666666667 +lat_2=31.88333333333333 +lat_0=29.66666666666667 +lon_0=-100.3333333333333 +x_0=700000 +y_0=3000000 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102740, "+proj=lcc +lat_1=28.38333333333333 +lat_2=30.28333333333334 +lat_0=27.83333333333333 +lon_0=-99 +x_0=600000.0000000001 +y_0=4000000 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102741, "+proj=lcc +lat_1=26.16666666666667 +lat_2=27.83333333333333 +lat_0=25.66666666666667 +lon_0=-98.5 +x_0=300000 +y_0=4999999.999999999 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102742, "+proj=lcc +lat_1=40.71666666666667 +lat_2=41.78333333333333 +lat_0=40.33333333333334 +lon_0=-111.5 +x_0=500000.0000000002 +y_0=1000000 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102743, "+proj=lcc +lat_1=39.01666666666667 +lat_2=40.65 +lat_0=38.33333333333334 +lon_0=-111.5 +x_0=500000.0000000002 +y_0=2000000 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102744, "+proj=lcc +lat_1=37.21666666666667 +lat_2=38.35 +lat_0=36.66666666666666 +lon_0=-111.5 +x_0=500000.0000000002 +y_0=3000000 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102745, "+proj=tmerc +lat_0=42.5 +lon_0=-72.5 +k=0.9999642857142857 +x_0=500000.0000000002 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102746, "+proj=lcc +lat_1=38.03333333333333 +lat_2=39.2 +lat_0=37.66666666666666 +lon_0=-78.5 +x_0=3499999.999999999 +y_0=2000000 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102747, "+proj=lcc +lat_1=36.76666666666667 +lat_2=37.96666666666667 +lat_0=36.33333333333334 +lon_0=-78.5 +x_0=3499999.999999999 +y_0=1000000 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102748, "+proj=lcc +lat_1=47.5 +lat_2=48.73333333333333 +lat_0=47 +lon_0=-120.8333333333333 +x_0=500000.0000000002 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102749, "+proj=lcc +lat_1=45.83333333333334 +lat_2=47.33333333333334 +lat_0=45.33333333333334 +lon_0=-120.5 +x_0=500000.0000000002 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102750, "+proj=lcc +lat_1=39 +lat_2=40.25 +lat_0=38.5 +lon_0=-79.5 +x_0=600000.0000000001 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102751, "+proj=lcc +lat_1=37.48333333333333 +lat_2=38.88333333333333 +lat_0=37 +lon_0=-81 +x_0=600000.0000000001 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102752, "+proj=lcc +lat_1=45.56666666666667 +lat_2=46.76666666666667 +lat_0=45.16666666666666 +lon_0=-90 +x_0=600000.0000000001 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102753, "+proj=lcc +lat_1=44.25 +lat_2=45.5 +lat_0=43.83333333333334 +lon_0=-90 +x_0=600000.0000000001 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102754, "+proj=lcc +lat_1=42.73333333333333 +lat_2=44.06666666666667 +lat_0=42 +lon_0=-90 +x_0=600000.0000000001 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102755, "+proj=tmerc +lat_0=40.5 +lon_0=-105.1666666666667 +k=0.9999375 +x_0=200000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102756, "+proj=tmerc +lat_0=40.5 +lon_0=-107.3333333333333 +k=0.9999375 +x_0=399999.9999999999 +y_0=100000 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102757, "+proj=tmerc +lat_0=40.5 +lon_0=-108.75 +k=0.9999375 +x_0=600000.0000000001 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102758, "+proj=tmerc +lat_0=40.5 +lon_0=-110.0833333333333 +k=0.9999375 +x_0=799999.9999999999 +y_0=100000 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102761, "+proj=lcc +lat_1=18.03333333333334 +lat_2=18.43333333333333 +lat_0=17.83333333333333 +lon_0=-66.43333333333334 +x_0=200000 +y_0=200000 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{102766, "+proj=poly +lat_0=13.47246635277778 +lon_0=-144.7487507055556 +x_0=49999.99999999999 +y_0=49999.99999999999 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs"},
{103300, "+proj=lcc +lat_1=49.8333339 +lat_2=51.16666733333333 +lat_0=90 +lon_0=4.367486666666666 +x_0=150000.01256 +y_0=5400088.4378 +ellps=intl +units=m +no_defs"},
{104000, "+proj=longlat +ellps=clrk66 +datum=NAD27 +no_defs"},
{104101, "+proj=longlat +ellps=bessel +no_defs"},
{104102, "+proj=longlat +ellps=bessel +no_defs"},
{104103, "+proj=longlat +ellps=clrk80 +no_defs"},
{104104, "+proj=longlat +ellps=intl +no_defs"},
{104105, "+proj=longlat +ellps=bessel +no_defs"},
{104106, "+proj=longlat +ellps=intl +no_defs"},
{104107, "+proj=longlat +ellps=GRS80 +no_defs"},
{104108, "+proj=longlat +ellps=GRS80 +no_defs"},
{104261, "+proj=longlat +a=6378249.2 +b=6356514.999904194 +no_defs"},
{104304, "+proj=longlat +a=6378249.2 +b=6356514.999904194 +no_defs"},
{104305, "+proj=longlat +ellps=clrk80 +no_defs"}
};
const code_element * first = arr;
const code_element * last = arr + sizeof(arr) / sizeof(code_element);
const code_element * el = binary_find_code_element(first, last, code);
return el != last ? el->proj4_str : "";
}
}
#endif // DOXYGEN_NO_DETAIL
}}} // namespace boost::geometry::projections
#endif

View File

@@ -0,0 +1,48 @@
// Boost.Geometry
// Copyright (c) 2017, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
#ifndef BOOST_GEOMETRY_SRS_PROJECTIONS_ESRI_PARAMS_HPP
#define BOOST_GEOMETRY_SRS_PROJECTIONS_ESRI_PARAMS_HPP
#include <string>
#include <boost/geometry/srs/spheroid.hpp>
namespace boost { namespace geometry
{
namespace srs
{
struct esri
{
explicit esri(int c)
: code(c)
{}
int code;
};
template <int Code>
struct static_esri
{
static const int code = Code;
};
} // namespace srs
}} // namespace boost::geometry
#endif // BOOST_GEOMETRY_SRS_PROJECTIONS_ESRI_PARAMS_HPP

View File

@@ -0,0 +1,499 @@
// Boost.Geometry
// Copyright (c) 2017-2018, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
#ifndef BOOST_GEOMETRY_PROJECTIONS_ESRI_TRAITS_HPP
#define BOOST_GEOMETRY_PROJECTIONS_ESRI_TRAITS_HPP
#include <boost/geometry/core/tags.hpp>
#include <boost/geometry/srs/projections/factory.hpp>
#include <boost/geometry/srs/projections/impl/projects.hpp>
#include <boost/geometry/srs/projections/srid_traits.hpp>
namespace boost { namespace geometry { namespace projections
{
#ifndef DOXYGEN_NO_DETAIL
namespace detail
{
/*!
\brief ESRI traits
\details With help of the ESRI traits library users can statically use projections
or coordinate systems specifying an ESRI code. The correct projections for transformations
are used automically then, still keeping static polymorphism.
\ingroup projection
\tparam ESRI esri code
*/
template <size_t ESRI>
struct esri_traits
{
// Specializations define:
// - type to get projection type
// - function par to get parameters
};
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 37001, longlat, WGS66, "+proj=longlat +ellps=WGS66 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_AB(esri, 37002, longlat, 6378166, 6356784.283607107, "+proj=longlat +a=6378166 +b=6356784.283607107 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_AB(esri, 37003, longlat, 6378150, 6356768.337244385, "+proj=longlat +a=6378150 +b=6356768.337244385 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 37004, longlat, fschr60m, "+proj=longlat +ellps=fschr60m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_AB(esri, 37005, longlat, 6378270, 6356794.343434343, "+proj=longlat +a=6378270 +b=6356794.343434343 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_AB(esri, 37006, longlat, 6377295.664, 6356094.667915204, "+proj=longlat +a=6377295.664 +b=6356094.667915204 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_AB(esri, 37007, longlat, 6376896, 6355834.846687363, "+proj=longlat +a=6376896 +b=6355834.846687363 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_S (esri, 37008, longlat, 6370997, "+proj=longlat +a=6370997 +b=6370997 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 37201, longlat, intl, "+proj=longlat +ellps=intl +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_AB(esri, 37202, longlat, 6377276.345, 6356075.41314024, "+proj=longlat +a=6377276.345 +b=6356075.41314024 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_AB(esri, 37203, longlat, 6377301.243, 6356100.230165384, "+proj=longlat +a=6377301.243 +b=6356100.230165384 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 37204, longlat, intl, "+proj=longlat +ellps=intl +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 37205, longlat, intl, "+proj=longlat +ellps=intl +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 37206, longlat, clrk80, "+proj=longlat +ellps=clrk80 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 37207, longlat, fschr60m, "+proj=longlat +ellps=fschr60m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 37208, longlat, clrk80, "+proj=longlat +ellps=clrk80 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 37211, longlat, clrk80, "+proj=longlat +ellps=clrk80 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 37212, longlat, intl, "+proj=longlat +ellps=intl +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 37213, longlat, intl, "+proj=longlat +ellps=intl +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 37214, longlat, intl, "+proj=longlat +ellps=intl +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 37215, longlat, intl, "+proj=longlat +ellps=intl +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 37216, longlat, intl, "+proj=longlat +ellps=intl +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 37217, longlat, intl, "+proj=longlat +ellps=intl +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 37218, longlat, intl, "+proj=longlat +ellps=intl +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 37219, longlat, intl, "+proj=longlat +ellps=intl +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 37220, longlat, clrk66, "+proj=longlat +ellps=clrk66 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 37221, longlat, intl, "+proj=longlat +ellps=intl +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 37222, longlat, intl, "+proj=longlat +ellps=intl +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_AB(esri, 37223, longlat, 6378249.2, 6356514.999904194, "+proj=longlat +a=6378249.2 +b=6356514.999904194 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 37224, longlat, intl, "+proj=longlat +ellps=intl +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 37226, longlat, intl, "+proj=longlat +ellps=intl +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 37227, longlat, intl, "+proj=longlat +ellps=intl +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 37228, longlat, clrk80, "+proj=longlat +ellps=clrk80 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_AB(esri, 37229, longlat, 6378270, 6356794.343434343, "+proj=longlat +a=6378270 +b=6356794.343434343 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 37230, longlat, intl, "+proj=longlat +ellps=intl +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 37231, longlat, aust_SA, "+proj=longlat +ellps=aust_SA +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 37232, longlat, intl, "+proj=longlat +ellps=intl +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 37233, longlat, intl, "+proj=longlat +ellps=intl +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 37234, longlat, intl, "+proj=longlat +ellps=intl +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 37235, longlat, intl, "+proj=longlat +ellps=intl +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 37237, longlat, intl, "+proj=longlat +ellps=intl +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 37238, longlat, intl, "+proj=longlat +ellps=intl +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 37239, longlat, clrk66, "+proj=longlat +ellps=clrk66 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 37240, longlat, clrk80, "+proj=longlat +ellps=clrk80 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 37241, longlat, intl, "+proj=longlat +ellps=intl +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 37242, longlat, intl, "+proj=longlat +ellps=intl +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 37243, longlat, clrk66, "+proj=longlat +ellps=clrk66 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 37245, longlat, intl, "+proj=longlat +ellps=intl +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 37246, longlat, intl, "+proj=longlat +ellps=intl +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 37247, longlat, intl, "+proj=longlat +ellps=intl +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 37249, longlat, intl, "+proj=longlat +ellps=intl +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 37250, longlat, intl, "+proj=longlat +ellps=intl +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 37251, longlat, intl, "+proj=longlat +ellps=intl +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 37252, longlat, clrk66, "+proj=longlat +ellps=clrk66 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 37253, longlat, intl, "+proj=longlat +ellps=intl +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 37254, longlat, clrk80, "+proj=longlat +ellps=clrk80 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 37255, longlat, bessel, "+proj=longlat +ellps=bessel +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 37257, longlat, krass, "+proj=longlat +ellps=krass +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 37259, longlat, intl, "+proj=longlat +ellps=intl +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 37260, longlat, clrk66, "+proj=longlat +ellps=clrk66 +no_defs")
//BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS (esri, 53001, "")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_S (esri, 53002, eqc, 6371000, "+proj=eqc +lat_ts=60 +lat_0=0 +lon_0=0 +x_0=0 +y_0=0 +a=6371000 +b=6371000 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_S (esri, 53003, mill, 6371000, "+proj=mill +lat_0=0 +lon_0=0 +x_0=0 +y_0=0 +R_A +a=6371000 +b=6371000 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_S (esri, 53004, merc, 6371000, "+proj=merc +lon_0=0 +k=1 +x_0=0 +y_0=0 +a=6371000 +b=6371000 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_S (esri, 53008, sinu, 6371000, "+proj=sinu +lon_0=0 +x_0=0 +y_0=0 +a=6371000 +b=6371000 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_S (esri, 53009, moll, 6371000, "+proj=moll +lon_0=0 +x_0=0 +y_0=0 +a=6371000 +b=6371000 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_S (esri, 53010, eck6, 6371000, "+proj=eck6 +lon_0=0 +x_0=0 +y_0=0 +a=6371000 +b=6371000 +units=m +no_defs")
//BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS (esri, 53011, "")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_S (esri, 53012, eck4, 6371000, "+proj=eck4 +lon_0=0 +x_0=0 +y_0=0 +a=6371000 +b=6371000 +units=m +no_defs")
//BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS (esri, 53013, "")
//BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS (esri, 53014, "")
//BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS (esri, 53015, "")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_S (esri, 53016, gall, 6371000, "+proj=gall +lon_0=0 +x_0=0 +y_0=0 +a=6371000 +b=6371000 +units=m +no_defs")
//BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS (esri, 53017, "")
//BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS (esri, 53018, "")
//BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS (esri, 53019, "")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_S (esri, 53021, poly, 6371000, "+proj=poly +lat_0=0 +lon_0=0 +x_0=0 +y_0=0 +a=6371000 +b=6371000 +units=m +no_defs")
//BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS (esri, 53022, "")
//BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS (esri, 53023, "")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_S (esri, 53024, bonne, 6371000, "+proj=bonne +lon_0=0 +lat_1=60 +x_0=0 +y_0=0 +a=6371000 +b=6371000 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_S (esri, 53025, omerc, 6371000, "+proj=omerc +lat_0=40 +lon_1=0 +lat_1=0 +lon_2=0 +lat_2=0 +k=1 +x_0=0 +y_0=0 +a=6371000 +b=6371000 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_S (esri, 53026, stere, 6371000, "+proj=stere +lat_0=0 +lon_0=0 +k=1 +x_0=0 +y_0=0 +a=6371000 +b=6371000 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_S (esri, 53027, eqdc, 6371000, "+proj=eqdc +lat_0=0 +lon_0=0 +lat_1=60 +lat_2=60 +x_0=0 +y_0=0 +a=6371000 +b=6371000 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_S (esri, 53028, cass, 6371000, "+proj=cass +lat_0=0 +lon_0=0 +x_0=0 +y_0=0 +a=6371000 +b=6371000 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_S (esri, 53029, vandg, 6371000, "+proj=vandg +lon_0=0 +x_0=0 +y_0=0 +R_A +a=6371000 +b=6371000 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_S (esri, 53030, robin, 6371000, "+proj=robin +lon_0=0 +x_0=0 +y_0=0 +a=6371000 +b=6371000 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_S (esri, 53031, tpeqd, 6371000, "+proj=tpeqd +lat_1=0 +lon_1=0 +lat_2=60 +lon_2=60 +x_0=0 +y_0=0 +a=6371000 +b=6371000 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_S (esri, 53032, aeqd, 6371000, "+proj=aeqd +lat_0=0 +lon_0=0 +x_0=0 +y_0=0 +a=6371000 +b=6371000 +units=m +no_defs")
//BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS (esri, 54001, "")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 54002, eqc, WGS84, WGS84, "+proj=eqc +lat_ts=60 +lat_0=0 +lon_0=0 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_S (esri, 54003, mill, 6371007.1810824294, "+proj=mill +lat_0=0 +lon_0=0 +x_0=0 +y_0=0 +R_A +ellps=WGS84 +datum=WGS84 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 54004, merc, WGS84, WGS84, "+proj=merc +lon_0=0 +k=1 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 54008, sinu, WGS84, WGS84, "+proj=sinu +lon_0=0 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 54009, moll, WGS84, WGS84, "+proj=moll +lon_0=0 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 54010, eck6, WGS84, WGS84, "+proj=eck6 +lon_0=0 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs")
//BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS (esri, 54011, "")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 54012, eck4, WGS84, WGS84, "+proj=eck4 +lon_0=0 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs")
//BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS (esri, 54013, "")
//BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS (esri, 54014, "")
//BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS (esri, 54015, "")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 54016, gall, WGS84, WGS84, "+proj=gall +lon_0=0 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs")
//BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS (esri, 54017, "")
//BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS (esri, 54018, "")
//BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS (esri, 54019, "")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 54021, poly, WGS84, WGS84, "+proj=poly +lat_0=0 +lon_0=0 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs")
//BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS (esri, 54022, "")
//BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS (esri, 54023, "")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 54024, bonne, WGS84, WGS84, "+proj=bonne +lon_0=0 +lat_1=60 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 54025, omerc, WGS84, WGS84, "+proj=omerc +lat_0=40 +lon_1=0 +lat_1=0 +lon_2=0 +lat_2=0 +k=1 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 54026, stere, WGS84, WGS84, "+proj=stere +lat_0=0 +lon_0=0 +k=1 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 54027, eqdc, WGS84, WGS84, "+proj=eqdc +lat_0=0 +lon_0=0 +lat_1=60 +lat_2=60 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 54028, cass, WGS84, WGS84, "+proj=cass +lat_0=0 +lon_0=0 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_S (esri, 54029, vandg, 6371007.1810824294, "+proj=vandg +lon_0=0 +x_0=0 +y_0=0 +R_A +ellps=WGS84 +datum=WGS84 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 54030, robin, WGS84, WGS84, "+proj=robin +lon_0=0 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 54031, tpeqd, WGS84, WGS84, "+proj=tpeqd +lat_1=0 +lon_1=0 +lat_2=60 +lon_2=60 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 54032, aeqd, WGS84, WGS84, "+proj=aeqd +lat_0=0 +lon_0=0 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 65061, poly, clrk66, NAD27, "+proj=poly +lat_0=13.47246635277778 +lon_0=-144.7487507055556 +x_0=50000.00000000001 +y_0=50000.00000000001 +ellps=clrk66 +datum=NAD27 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 65161, poly, GRS80, NAD83, "+proj=poly +lat_0=13.47246635277778 +lon_0=-144.7487507055556 +x_0=50000 +y_0=50000 +ellps=GRS80 +datum=NAD83 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102001, aea, GRS80, NAD83, "+proj=aea +lat_1=50 +lat_2=70 +lat_0=40 +lon_0=-96 +x_0=0 +y_0=0 +ellps=GRS80 +datum=NAD83 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102002, lcc, GRS80, NAD83, "+proj=lcc +lat_1=50 +lat_2=70 +lat_0=40 +lon_0=-96 +x_0=0 +y_0=0 +ellps=GRS80 +datum=NAD83 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102003, aea, GRS80, NAD83, "+proj=aea +lat_1=29.5 +lat_2=45.5 +lat_0=37.5 +lon_0=-96 +x_0=0 +y_0=0 +ellps=GRS80 +datum=NAD83 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102004, lcc, GRS80, NAD83, "+proj=lcc +lat_1=33 +lat_2=45 +lat_0=39 +lon_0=-96 +x_0=0 +y_0=0 +ellps=GRS80 +datum=NAD83 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102005, eqdc, GRS80, NAD83, "+proj=eqdc +lat_0=0 +lon_0=0 +lat_1=33 +lat_2=45 +x_0=0 +y_0=0 +ellps=GRS80 +datum=NAD83 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102006, aea, GRS80, NAD83, "+proj=aea +lat_1=55 +lat_2=65 +lat_0=50 +lon_0=-154 +x_0=0 +y_0=0 +ellps=GRS80 +datum=NAD83 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102007, aea, GRS80, NAD83, "+proj=aea +lat_1=8 +lat_2=18 +lat_0=13 +lon_0=-157 +x_0=0 +y_0=0 +ellps=GRS80 +datum=NAD83 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102008, aea, GRS80, NAD83, "+proj=aea +lat_1=20 +lat_2=60 +lat_0=40 +lon_0=-96 +x_0=0 +y_0=0 +ellps=GRS80 +datum=NAD83 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102009, lcc, GRS80, NAD83, "+proj=lcc +lat_1=20 +lat_2=60 +lat_0=40 +lon_0=-96 +x_0=0 +y_0=0 +ellps=GRS80 +datum=NAD83 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102010, eqdc, GRS80, NAD83, "+proj=eqdc +lat_0=0 +lon_0=0 +lat_1=20 +lat_2=60 +x_0=0 +y_0=0 +ellps=GRS80 +datum=NAD83 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102011, sinu, WGS84, WGS84, "+proj=sinu +lon_0=0 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102012, lcc, WGS84, WGS84, "+proj=lcc +lat_1=30 +lat_2=62 +lat_0=0 +lon_0=105 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102013, aea, intl, "+proj=aea +lat_1=43 +lat_2=62 +lat_0=30 +lon_0=10 +x_0=0 +y_0=0 +ellps=intl +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102014, lcc, intl, "+proj=lcc +lat_1=43 +lat_2=62 +lat_0=30 +lon_0=10 +x_0=0 +y_0=0 +ellps=intl +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102015, lcc, aust_SA, "+proj=lcc +lat_1=-5 +lat_2=-42 +lat_0=-32 +lon_0=-60 +x_0=0 +y_0=0 +ellps=aust_SA +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102016, aeqd, WGS84, WGS84, "+proj=aeqd +lat_0=90 +lon_0=0 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102017, laea, WGS84, WGS84, "+proj=laea +lat_0=90 +lon_0=0 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102018, stere, WGS84, WGS84, "+proj=stere +lat_0=90 +lon_0=0 +k=1 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102019, aeqd, WGS84, WGS84, "+proj=aeqd +lat_0=-90 +lon_0=0 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102020, laea, WGS84, WGS84, "+proj=laea +lat_0=-90 +lon_0=0 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102021, stere, WGS84, WGS84, "+proj=stere +lat_0=-90 +lon_0=0 +k=1 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102022, aea, WGS84, WGS84, "+proj=aea +lat_1=20 +lat_2=-23 +lat_0=0 +lon_0=25 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102023, eqdc, WGS84, WGS84, "+proj=eqdc +lat_0=0 +lon_0=0 +lat_1=20 +lat_2=-23 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102024, lcc, WGS84, WGS84, "+proj=lcc +lat_1=20 +lat_2=-23 +lat_0=0 +lon_0=25 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102025, aea, WGS84, WGS84, "+proj=aea +lat_1=15 +lat_2=65 +lat_0=30 +lon_0=95 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102026, eqdc, WGS84, WGS84, "+proj=eqdc +lat_0=0 +lon_0=0 +lat_1=15 +lat_2=65 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102027, lcc, WGS84, WGS84, "+proj=lcc +lat_1=15 +lat_2=65 +lat_0=30 +lon_0=95 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102028, aea, WGS84, WGS84, "+proj=aea +lat_1=7 +lat_2=-32 +lat_0=-15 +lon_0=125 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102029, eqdc, WGS84, WGS84, "+proj=eqdc +lat_0=0 +lon_0=0 +lat_1=7 +lat_2=-32 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102030, lcc, WGS84, WGS84, "+proj=lcc +lat_1=7 +lat_2=-32 +lat_0=-15 +lon_0=125 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102031, eqdc, intl, "+proj=eqdc +lat_0=0 +lon_0=0 +lat_1=43 +lat_2=62 +x_0=0 +y_0=0 +ellps=intl +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102032, eqdc, aust_SA, "+proj=eqdc +lat_0=0 +lon_0=0 +lat_1=-5 +lat_2=-42 +x_0=0 +y_0=0 +ellps=aust_SA +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102033, aea, aust_SA, "+proj=aea +lat_1=-5 +lat_2=-42 +lat_0=-32 +lon_0=-60 +x_0=0 +y_0=0 +ellps=aust_SA +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102065, krovak, bessel, "+proj=krovak +lat_0=49.5 +lon_0=24.83333333333333 +alpha=30.28813975277778 +k=0.9999 +x_0=0 +y_0=0 +ellps=bessel +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102066, krovak, bessel, "+proj=krovak +lat_0=49.5 +lon_0=42.5 +alpha=30.28813975277778 +k=0.9999 +x_0=0 +y_0=0 +ellps=bessel +pm=-17.66666666666667 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102067, krovak, bessel, "+proj=krovak +lat_0=49.5 +lon_0=24.83333333333333 +alpha=30.28813975277778 +k=0.9999 +x_0=0 +y_0=0 +ellps=bessel +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102091, tmerc, intl, "+proj=tmerc +lat_0=0 +lon_0=9 +k=0.9996 +x_0=1500000 +y_0=0 +ellps=intl +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102092, tmerc, intl, "+proj=tmerc +lat_0=0 +lon_0=15 +k=0.9996 +x_0=2520000 +y_0=0 +ellps=intl +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_AB(esri, 102101, tmerc, 6377492.018, 6356173.508712696, "+proj=tmerc +lat_0=58 +lon_0=6.05625 +k=1 +x_0=0 +y_0=0 +a=6377492.018 +b=6356173.508712696 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_AB(esri, 102102, tmerc, 6377492.018, 6356173.508712696, "+proj=tmerc +lat_0=58 +lon_0=8.389583333333333 +k=1 +x_0=0 +y_0=0 +a=6377492.018 +b=6356173.508712696 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_AB(esri, 102103, tmerc, 6377492.018, 6356173.508712696, "+proj=tmerc +lat_0=58 +lon_0=10.72291666666667 +k=1 +x_0=0 +y_0=0 +a=6377492.018 +b=6356173.508712696 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_AB(esri, 102104, tmerc, 6377492.018, 6356173.508712696, "+proj=tmerc +lat_0=58 +lon_0=13.22291666666667 +k=1 +x_0=0 +y_0=0 +a=6377492.018 +b=6356173.508712696 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_AB(esri, 102105, tmerc, 6377492.018, 6356173.508712696, "+proj=tmerc +lat_0=58 +lon_0=16.88958333333333 +k=1 +x_0=0 +y_0=0 +a=6377492.018 +b=6356173.508712696 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_AB(esri, 102106, tmerc, 6377492.018, 6356173.508712696, "+proj=tmerc +lat_0=58 +lon_0=20.88958333333333 +k=1 +x_0=0 +y_0=0 +a=6377492.018 +b=6356173.508712696 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_AB(esri, 102107, tmerc, 6377492.018, 6356173.508712696, "+proj=tmerc +lat_0=58 +lon_0=24.88958333333333 +k=1 +x_0=0 +y_0=0 +a=6377492.018 +b=6356173.508712696 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_AB(esri, 102108, tmerc, 6377492.018, 6356173.508712696, "+proj=tmerc +lat_0=58 +lon_0=29.05625 +k=1 +x_0=0 +y_0=0 +a=6377492.018 +b=6356173.508712696 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102110, lcc, GRS80, "+proj=lcc +lat_1=44 +lat_2=49 +lat_0=46.5 +lon_0=3 +x_0=700000 +y_0=6600000 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102114, utm, clrk66, "+proj=utm +zone=4 +ellps=clrk66 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102115, utm, clrk66, "+proj=utm +zone=5 +ellps=clrk66 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102120, omerc, clrk66, NAD27, "+proj=omerc +lat_0=45.30916666666666 +lonc=-86 +alpha=337.255555555556 +k=0.9996 +x_0=2546731.495961392 +y_0=-4354009.816002033 +ellps=clrk66 +datum=NAD27 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102121, omerc, GRS80, NAD83, "+proj=omerc +lat_0=45.30916666666666 +lonc=-86 +alpha=337.255555555556 +k=0.9996 +x_0=2546731.495961392 +y_0=-4354009.816002033 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102122, omerc, clrk66, NAD27, "+proj=omerc +lat_0=45.30916666666666 +lonc=-86 +alpha=337.255555555556 +k=0.9996 +x_0=2546731.496 +y_0=-4354009.816 +ellps=clrk66 +datum=NAD27 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102123, omerc, GRS80, NAD83, "+proj=omerc +lat_0=45.30916666666666 +lonc=-86 +alpha=337.255555555556 +k=0.9996 +x_0=2546731.496 +y_0=-4354009.816 +ellps=GRS80 +datum=NAD83 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_AB(esri, 102132, utm, 6377492.018, 6356173.508712696, "+proj=utm +zone=32 +a=6377492.018 +b=6356173.508712696 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_AB(esri, 102133, utm, 6377492.018, 6356173.508712696, "+proj=utm +zone=33 +a=6377492.018 +b=6356173.508712696 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_AB(esri, 102134, utm, 6377492.018, 6356173.508712696, "+proj=utm +zone=34 +a=6377492.018 +b=6356173.508712696 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_AB(esri, 102135, utm, 6377492.018, 6356173.508712696, "+proj=utm +zone=35 +a=6377492.018 +b=6356173.508712696 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102140, tmerc, intl, "+proj=tmerc +lat_0=22.31213333333334 +lon_0=114.1785555555556 +k=1 +x_0=836694.05 +y_0=819069.8 +ellps=intl +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102141, utm, intl, "+proj=utm +zone=49 +ellps=intl +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102142, utm, intl, "+proj=utm +zone=50 +ellps=intl +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102151, utm, bessel, "+proj=utm +zone=51 +ellps=bessel +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102152, utm, bessel, "+proj=utm +zone=52 +ellps=bessel +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102153, utm, bessel, "+proj=utm +zone=53 +ellps=bessel +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102154, utm, bessel, "+proj=utm +zone=54 +ellps=bessel +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102155, utm, bessel, "+proj=utm +zone=55 +ellps=bessel +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102156, utm, bessel, "+proj=utm +zone=56 +ellps=bessel +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102160, tmerc, intl, "+proj=tmerc +lat_0=39.66666666666666 +lon_0=-8.131906111111112 +k=1 +x_0=200180.598 +y_0=299913.01 +ellps=intl +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102161, tmerc, intl, "+proj=tmerc +lat_0=39.66666666666666 +lon_0=-8.131906111111112 +k=1 +x_0=180.598 +y_0=-86.98999999999999 +ellps=intl +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102162, utm, intl, "+proj=utm +zone=26 +ellps=intl +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102163, bonne, bessel, "+proj=bonne +lon_0=-8.131906111111112 +lat_1=39.66666666666666 +x_0=0 +y_0=0 +ellps=bessel +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102164, tmerc, intl, "+proj=tmerc +lat_0=39.66666666666666 +lon_0=-8.131906111111112 +k=1 +x_0=200000 +y_0=300000 +ellps=intl +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102165, tmerc, intl, "+proj=tmerc +lat_0=39.66666666666666 +lon_0=-8.131906111111112 +k=1 +x_0=0 +y_0=0 +ellps=intl +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102166, utm, intl, "+proj=utm +zone=25 +ellps=intl +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102167, utm, intl, "+proj=utm +zone=28 +ellps=intl +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102168, utm, intl, "+proj=utm +zone=26 +ellps=intl +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102169, utm, intl, "+proj=utm +zone=28 +ellps=intl +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_AB(esri, 102191, lcc, 6378249.2, 6356514.999904194, "+proj=lcc +lat_1=33.3 +lat_0=33.3 +lon_0=-5.4 +k_0=0.999625769 +x_0=500000 +y_0=300000 +a=6378249.2 +b=6356514.999904194 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_AB(esri, 102192, lcc, 6378249.2, 6356514.999904194, "+proj=lcc +lat_1=29.7 +lat_0=29.7 +lon_0=-5.4 +k_0=0.9996155960000001 +x_0=500000 +y_0=300000 +a=6378249.2 +b=6356514.999904194 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_AB(esri, 102193, lcc, 6378249.2, 6356514.999904194, "+proj=lcc +lat_1=26.1 +lat_0=26.1 +lon_0=-5.4 +k_0=0.9996 +x_0=1200000 +y_0=400000 +a=6378249.2 +b=6356514.999904194 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102229, tmerc, GRS80, "+proj=tmerc +lat_0=30.5 +lon_0=-85.83333333333333 +k=0.99996 +x_0=200000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102230, tmerc, GRS80, "+proj=tmerc +lat_0=30 +lon_0=-87.5 +k=0.9999333333333333 +x_0=600000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102241, lcc, GRS80, "+proj=lcc +lat_1=40 +lat_2=41.66666666666666 +lat_0=39.33333333333334 +lon_0=-122 +x_0=2000000 +y_0=500000 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102242, lcc, GRS80, "+proj=lcc +lat_1=38.33333333333334 +lat_2=39.83333333333334 +lat_0=37.66666666666666 +lon_0=-122 +x_0=2000000 +y_0=500000 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102243, lcc, GRS80, "+proj=lcc +lat_1=37.06666666666667 +lat_2=38.43333333333333 +lat_0=36.5 +lon_0=-120.5 +x_0=2000000 +y_0=500000 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102244, lcc, GRS80, "+proj=lcc +lat_1=36 +lat_2=37.25 +lat_0=35.33333333333334 +lon_0=-119 +x_0=2000000 +y_0=500000 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102245, lcc, GRS80, "+proj=lcc +lat_1=34.03333333333333 +lat_2=35.46666666666667 +lat_0=33.5 +lon_0=-118 +x_0=2000000 +y_0=500000 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102246, lcc, GRS80, "+proj=lcc +lat_1=32.78333333333333 +lat_2=33.88333333333333 +lat_0=32.16666666666666 +lon_0=-116.25 +x_0=2000000 +y_0=500000 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102248, tmerc, GRS80, "+proj=tmerc +lat_0=31 +lon_0=-110.1666666666667 +k=0.9999 +x_0=213360 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102249, tmerc, GRS80, "+proj=tmerc +lat_0=31 +lon_0=-111.9166666666667 +k=0.9999 +x_0=213360 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102250, tmerc, GRS80, "+proj=tmerc +lat_0=31 +lon_0=-113.75 +k=0.9999333333333333 +x_0=213360 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102251, lcc, GRS80, "+proj=lcc +lat_1=34.93333333333333 +lat_2=36.23333333333333 +lat_0=34.33333333333334 +lon_0=-92 +x_0=400000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102252, lcc, GRS80, "+proj=lcc +lat_1=33.3 +lat_2=34.76666666666667 +lat_0=32.66666666666666 +lon_0=-92 +x_0=400000 +y_0=400000 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102253, lcc, GRS80, "+proj=lcc +lat_1=39.71666666666667 +lat_2=40.78333333333333 +lat_0=39.33333333333334 +lon_0=-105.5 +x_0=914401.8289 +y_0=304800.6096 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102254, lcc, GRS80, "+proj=lcc +lat_1=38.45 +lat_2=39.75 +lat_0=37.83333333333334 +lon_0=-105.5 +x_0=914401.8289 +y_0=304800.6096 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102255, lcc, GRS80, "+proj=lcc +lat_1=37.23333333333333 +lat_2=38.43333333333333 +lat_0=36.66666666666666 +lon_0=-105.5 +x_0=914401.8289 +y_0=304800.6096 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102256, lcc, GRS80, "+proj=lcc +lat_1=41.2 +lat_2=41.86666666666667 +lat_0=40.83333333333334 +lon_0=-72.75 +x_0=304800.6096 +y_0=152400.3048 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102257, tmerc, GRS80, "+proj=tmerc +lat_0=38 +lon_0=-75.41666666666667 +k=0.999995 +x_0=200000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102258, tmerc, GRS80, "+proj=tmerc +lat_0=24.33333333333333 +lon_0=-81 +k=0.9999411764705882 +x_0=200000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102259, tmerc, GRS80, "+proj=tmerc +lat_0=24.33333333333333 +lon_0=-82 +k=0.9999411764705882 +x_0=200000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102260, lcc, GRS80, "+proj=lcc +lat_1=29.58333333333333 +lat_2=30.75 +lat_0=29 +lon_0=-84.5 +x_0=600000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102261, tmerc, GRS80, "+proj=tmerc +lat_0=18.83333333333333 +lon_0=-155.5 +k=0.9999666666666667 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102262, tmerc, GRS80, "+proj=tmerc +lat_0=20.33333333333333 +lon_0=-156.6666666666667 +k=0.9999666666666667 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102263, tmerc, GRS80, "+proj=tmerc +lat_0=21.16666666666667 +lon_0=-158 +k=0.99999 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102264, tmerc, GRS80, "+proj=tmerc +lat_0=21.83333333333333 +lon_0=-159.5 +k=0.99999 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102265, tmerc, GRS80, "+proj=tmerc +lat_0=21.66666666666667 +lon_0=-160.1666666666667 +k=1 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102266, tmerc, GRS80, "+proj=tmerc +lat_0=30 +lon_0=-82.16666666666667 +k=0.9999 +x_0=200000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102267, tmerc, GRS80, "+proj=tmerc +lat_0=30 +lon_0=-84.16666666666667 +k=0.9999 +x_0=700000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102268, tmerc, GRS80, "+proj=tmerc +lat_0=41.66666666666666 +lon_0=-112.1666666666667 +k=0.9999473684210526 +x_0=200000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102269, tmerc, GRS80, "+proj=tmerc +lat_0=41.66666666666666 +lon_0=-114 +k=0.9999473684210526 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102270, tmerc, GRS80, "+proj=tmerc +lat_0=41.66666666666666 +lon_0=-115.75 +k=0.9999333333333333 +x_0=800000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102271, tmerc, GRS80, "+proj=tmerc +lat_0=36.66666666666666 +lon_0=-88.33333333333333 +k=0.9999749999999999 +x_0=300000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102272, tmerc, GRS80, "+proj=tmerc +lat_0=36.66666666666666 +lon_0=-90.16666666666667 +k=0.9999411764705882 +x_0=700000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102273, tmerc, GRS80, "+proj=tmerc +lat_0=37.5 +lon_0=-85.66666666666667 +k=0.9999666666666667 +x_0=100000 +y_0=250000 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102274, tmerc, GRS80, "+proj=tmerc +lat_0=37.5 +lon_0=-87.08333333333333 +k=0.9999666666666667 +x_0=900000 +y_0=250000 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102277, lcc, GRS80, "+proj=lcc +lat_1=38.71666666666667 +lat_2=39.78333333333333 +lat_0=38.33333333333334 +lon_0=-98 +x_0=400000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102278, lcc, GRS80, "+proj=lcc +lat_1=37.26666666666667 +lat_2=38.56666666666667 +lat_0=36.66666666666666 +lon_0=-98.5 +x_0=400000 +y_0=400000 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102279, lcc, GRS80, "+proj=lcc +lat_1=37.96666666666667 +lat_2=38.96666666666667 +lat_0=37.5 +lon_0=-84.25 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102280, lcc, GRS80, "+proj=lcc +lat_1=36.73333333333333 +lat_2=37.93333333333333 +lat_0=36.33333333333334 +lon_0=-85.75 +x_0=500000 +y_0=500000 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102281, lcc, GRS80, "+proj=lcc +lat_1=31.16666666666667 +lat_2=32.66666666666666 +lat_0=30.5 +lon_0=-92.5 +x_0=1000000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102282, lcc, GRS80, "+proj=lcc +lat_1=29.3 +lat_2=30.7 +lat_0=28.5 +lon_0=-91.33333333333333 +x_0=1000000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102283, tmerc, GRS80, "+proj=tmerc +lat_0=43.66666666666666 +lon_0=-68.5 +k=0.9999 +x_0=300000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102284, tmerc, GRS80, "+proj=tmerc +lat_0=42.83333333333334 +lon_0=-70.16666666666667 +k=0.9999666666666667 +x_0=900000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102285, lcc, GRS80, "+proj=lcc +lat_1=38.3 +lat_2=39.45 +lat_0=37.66666666666666 +lon_0=-77 +x_0=400000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102286, lcc, GRS80, "+proj=lcc +lat_1=41.71666666666667 +lat_2=42.68333333333333 +lat_0=41 +lon_0=-71.5 +x_0=200000 +y_0=750000 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102287, lcc, GRS80, "+proj=lcc +lat_1=41.28333333333333 +lat_2=41.48333333333333 +lat_0=41 +lon_0=-70.5 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102288, lcc, GRS80, "+proj=lcc +lat_1=45.48333333333333 +lat_2=47.08333333333334 +lat_0=44.78333333333333 +lon_0=-87 +x_0=8000000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102289, lcc, GRS80, "+proj=lcc +lat_1=44.18333333333333 +lat_2=45.7 +lat_0=43.31666666666667 +lon_0=-84.36666666666666 +x_0=6000000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102290, lcc, GRS80, "+proj=lcc +lat_1=42.1 +lat_2=43.66666666666666 +lat_0=41.5 +lon_0=-84.36666666666666 +x_0=4000000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102291, lcc, GRS80, "+proj=lcc +lat_1=47.03333333333333 +lat_2=48.63333333333333 +lat_0=46.5 +lon_0=-93.09999999999999 +x_0=800000 +y_0=100000 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102292, lcc, GRS80, "+proj=lcc +lat_1=45.61666666666667 +lat_2=47.05 +lat_0=45 +lon_0=-94.25 +x_0=800000 +y_0=100000 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102293, lcc, GRS80, "+proj=lcc +lat_1=43.78333333333333 +lat_2=45.21666666666667 +lat_0=43 +lon_0=-94 +x_0=800000 +y_0=100000 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102294, tmerc, GRS80, "+proj=tmerc +lat_0=29.5 +lon_0=-88.83333333333333 +k=0.99995 +x_0=300000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102295, tmerc, GRS80, "+proj=tmerc +lat_0=29.5 +lon_0=-90.33333333333333 +k=0.99995 +x_0=700000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102296, tmerc, GRS80, "+proj=tmerc +lat_0=35.83333333333334 +lon_0=-90.5 +k=0.9999333333333333 +x_0=250000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102297, tmerc, GRS80, "+proj=tmerc +lat_0=35.83333333333334 +lon_0=-92.5 +k=0.9999333333333333 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102298, tmerc, GRS80, "+proj=tmerc +lat_0=36.16666666666666 +lon_0=-94.5 +k=0.9999411764705882 +x_0=850000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102300, lcc, GRS80, "+proj=lcc +lat_1=45 +lat_2=49 +lat_0=44.25 +lon_0=-109.5 +x_0=600000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102304, lcc, GRS80, "+proj=lcc +lat_1=40 +lat_2=43 +lat_0=39.83333333333334 +lon_0=-100 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102307, tmerc, GRS80, "+proj=tmerc +lat_0=34.75 +lon_0=-115.5833333333333 +k=0.9999 +x_0=200000 +y_0=8000000 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102308, tmerc, GRS80, "+proj=tmerc +lat_0=34.75 +lon_0=-116.6666666666667 +k=0.9999 +x_0=500000 +y_0=6000000 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102309, tmerc, GRS80, "+proj=tmerc +lat_0=34.75 +lon_0=-118.5833333333333 +k=0.9999 +x_0=800000 +y_0=4000000 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102310, tmerc, GRS80, "+proj=tmerc +lat_0=42.5 +lon_0=-71.66666666666667 +k=0.9999666666666667 +x_0=300000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102311, tmerc, GRS80, "+proj=tmerc +lat_0=38.83333333333334 +lon_0=-74.5 +k=0.9999 +x_0=150000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102312, tmerc, GRS80, "+proj=tmerc +lat_0=31 +lon_0=-104.3333333333333 +k=0.9999090909090909 +x_0=165000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102313, tmerc, GRS80, "+proj=tmerc +lat_0=31 +lon_0=-106.25 +k=0.9999 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102314, tmerc, GRS80, "+proj=tmerc +lat_0=31 +lon_0=-107.8333333333333 +k=0.9999166666666667 +x_0=830000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102315, tmerc, GRS80, "+proj=tmerc +lat_0=38.83333333333334 +lon_0=-74.5 +k=0.9999 +x_0=150000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102316, tmerc, GRS80, "+proj=tmerc +lat_0=40 +lon_0=-76.58333333333333 +k=0.9999375 +x_0=250000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102317, tmerc, GRS80, "+proj=tmerc +lat_0=40 +lon_0=-78.58333333333333 +k=0.9999375 +x_0=350000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102318, lcc, GRS80, "+proj=lcc +lat_1=40.66666666666666 +lat_2=41.03333333333333 +lat_0=40.16666666666666 +lon_0=-74 +x_0=300000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102320, lcc, GRS80, "+proj=lcc +lat_1=47.43333333333333 +lat_2=48.73333333333333 +lat_0=47 +lon_0=-100.5 +x_0=600000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102321, lcc, GRS80, "+proj=lcc +lat_1=46.18333333333333 +lat_2=47.48333333333333 +lat_0=45.66666666666666 +lon_0=-100.5 +x_0=600000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102322, lcc, GRS80, "+proj=lcc +lat_1=40.43333333333333 +lat_2=41.7 +lat_0=39.66666666666666 +lon_0=-82.5 +x_0=600000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102323, lcc, GRS80, "+proj=lcc +lat_1=38.73333333333333 +lat_2=40.03333333333333 +lat_0=38 +lon_0=-82.5 +x_0=600000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102324, lcc, GRS80, "+proj=lcc +lat_1=35.56666666666667 +lat_2=36.76666666666667 +lat_0=35 +lon_0=-98 +x_0=600000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102325, lcc, GRS80, "+proj=lcc +lat_1=33.93333333333333 +lat_2=35.23333333333333 +lat_0=33.33333333333334 +lon_0=-98 +x_0=600000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102326, lcc, GRS80, "+proj=lcc +lat_1=44.33333333333334 +lat_2=46 +lat_0=43.66666666666666 +lon_0=-120.5 +x_0=2500000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102327, lcc, GRS80, "+proj=lcc +lat_1=42.33333333333334 +lat_2=44 +lat_0=41.66666666666666 +lon_0=-120.5 +x_0=1500000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102330, tmerc, GRS80, "+proj=tmerc +lat_0=41.08333333333334 +lon_0=-71.5 +k=0.99999375 +x_0=100000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102334, lcc, GRS80, "+proj=lcc +lat_1=44.41666666666666 +lat_2=45.68333333333333 +lat_0=43.83333333333334 +lon_0=-100 +x_0=600000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102335, lcc, GRS80, "+proj=lcc +lat_1=42.83333333333334 +lat_2=44.4 +lat_0=42.33333333333334 +lon_0=-100.3333333333333 +x_0=600000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102336, lcc, GRS80, "+proj=lcc +lat_1=35.25 +lat_2=36.41666666666666 +lat_0=34.33333333333334 +lon_0=-86 +x_0=600000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102337, lcc, GRS80, "+proj=lcc +lat_1=34.65 +lat_2=36.18333333333333 +lat_0=34 +lon_0=-101.5 +x_0=200000 +y_0=1000000 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102338, lcc, GRS80, "+proj=lcc +lat_1=32.13333333333333 +lat_2=33.96666666666667 +lat_0=31.66666666666667 +lon_0=-98.5 +x_0=600000 +y_0=2000000 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102339, lcc, GRS80, "+proj=lcc +lat_1=30.11666666666667 +lat_2=31.88333333333333 +lat_0=29.66666666666667 +lon_0=-100.3333333333333 +x_0=700000 +y_0=3000000 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102340, lcc, GRS80, "+proj=lcc +lat_1=28.38333333333333 +lat_2=30.28333333333334 +lat_0=27.83333333333333 +lon_0=-99 +x_0=600000 +y_0=4000000 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102341, lcc, GRS80, "+proj=lcc +lat_1=26.16666666666667 +lat_2=27.83333333333333 +lat_0=25.66666666666667 +lon_0=-98.5 +x_0=300000 +y_0=5000000 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102342, lcc, GRS80, "+proj=lcc +lat_1=40.71666666666667 +lat_2=41.78333333333333 +lat_0=40.33333333333334 +lon_0=-111.5 +x_0=500000 +y_0=1000000 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102343, lcc, GRS80, "+proj=lcc +lat_1=39.01666666666667 +lat_2=40.65 +lat_0=38.33333333333334 +lon_0=-111.5 +x_0=500000 +y_0=2000000 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102344, lcc, GRS80, "+proj=lcc +lat_1=37.21666666666667 +lat_2=38.35 +lat_0=36.66666666666666 +lon_0=-111.5 +x_0=500000 +y_0=3000000 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102345, tmerc, GRS80, "+proj=tmerc +lat_0=42.5 +lon_0=-72.5 +k=0.9999642857142857 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102346, lcc, GRS80, "+proj=lcc +lat_1=38.03333333333333 +lat_2=39.2 +lat_0=37.66666666666666 +lon_0=-78.5 +x_0=3500000 +y_0=2000000 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102347, lcc, GRS80, "+proj=lcc +lat_1=36.76666666666667 +lat_2=37.96666666666667 +lat_0=36.33333333333334 +lon_0=-78.5 +x_0=3500000 +y_0=1000000 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102348, lcc, GRS80, "+proj=lcc +lat_1=47.5 +lat_2=48.73333333333333 +lat_0=47 +lon_0=-120.8333333333333 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102349, lcc, GRS80, "+proj=lcc +lat_1=45.83333333333334 +lat_2=47.33333333333334 +lat_0=45.33333333333334 +lon_0=-120.5 +x_0=500000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102350, lcc, GRS80, "+proj=lcc +lat_1=39 +lat_2=40.25 +lat_0=38.5 +lon_0=-79.5 +x_0=600000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102351, lcc, GRS80, "+proj=lcc +lat_1=37.48333333333333 +lat_2=38.88333333333333 +lat_0=37 +lon_0=-81 +x_0=600000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102352, lcc, GRS80, "+proj=lcc +lat_1=45.56666666666667 +lat_2=46.76666666666667 +lat_0=45.16666666666666 +lon_0=-90 +x_0=600000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102353, lcc, GRS80, "+proj=lcc +lat_1=44.25 +lat_2=45.5 +lat_0=43.83333333333334 +lon_0=-90 +x_0=600000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102354, lcc, GRS80, "+proj=lcc +lat_1=42.73333333333333 +lat_2=44.06666666666667 +lat_0=42 +lon_0=-90 +x_0=600000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102355, tmerc, GRS80, "+proj=tmerc +lat_0=40.5 +lon_0=-105.1666666666667 +k=0.9999375 +x_0=200000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102356, tmerc, GRS80, "+proj=tmerc +lat_0=40.5 +lon_0=-107.3333333333333 +k=0.9999375 +x_0=400000 +y_0=100000 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102357, tmerc, GRS80, "+proj=tmerc +lat_0=40.5 +lon_0=-108.75 +k=0.9999375 +x_0=600000 +y_0=0 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102358, tmerc, GRS80, "+proj=tmerc +lat_0=40.5 +lon_0=-110.0833333333333 +k=0.9999375 +x_0=800000 +y_0=100000 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102361, lcc, GRS80, "+proj=lcc +lat_1=18.03333333333334 +lat_2=18.43333333333333 +lat_0=17.83333333333333 +lon_0=-66.43333333333334 +x_0=200000 +y_0=200000 +ellps=GRS80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_AB(esri, 102491, lcc, 6378249.2, 6356514.999904194, "+proj=lcc +lat_1=36 +lat_0=36 +lon_0=2.7 +k_0=0.999625544 +x_0=500000 +y_0=300000 +a=6378249.2 +b=6356514.999904194 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_AB(esri, 102492, lcc, 6378249.2, 6356514.999904194, "+proj=lcc +lat_1=33.3 +lat_0=33.3 +lon_0=2.7 +k_0=0.999625769 +x_0=500000 +y_0=300000 +a=6378249.2 +b=6356514.999904194 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_AB(esri, 102581, lcc, 6378249.2, 6356514.999904194, "+proj=lcc +lat_1=49.5 +lat_0=49.5 +lon_0=2.337229166666667 +k_0=0.999877341 +x_0=600000 +y_0=1200000 +a=6378249.2 +b=6356514.999904194 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_AB(esri, 102582, lcc, 6378249.2, 6356514.999904194, "+proj=lcc +lat_1=46.8 +lat_0=46.8 +lon_0=2.337229166666667 +k_0=0.99987742 +x_0=600000 +y_0=2200000 +a=6378249.2 +b=6356514.999904194 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_AB(esri, 102583, lcc, 6378249.2, 6356514.999904194, "+proj=lcc +lat_1=44.1 +lat_0=44.1 +lon_0=2.337229166666667 +k_0=0.999877499 +x_0=600000 +y_0=3200000 +a=6378249.2 +b=6356514.999904194 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_AB(esri, 102584, lcc, 6378249.2, 6356514.999904194, "+proj=lcc +lat_1=42.165 +lat_0=42.165 +lon_0=2.337229166666667 +k_0=0.99994471 +x_0=234.358 +y_0=4185861.369 +a=6378249.2 +b=6356514.999904194 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102591, lcc, clrk80, "+proj=lcc +lat_1=36 +lat_0=36 +lon_0=2.7 +k_0=0.999625544 +x_0=500135 +y_0=300090 +ellps=clrk80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 102592, lcc, clrk80, "+proj=lcc +lat_1=33.3 +lat_0=33.3 +lon_0=2.7 +k_0=0.999625769 +x_0=500135 +y_0=300090 +ellps=clrk80 +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102629, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=30.5 +lon_0=-85.83333333333333 +k=0.99996 +x_0=200000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102630, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=30 +lon_0=-87.5 +k=0.9999333333333333 +x_0=600000.0000000001 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102631, omerc, GRS80, NAD83, "+proj=omerc +lat_0=57 +lonc=-133.6666666666667 +alpha=-36.86989764583333 +k=0.9999 +x_0=4999999.999999999 +y_0=-4999999.999999999 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102632, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=54 +lon_0=-142 +k=0.9999 +x_0=500000.0000000002 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102633, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=54 +lon_0=-146 +k=0.9999 +x_0=500000.0000000002 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102634, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=54 +lon_0=-150 +k=0.9999 +x_0=500000.0000000002 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102635, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=54 +lon_0=-154 +k=0.9999 +x_0=500000.0000000002 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102636, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=54 +lon_0=-158 +k=0.9999 +x_0=500000.0000000002 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102637, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=54 +lon_0=-162 +k=0.9999 +x_0=500000.0000000002 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102638, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=54 +lon_0=-166 +k=0.9999 +x_0=500000.0000000002 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102639, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=54 +lon_0=-170 +k=0.9999 +x_0=500000.0000000002 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102640, lcc, GRS80, NAD83, "+proj=lcc +lat_1=51.83333333333334 +lat_2=53.83333333333334 +lat_0=51 +lon_0=-176 +x_0=1000000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102641, lcc, GRS80, NAD83, "+proj=lcc +lat_1=40 +lat_2=41.66666666666666 +lat_0=39.33333333333334 +lon_0=-122 +x_0=2000000 +y_0=500000.0000000002 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102642, lcc, GRS80, NAD83, "+proj=lcc +lat_1=38.33333333333334 +lat_2=39.83333333333334 +lat_0=37.66666666666666 +lon_0=-122 +x_0=2000000 +y_0=500000.0000000002 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102643, lcc, GRS80, NAD83, "+proj=lcc +lat_1=37.06666666666667 +lat_2=38.43333333333333 +lat_0=36.5 +lon_0=-120.5 +x_0=2000000 +y_0=500000.0000000002 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102644, lcc, GRS80, NAD83, "+proj=lcc +lat_1=36 +lat_2=37.25 +lat_0=35.33333333333334 +lon_0=-119 +x_0=2000000 +y_0=500000.0000000002 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102645, lcc, GRS80, NAD83, "+proj=lcc +lat_1=34.03333333333333 +lat_2=35.46666666666667 +lat_0=33.5 +lon_0=-118 +x_0=2000000 +y_0=500000.0000000002 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102646, lcc, GRS80, NAD83, "+proj=lcc +lat_1=32.78333333333333 +lat_2=33.88333333333333 +lat_0=32.16666666666666 +lon_0=-116.25 +x_0=2000000 +y_0=500000.0000000002 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102648, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=31 +lon_0=-110.1666666666667 +k=0.9999 +x_0=213360 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102649, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=31 +lon_0=-111.9166666666667 +k=0.9999 +x_0=213360 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102650, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=31 +lon_0=-113.75 +k=0.9999333333333333 +x_0=213360 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102651, lcc, GRS80, NAD83, "+proj=lcc +lat_1=34.93333333333333 +lat_2=36.23333333333333 +lat_0=34.33333333333334 +lon_0=-92 +x_0=399999.9999999999 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102652, lcc, GRS80, NAD83, "+proj=lcc +lat_1=33.3 +lat_2=34.76666666666667 +lat_0=32.66666666666666 +lon_0=-92 +x_0=399999.9999999999 +y_0=399999.9999999999 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102653, lcc, GRS80, NAD83, "+proj=lcc +lat_1=39.71666666666667 +lat_2=40.78333333333333 +lat_0=39.33333333333334 +lon_0=-105.5 +x_0=914401.8289 +y_0=304800.6096 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102654, lcc, GRS80, NAD83, "+proj=lcc +lat_1=38.45 +lat_2=39.75 +lat_0=37.83333333333334 +lon_0=-105.5 +x_0=914401.8289 +y_0=304800.6096 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102655, lcc, GRS80, NAD83, "+proj=lcc +lat_1=37.23333333333333 +lat_2=38.43333333333333 +lat_0=36.66666666666666 +lon_0=-105.5 +x_0=914401.8289 +y_0=304800.6096 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102656, lcc, GRS80, NAD83, "+proj=lcc +lat_1=41.2 +lat_2=41.86666666666667 +lat_0=40.83333333333334 +lon_0=-72.75 +x_0=304800.6096 +y_0=152400.3048 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102657, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=38 +lon_0=-75.41666666666667 +k=0.999995 +x_0=200000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102658, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=24.33333333333333 +lon_0=-81 +k=0.9999411764705882 +x_0=200000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102659, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=24.33333333333333 +lon_0=-82 +k=0.9999411764705882 +x_0=200000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102660, lcc, GRS80, NAD83, "+proj=lcc +lat_1=29.58333333333333 +lat_2=30.75 +lat_0=29 +lon_0=-84.5 +x_0=600000.0000000001 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102661, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=18.83333333333333 +lon_0=-155.5 +k=0.9999666666666667 +x_0=500000.0000000002 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102662, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=20.33333333333333 +lon_0=-156.6666666666667 +k=0.9999666666666667 +x_0=500000.0000000002 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102663, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=21.16666666666667 +lon_0=-158 +k=0.99999 +x_0=500000.0000000002 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102664, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=21.83333333333333 +lon_0=-159.5 +k=0.99999 +x_0=500000.0000000002 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102665, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=21.66666666666667 +lon_0=-160.1666666666667 +k=1 +x_0=500000.0000000002 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102666, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=30 +lon_0=-82.16666666666667 +k=0.9999 +x_0=200000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102667, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=30 +lon_0=-84.16666666666667 +k=0.9999 +x_0=700000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102668, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=41.66666666666666 +lon_0=-112.1666666666667 +k=0.9999473684210526 +x_0=200000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102669, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=41.66666666666666 +lon_0=-114 +k=0.9999473684210526 +x_0=500000.0000000002 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102670, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=41.66666666666666 +lon_0=-115.75 +k=0.9999333333333333 +x_0=799999.9999999999 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102671, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=36.66666666666666 +lon_0=-88.33333333333333 +k=0.9999749999999999 +x_0=300000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102672, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=36.66666666666666 +lon_0=-90.16666666666667 +k=0.9999411764705882 +x_0=700000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102673, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=37.5 +lon_0=-85.66666666666667 +k=0.9999666666666667 +x_0=100000 +y_0=250000 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102674, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=37.5 +lon_0=-87.08333333333333 +k=0.9999666666666667 +x_0=900000.0000000001 +y_0=250000 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102675, lcc, GRS80, NAD83, "+proj=lcc +lat_1=42.06666666666667 +lat_2=43.26666666666667 +lat_0=41.5 +lon_0=-93.5 +x_0=1500000 +y_0=1000000 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102676, lcc, GRS80, NAD83, "+proj=lcc +lat_1=40.61666666666667 +lat_2=41.78333333333333 +lat_0=40 +lon_0=-93.5 +x_0=500000.0000000002 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102677, lcc, GRS80, NAD83, "+proj=lcc +lat_1=38.71666666666667 +lat_2=39.78333333333333 +lat_0=38.33333333333334 +lon_0=-98 +x_0=399999.9999999999 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102678, lcc, GRS80, NAD83, "+proj=lcc +lat_1=37.26666666666667 +lat_2=38.56666666666667 +lat_0=36.66666666666666 +lon_0=-98.5 +x_0=399999.9999999999 +y_0=399999.9999999999 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102679, lcc, GRS80, NAD83, "+proj=lcc +lat_1=37.96666666666667 +lat_2=38.96666666666667 +lat_0=37.5 +lon_0=-84.25 +x_0=500000.0000000002 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102680, lcc, GRS80, NAD83, "+proj=lcc +lat_1=36.73333333333333 +lat_2=37.93333333333333 +lat_0=36.33333333333334 +lon_0=-85.75 +x_0=500000.0000000002 +y_0=500000.0000000002 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102681, lcc, GRS80, NAD83, "+proj=lcc +lat_1=31.16666666666667 +lat_2=32.66666666666666 +lat_0=30.5 +lon_0=-92.5 +x_0=1000000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102682, lcc, GRS80, NAD83, "+proj=lcc +lat_1=29.3 +lat_2=30.7 +lat_0=28.5 +lon_0=-91.33333333333333 +x_0=1000000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102683, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=43.66666666666666 +lon_0=-68.5 +k=0.9999 +x_0=300000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102684, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=42.83333333333334 +lon_0=-70.16666666666667 +k=0.9999666666666667 +x_0=900000.0000000001 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102685, lcc, GRS80, NAD83, "+proj=lcc +lat_1=38.3 +lat_2=39.45 +lat_0=37.66666666666666 +lon_0=-77 +x_0=399999.9999999999 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102686, lcc, GRS80, NAD83, "+proj=lcc +lat_1=41.71666666666667 +lat_2=42.68333333333333 +lat_0=41 +lon_0=-71.5 +x_0=200000 +y_0=750000.0000000001 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102687, lcc, GRS80, NAD83, "+proj=lcc +lat_1=41.28333333333333 +lat_2=41.48333333333333 +lat_0=41 +lon_0=-70.5 +x_0=500000.0000000002 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102688, lcc, GRS80, NAD83, "+proj=lcc +lat_1=45.48333333333333 +lat_2=47.08333333333334 +lat_0=44.78333333333333 +lon_0=-87 +x_0=7999999.999999999 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102689, lcc, GRS80, NAD83, "+proj=lcc +lat_1=44.18333333333333 +lat_2=45.7 +lat_0=43.31666666666667 +lon_0=-84.36666666666666 +x_0=6000000.000000001 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102690, lcc, GRS80, NAD83, "+proj=lcc +lat_1=42.1 +lat_2=43.66666666666666 +lat_0=41.5 +lon_0=-84.36666666666666 +x_0=4000000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102691, lcc, GRS80, NAD83, "+proj=lcc +lat_1=47.03333333333333 +lat_2=48.63333333333333 +lat_0=46.5 +lon_0=-93.09999999999999 +x_0=799999.9999999999 +y_0=100000 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102692, lcc, GRS80, NAD83, "+proj=lcc +lat_1=45.61666666666667 +lat_2=47.05 +lat_0=45 +lon_0=-94.25 +x_0=799999.9999999999 +y_0=100000 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102693, lcc, GRS80, NAD83, "+proj=lcc +lat_1=43.78333333333333 +lat_2=45.21666666666667 +lat_0=43 +lon_0=-94 +x_0=799999.9999999999 +y_0=100000 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102694, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=29.5 +lon_0=-88.83333333333333 +k=0.99995 +x_0=300000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102695, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=29.5 +lon_0=-90.33333333333333 +k=0.99995 +x_0=700000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102696, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=35.83333333333334 +lon_0=-90.5 +k=0.9999333333333333 +x_0=250000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102697, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=35.83333333333334 +lon_0=-92.5 +k=0.9999333333333333 +x_0=500000.0000000002 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102698, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=36.16666666666666 +lon_0=-94.5 +k=0.9999411764705882 +x_0=850000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102700, lcc, GRS80, NAD83, "+proj=lcc +lat_1=45 +lat_2=49 +lat_0=44.25 +lon_0=-109.5 +x_0=600000.0000000001 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102704, lcc, GRS80, NAD83, "+proj=lcc +lat_1=40 +lat_2=43 +lat_0=39.83333333333334 +lon_0=-100 +x_0=500000.0000000002 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102707, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=34.75 +lon_0=-115.5833333333333 +k=0.9999 +x_0=200000 +y_0=7999999.999999999 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102708, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=34.75 +lon_0=-116.6666666666667 +k=0.9999 +x_0=500000.0000000002 +y_0=6000000.000000001 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102709, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=34.75 +lon_0=-118.5833333333333 +k=0.9999 +x_0=799999.9999999999 +y_0=4000000 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102710, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=42.5 +lon_0=-71.66666666666667 +k=0.9999666666666667 +x_0=300000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102711, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=38.83333333333334 +lon_0=-74.5 +k=0.9999 +x_0=150000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102712, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=31 +lon_0=-104.3333333333333 +k=0.9999090909090909 +x_0=165000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102713, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=31 +lon_0=-106.25 +k=0.9999 +x_0=500000.0000000002 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102714, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=31 +lon_0=-107.8333333333333 +k=0.9999166666666667 +x_0=829999.9999999999 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102715, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=38.83333333333334 +lon_0=-74.5 +k=0.9999 +x_0=150000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102716, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=40 +lon_0=-76.58333333333333 +k=0.9999375 +x_0=250000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102717, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=40 +lon_0=-78.58333333333333 +k=0.9999375 +x_0=350000.0000000001 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102718, lcc, GRS80, NAD83, "+proj=lcc +lat_1=40.66666666666666 +lat_2=41.03333333333333 +lat_0=40.16666666666666 +lon_0=-74 +x_0=300000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102719, lcc, GRS80, NAD83, "+proj=lcc +lat_1=34.33333333333334 +lat_2=36.16666666666666 +lat_0=33.75 +lon_0=-79 +x_0=609601.2199999999 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102720, lcc, GRS80, NAD83, "+proj=lcc +lat_1=47.43333333333333 +lat_2=48.73333333333333 +lat_0=47 +lon_0=-100.5 +x_0=600000.0000000001 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102721, lcc, GRS80, NAD83, "+proj=lcc +lat_1=46.18333333333333 +lat_2=47.48333333333333 +lat_0=45.66666666666666 +lon_0=-100.5 +x_0=600000.0000000001 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102722, lcc, GRS80, NAD83, "+proj=lcc +lat_1=40.43333333333333 +lat_2=41.7 +lat_0=39.66666666666666 +lon_0=-82.5 +x_0=600000.0000000001 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102723, lcc, GRS80, NAD83, "+proj=lcc +lat_1=38.73333333333333 +lat_2=40.03333333333333 +lat_0=38 +lon_0=-82.5 +x_0=600000.0000000001 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102724, lcc, GRS80, NAD83, "+proj=lcc +lat_1=35.56666666666667 +lat_2=36.76666666666667 +lat_0=35 +lon_0=-98 +x_0=600000.0000000001 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102725, lcc, GRS80, NAD83, "+proj=lcc +lat_1=33.93333333333333 +lat_2=35.23333333333333 +lat_0=33.33333333333334 +lon_0=-98 +x_0=600000.0000000001 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102726, lcc, GRS80, NAD83, "+proj=lcc +lat_1=44.33333333333334 +lat_2=46 +lat_0=43.66666666666666 +lon_0=-120.5 +x_0=2500000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102727, lcc, GRS80, NAD83, "+proj=lcc +lat_1=42.33333333333334 +lat_2=44 +lat_0=41.66666666666666 +lon_0=-120.5 +x_0=1500000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102728, lcc, GRS80, NAD83, "+proj=lcc +lat_1=40.88333333333333 +lat_2=41.95 +lat_0=40.16666666666666 +lon_0=-77.75 +x_0=600000.0000000001 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102729, lcc, GRS80, NAD83, "+proj=lcc +lat_1=39.93333333333333 +lat_2=40.96666666666667 +lat_0=39.33333333333334 +lon_0=-77.75 +x_0=600000.0000000001 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102730, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=41.08333333333334 +lon_0=-71.5 +k=0.99999375 +x_0=100000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102733, lcc, GRS80, NAD83, "+proj=lcc +lat_1=32.5 +lat_2=34.83333333333334 +lat_0=31.83333333333333 +lon_0=-81 +x_0=609600.0000000001 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102734, lcc, GRS80, NAD83, "+proj=lcc +lat_1=44.41666666666666 +lat_2=45.68333333333333 +lat_0=43.83333333333334 +lon_0=-100 +x_0=600000.0000000001 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102735, lcc, GRS80, NAD83, "+proj=lcc +lat_1=42.83333333333334 +lat_2=44.4 +lat_0=42.33333333333334 +lon_0=-100.3333333333333 +x_0=600000.0000000001 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102736, lcc, GRS80, NAD83, "+proj=lcc +lat_1=35.25 +lat_2=36.41666666666666 +lat_0=34.33333333333334 +lon_0=-86 +x_0=600000.0000000001 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102737, lcc, GRS80, NAD83, "+proj=lcc +lat_1=34.65 +lat_2=36.18333333333333 +lat_0=34 +lon_0=-101.5 +x_0=200000 +y_0=1000000 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102738, lcc, GRS80, NAD83, "+proj=lcc +lat_1=32.13333333333333 +lat_2=33.96666666666667 +lat_0=31.66666666666667 +lon_0=-98.5 +x_0=600000.0000000001 +y_0=2000000 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102739, lcc, GRS80, NAD83, "+proj=lcc +lat_1=30.11666666666667 +lat_2=31.88333333333333 +lat_0=29.66666666666667 +lon_0=-100.3333333333333 +x_0=700000 +y_0=3000000 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102740, lcc, GRS80, NAD83, "+proj=lcc +lat_1=28.38333333333333 +lat_2=30.28333333333334 +lat_0=27.83333333333333 +lon_0=-99 +x_0=600000.0000000001 +y_0=4000000 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102741, lcc, GRS80, NAD83, "+proj=lcc +lat_1=26.16666666666667 +lat_2=27.83333333333333 +lat_0=25.66666666666667 +lon_0=-98.5 +x_0=300000 +y_0=4999999.999999999 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102742, lcc, GRS80, NAD83, "+proj=lcc +lat_1=40.71666666666667 +lat_2=41.78333333333333 +lat_0=40.33333333333334 +lon_0=-111.5 +x_0=500000.0000000002 +y_0=1000000 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102743, lcc, GRS80, NAD83, "+proj=lcc +lat_1=39.01666666666667 +lat_2=40.65 +lat_0=38.33333333333334 +lon_0=-111.5 +x_0=500000.0000000002 +y_0=2000000 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102744, lcc, GRS80, NAD83, "+proj=lcc +lat_1=37.21666666666667 +lat_2=38.35 +lat_0=36.66666666666666 +lon_0=-111.5 +x_0=500000.0000000002 +y_0=3000000 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102745, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=42.5 +lon_0=-72.5 +k=0.9999642857142857 +x_0=500000.0000000002 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102746, lcc, GRS80, NAD83, "+proj=lcc +lat_1=38.03333333333333 +lat_2=39.2 +lat_0=37.66666666666666 +lon_0=-78.5 +x_0=3499999.999999999 +y_0=2000000 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102747, lcc, GRS80, NAD83, "+proj=lcc +lat_1=36.76666666666667 +lat_2=37.96666666666667 +lat_0=36.33333333333334 +lon_0=-78.5 +x_0=3499999.999999999 +y_0=1000000 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102748, lcc, GRS80, NAD83, "+proj=lcc +lat_1=47.5 +lat_2=48.73333333333333 +lat_0=47 +lon_0=-120.8333333333333 +x_0=500000.0000000002 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102749, lcc, GRS80, NAD83, "+proj=lcc +lat_1=45.83333333333334 +lat_2=47.33333333333334 +lat_0=45.33333333333334 +lon_0=-120.5 +x_0=500000.0000000002 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102750, lcc, GRS80, NAD83, "+proj=lcc +lat_1=39 +lat_2=40.25 +lat_0=38.5 +lon_0=-79.5 +x_0=600000.0000000001 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102751, lcc, GRS80, NAD83, "+proj=lcc +lat_1=37.48333333333333 +lat_2=38.88333333333333 +lat_0=37 +lon_0=-81 +x_0=600000.0000000001 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102752, lcc, GRS80, NAD83, "+proj=lcc +lat_1=45.56666666666667 +lat_2=46.76666666666667 +lat_0=45.16666666666666 +lon_0=-90 +x_0=600000.0000000001 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102753, lcc, GRS80, NAD83, "+proj=lcc +lat_1=44.25 +lat_2=45.5 +lat_0=43.83333333333334 +lon_0=-90 +x_0=600000.0000000001 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102754, lcc, GRS80, NAD83, "+proj=lcc +lat_1=42.73333333333333 +lat_2=44.06666666666667 +lat_0=42 +lon_0=-90 +x_0=600000.0000000001 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102755, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=40.5 +lon_0=-105.1666666666667 +k=0.9999375 +x_0=200000 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102756, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=40.5 +lon_0=-107.3333333333333 +k=0.9999375 +x_0=399999.9999999999 +y_0=100000 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102757, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=40.5 +lon_0=-108.75 +k=0.9999375 +x_0=600000.0000000001 +y_0=0 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102758, tmerc, GRS80, NAD83, "+proj=tmerc +lat_0=40.5 +lon_0=-110.0833333333333 +k=0.9999375 +x_0=799999.9999999999 +y_0=100000 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102761, lcc, GRS80, NAD83, "+proj=lcc +lat_1=18.03333333333334 +lat_2=18.43333333333333 +lat_0=17.83333333333333 +lon_0=-66.43333333333334 +x_0=200000 +y_0=200000 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 102766, poly, GRS80, NAD83, "+proj=poly +lat_0=13.47246635277778 +lon_0=-144.7487507055556 +x_0=49999.99999999999 +y_0=49999.99999999999 +ellps=GRS80 +datum=NAD83 +to_meter=0.3048006096012192 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 103300, lcc, intl, "+proj=lcc +lat_1=49.8333339 +lat_2=51.16666733333333 +lat_0=90 +lon_0=4.367486666666666 +x_0=150000.01256 +y_0=5400088.4378 +ellps=intl +units=m +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_ED(esri, 104000, longlat, clrk66, NAD27, "+proj=longlat +ellps=clrk66 +datum=NAD27 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 104101, longlat, bessel, "+proj=longlat +ellps=bessel +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 104102, longlat, bessel, "+proj=longlat +ellps=bessel +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 104103, longlat, clrk80, "+proj=longlat +ellps=clrk80 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 104104, longlat, intl, "+proj=longlat +ellps=intl +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 104105, longlat, bessel, "+proj=longlat +ellps=bessel +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 104106, longlat, intl, "+proj=longlat +ellps=intl +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 104107, longlat, GRS80, "+proj=longlat +ellps=GRS80 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 104108, longlat, GRS80, "+proj=longlat +ellps=GRS80 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_AB(esri, 104261, longlat, 6378249.2, 6356514.999904194, "+proj=longlat +a=6378249.2 +b=6356514.999904194 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_AB(esri, 104304, longlat, 6378249.2, 6356514.999904194, "+proj=longlat +a=6378249.2 +b=6356514.999904194 +no_defs")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_SRID_TRAITS_E (esri, 104305, longlat, clrk80, "+proj=longlat +ellps=clrk80 +no_defs")
} // namespace detail
#endif // DOXYGEN_NO_DETAIL
}}} // namespace boost::geometry::projections
#endif

View File

@@ -0,0 +1,97 @@
// Boost.Geometry
// Copyright (c) 2008-2012 Barend Gehrels, Amsterdam, the Netherlands.
// This file was modified by Oracle on 2017.
// Modifications copyright (c) 2017, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
#ifndef BOOST_GEOMETRY_PROJECTIONS_EXCEPTION_HPP
#define BOOST_GEOMETRY_PROJECTIONS_EXCEPTION_HPP
#include <boost/geometry/core/exception.hpp>
#include <boost/geometry/srs/projections/impl/pj_strerrno.hpp>
#include <boost/throw_exception.hpp>
namespace boost { namespace geometry
{
// TODO: make more for forward/inverse/init/setup
class projection_exception : public geometry::exception
{
public:
explicit projection_exception(int code = 0)
: m_code(code)
, m_msg(projections::detail::pj_strerrno(code))
{}
explicit projection_exception(std::string const& msg)
: m_code(0)
, m_msg(msg)
{}
projection_exception(int code, std::string const& msg)
: m_code(code)
, m_msg(msg)
{}
virtual char const* what() const throw()
{
//return "Boost.Geometry Projection exception";
return m_msg.what();
}
int code() const { return m_code; }
private :
int m_code;
std::runtime_error m_msg;
};
struct projection_not_named_exception
: projection_exception
{
projection_not_named_exception()
: projection_exception(-4)
{}
};
struct projection_unknown_id_exception
: projection_exception
{
projection_unknown_id_exception(std::string const& proj_name)
: projection_exception(-5, msg(proj_name))
{}
private:
static std::string msg(std::string const& proj_name)
{
return projections::detail::pj_strerrno(-5) + " (" + proj_name + ")";
}
};
struct projection_not_invertible_exception
: projection_exception
{
projection_not_invertible_exception(std::string const& proj_name)
: projection_exception(-17, msg(proj_name))
{}
private:
static std::string msg(std::string const& proj_name)
{
return std::string("projection (") + proj_name + ") is not invertible";
}
};
}} // namespace boost::geometry
#endif // BOOST_GEOMETRY_PROJECTIONS_EXCEPTION_HPP

View File

@@ -0,0 +1,282 @@
// Boost.Geometry (aka GGL, Generic Geometry Library)
// Copyright (c) 2008-2012 Barend Gehrels, Amsterdam, the Netherlands.
// This file was modified by Oracle on 2017.
// Modifications copyright (c) 2017, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
#ifndef BOOST_GEOMETRY_PROJECTIONS_FACTORY_HPP
#define BOOST_GEOMETRY_PROJECTIONS_FACTORY_HPP
#include <map>
#include <string>
#include <boost/shared_ptr.hpp>
#include <boost/geometry/srs/projections/impl/factory_entry.hpp>
#include <boost/geometry/srs/projections/proj/aea.hpp>
#include <boost/geometry/srs/projections/proj/aeqd.hpp>
#include <boost/geometry/srs/projections/proj/airy.hpp>
#include <boost/geometry/srs/projections/proj/aitoff.hpp>
#include <boost/geometry/srs/projections/proj/august.hpp>
#include <boost/geometry/srs/projections/proj/bacon.hpp>
#include <boost/geometry/srs/projections/proj/bipc.hpp>
#include <boost/geometry/srs/projections/proj/boggs.hpp>
#include <boost/geometry/srs/projections/proj/bonne.hpp>
#include <boost/geometry/srs/projections/proj/cass.hpp>
#include <boost/geometry/srs/projections/proj/cc.hpp>
#include <boost/geometry/srs/projections/proj/cea.hpp>
#include <boost/geometry/srs/projections/proj/chamb.hpp>
#include <boost/geometry/srs/projections/proj/collg.hpp>
#include <boost/geometry/srs/projections/proj/crast.hpp>
#include <boost/geometry/srs/projections/proj/denoy.hpp>
#include <boost/geometry/srs/projections/proj/eck1.hpp>
#include <boost/geometry/srs/projections/proj/eck2.hpp>
#include <boost/geometry/srs/projections/proj/eck3.hpp>
#include <boost/geometry/srs/projections/proj/eck4.hpp>
#include <boost/geometry/srs/projections/proj/eck5.hpp>
#include <boost/geometry/srs/projections/proj/eqc.hpp>
#include <boost/geometry/srs/projections/proj/eqdc.hpp>
#include <boost/geometry/srs/projections/proj/etmerc.hpp>
#include <boost/geometry/srs/projections/proj/fahey.hpp>
#include <boost/geometry/srs/projections/proj/fouc_s.hpp>
#include <boost/geometry/srs/projections/proj/gall.hpp>
#include <boost/geometry/srs/projections/proj/geocent.hpp>
#include <boost/geometry/srs/projections/proj/geos.hpp>
#include <boost/geometry/srs/projections/proj/gins8.hpp>
#include <boost/geometry/srs/projections/proj/gn_sinu.hpp>
#include <boost/geometry/srs/projections/proj/gnom.hpp>
#include <boost/geometry/srs/projections/proj/goode.hpp>
#include <boost/geometry/srs/projections/proj/gstmerc.hpp>
#include <boost/geometry/srs/projections/proj/hammer.hpp>
#include <boost/geometry/srs/projections/proj/hatano.hpp>
#include <boost/geometry/srs/projections/proj/healpix.hpp>
#include <boost/geometry/srs/projections/proj/krovak.hpp>
#include <boost/geometry/srs/projections/proj/igh.hpp>
#include <boost/geometry/srs/projections/proj/imw_p.hpp>
#include <boost/geometry/srs/projections/proj/isea.hpp>
#include <boost/geometry/srs/projections/proj/laea.hpp>
#include <boost/geometry/srs/projections/proj/labrd.hpp>
#include <boost/geometry/srs/projections/proj/lagrng.hpp>
#include <boost/geometry/srs/projections/proj/larr.hpp>
#include <boost/geometry/srs/projections/proj/lask.hpp>
#include <boost/geometry/srs/projections/proj/latlong.hpp>
#include <boost/geometry/srs/projections/proj/lcc.hpp>
#include <boost/geometry/srs/projections/proj/lcca.hpp>
#include <boost/geometry/srs/projections/proj/loxim.hpp>
#include <boost/geometry/srs/projections/proj/lsat.hpp>
#include <boost/geometry/srs/projections/proj/mbtfpp.hpp>
#include <boost/geometry/srs/projections/proj/mbtfpq.hpp>
#include <boost/geometry/srs/projections/proj/mbt_fps.hpp>
#include <boost/geometry/srs/projections/proj/merc.hpp>
#include <boost/geometry/srs/projections/proj/mill.hpp>
#include <boost/geometry/srs/projections/proj/mod_ster.hpp>
#include <boost/geometry/srs/projections/proj/moll.hpp>
#include <boost/geometry/srs/projections/proj/natearth.hpp>
#include <boost/geometry/srs/projections/proj/nell.hpp>
#include <boost/geometry/srs/projections/proj/nell_h.hpp>
#include <boost/geometry/srs/projections/proj/nocol.hpp>
#include <boost/geometry/srs/projections/proj/nsper.hpp>
#include <boost/geometry/srs/projections/proj/nzmg.hpp>
#include <boost/geometry/srs/projections/proj/ob_tran.hpp>
#include <boost/geometry/srs/projections/proj/ocea.hpp>
#include <boost/geometry/srs/projections/proj/oea.hpp>
#include <boost/geometry/srs/projections/proj/omerc.hpp>
#include <boost/geometry/srs/projections/proj/ortho.hpp>
#include <boost/geometry/srs/projections/proj/qsc.hpp>
#include <boost/geometry/srs/projections/proj/poly.hpp>
#include <boost/geometry/srs/projections/proj/putp2.hpp>
#include <boost/geometry/srs/projections/proj/putp3.hpp>
#include <boost/geometry/srs/projections/proj/putp4p.hpp>
#include <boost/geometry/srs/projections/proj/putp5.hpp>
#include <boost/geometry/srs/projections/proj/putp6.hpp>
#include <boost/geometry/srs/projections/proj/robin.hpp>
#include <boost/geometry/srs/projections/proj/rouss.hpp>
#include <boost/geometry/srs/projections/proj/rpoly.hpp>
#include <boost/geometry/srs/projections/proj/sconics.hpp>
#include <boost/geometry/srs/projections/proj/somerc.hpp>
#include <boost/geometry/srs/projections/proj/stere.hpp>
#include <boost/geometry/srs/projections/proj/sterea.hpp>
#include <boost/geometry/srs/projections/proj/sts.hpp>
#include <boost/geometry/srs/projections/proj/tcc.hpp>
#include <boost/geometry/srs/projections/proj/tcea.hpp>
#include <boost/geometry/srs/projections/proj/tmerc.hpp>
#include <boost/geometry/srs/projections/proj/tpeqd.hpp>
#include <boost/geometry/srs/projections/proj/urm5.hpp>
#include <boost/geometry/srs/projections/proj/urmfps.hpp>
#include <boost/geometry/srs/projections/proj/vandg.hpp>
#include <boost/geometry/srs/projections/proj/vandg2.hpp>
#include <boost/geometry/srs/projections/proj/vandg4.hpp>
#include <boost/geometry/srs/projections/proj/wag2.hpp>
#include <boost/geometry/srs/projections/proj/wag3.hpp>
#include <boost/geometry/srs/projections/proj/wag7.hpp>
#include <boost/geometry/srs/projections/proj/wink1.hpp>
#include <boost/geometry/srs/projections/proj/wink2.hpp>
namespace boost { namespace geometry { namespace projections
{
namespace detail
{
template <typename CT, typename Parameters>
class factory : public detail::base_factory<CT, Parameters>
{
private:
typedef std::map
<
std::string,
boost::shared_ptr
<
detail::factory_entry
<
CT,
Parameters
>
>
> prj_registry;
prj_registry m_registry;
public:
factory()
{
detail::aea_init(*this);
detail::aeqd_init(*this);
detail::airy_init(*this);
detail::aitoff_init(*this);
detail::august_init(*this);
detail::bacon_init(*this);
detail::bipc_init(*this);
detail::boggs_init(*this);
detail::bonne_init(*this);
detail::cass_init(*this);
detail::cc_init(*this);
detail::cea_init(*this);
detail::chamb_init(*this);
detail::collg_init(*this);
detail::crast_init(*this);
detail::denoy_init(*this);
detail::eck1_init(*this);
detail::eck2_init(*this);
detail::eck3_init(*this);
detail::eck4_init(*this);
detail::eck5_init(*this);
detail::eqc_init(*this);
detail::eqdc_init(*this);
detail::etmerc_init(*this);
detail::fahey_init(*this);
detail::fouc_s_init(*this);
detail::gall_init(*this);
detail::geocent_init(*this);
detail::geos_init(*this);
detail::gins8_init(*this);
detail::gn_sinu_init(*this);
detail::gnom_init(*this);
detail::goode_init(*this);
detail::gstmerc_init(*this);
detail::hammer_init(*this);
detail::hatano_init(*this);
detail::healpix_init(*this);
detail::krovak_init(*this);
detail::igh_init(*this);
detail::imw_p_init(*this);
detail::isea_init(*this);
detail::labrd_init(*this);
detail::laea_init(*this);
detail::lagrng_init(*this);
detail::larr_init(*this);
detail::lask_init(*this);
detail::latlong_init(*this);
detail::lcc_init(*this);
detail::lcca_init(*this);
detail::loxim_init(*this);
detail::lsat_init(*this);
detail::mbtfpp_init(*this);
detail::mbtfpq_init(*this);
detail::mbt_fps_init(*this);
detail::merc_init(*this);
detail::mill_init(*this);
detail::mod_ster_init(*this);
detail::moll_init(*this);
detail::natearth_init(*this);
detail::nell_init(*this);
detail::nell_h_init(*this);
detail::nocol_init(*this);
detail::nsper_init(*this);
detail::nzmg_init(*this);
detail::ob_tran_init(*this);
detail::ocea_init(*this);
detail::oea_init(*this);
detail::omerc_init(*this);
detail::ortho_init(*this);
detail::qsc_init(*this);
detail::poly_init(*this);
detail::putp2_init(*this);
detail::putp3_init(*this);
detail::putp4p_init(*this);
detail::putp5_init(*this);
detail::putp6_init(*this);
detail::robin_init(*this);
detail::rouss_init(*this);
detail::rpoly_init(*this);
detail::sconics_init(*this);
detail::somerc_init(*this);
detail::stere_init(*this);
detail::sterea_init(*this);
detail::sts_init(*this);
detail::tcc_init(*this);
detail::tcea_init(*this);
detail::tmerc_init(*this);
detail::tpeqd_init(*this);
detail::urm5_init(*this);
detail::urmfps_init(*this);
detail::vandg_init(*this);
detail::vandg2_init(*this);
detail::vandg4_init(*this);
detail::wag2_init(*this);
detail::wag3_init(*this);
detail::wag7_init(*this);
detail::wink1_init(*this);
detail::wink2_init(*this);
}
virtual ~factory() {}
virtual void add_to_factory(std::string const& name,
detail::factory_entry<CT, Parameters>* sub)
{
m_registry[name].reset(sub);
}
inline detail::base_v<CT, Parameters>* create_new(Parameters const& parameters) const
{
typename prj_registry::const_iterator it = m_registry.find(parameters.name);
if (it != m_registry.end())
{
return it->second->create_new(parameters);
}
return 0;
}
};
template <typename CT>
inline detail::base_v<CT, projections::parameters<CT> >*
create_new(projections::parameters<CT> const& parameters)
{
static factory<CT, projections::parameters<CT> > fac;
return fac.create_new(parameters);
}
} // namespace detail
}}} // namespace boost::geometry::projections
#endif // BOOST_GEOMETRY_PROJECTIONS_FACTORY_HPP

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,48 @@
// Boost.Geometry
// Copyright (c) 2017, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
#ifndef BOOST_GEOMETRY_SRS_PROJECTIONS_IAU2000_PARAMS_HPP
#define BOOST_GEOMETRY_SRS_PROJECTIONS_IAU2000_PARAMS_HPP
#include <string>
#include <boost/geometry/srs/spheroid.hpp>
namespace boost { namespace geometry
{
namespace srs
{
struct iau2000
{
explicit iau2000(int c)
: code(c)
{}
int code;
};
template <int Code>
struct static_iau2000
{
static const int code = Code;
};
} // namespace srs
}} // namespace boost::geometry
#endif // BOOST_GEOMETRY_SRS_PROJECTIONS_IAU2000_PARAMS_HPP

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,114 @@
// Boost.Geometry (aka GGL, Generic Geometry Library)
// This file is manually converted from PROJ4
// Copyright (c) 2008-2012 Barend Gehrels, Amsterdam, the Netherlands.
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
// This file is converted from PROJ4, http://trac.osgeo.org/proj
// PROJ4 is originally written by Gerald Evenden (then of the USGS)
// PROJ4 is maintained by Frank Warmerdam
// PROJ4 is converted to Geometry Library by Barend Gehrels (Geodan, Amsterdam)
// Original copyright notice:
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the "Software"),
// to deal in the Software without restriction, including without limitation
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
// and/or sell copies of the Software, and to permit persons to whom the
// Software is furnished to do so, subject to the following conditions:
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Software.
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.
#ifndef BOOST_GEOMETRY_PROJECTIONS_IMPL_AASINCOS_HPP
#define BOOST_GEOMETRY_PROJECTIONS_IMPL_AASINCOS_HPP
#include <cmath>
#include <boost/geometry/util/math.hpp>
namespace boost { namespace geometry { namespace projections
{
namespace detail
{
namespace aasincos
{
template <typename T>
inline T ONE_TOL() { return 1.00000000000001; }
//template <typename T>
//inline T TOL() { return 0.000000001; }
template <typename T>
inline T ATOL() { return 1e-50; }
}
template <typename T>
inline T aasin(T const& v)
{
T av = 0;
if ((av = geometry::math::abs(v)) >= 1.0)
{
if (av > aasincos::ONE_TOL<T>())
{
BOOST_THROW_EXCEPTION( projection_exception(-19) );
}
return (v < 0.0 ? -geometry::math::half_pi<T>() : geometry::math::half_pi<T>());
}
return asin(v);
}
template <typename T>
inline T aacos(T const& v)
{
T av = 0;
if ((av = geometry::math::abs(v)) >= 1.0)
{
if (av > aasincos::ONE_TOL<T>())
{
BOOST_THROW_EXCEPTION( projection_exception(-19) );
}
return (v < 0.0 ? geometry::math::pi<T>() : 0.0);
}
return acos(v);
}
template <typename T>
inline T asqrt(T const& v)
{
return ((v <= 0) ? 0 : sqrt(v));
}
template <typename T>
inline T aatan2(T const& n, T const& d)
{
return ((geometry::math::abs(n) < aasincos::ATOL<T>()
&& geometry::math::abs(d) < aasincos::ATOL<T>()) ? 0.0 : atan2(n, d));
}
} // namespace detail
}}} // namespace boost::geometry::projections
#endif // BOOST_GEOMETRY_PROJECTIONS_IMPL_AASINCOS_HPP

View File

@@ -0,0 +1,70 @@
// Boost.Geometry (aka GGL, Generic Geometry Library)
// This file is manually converted from PROJ4
// Copyright (c) 2008-2012 Barend Gehrels, Amsterdam, the Netherlands.
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
// This file is converted from PROJ4, http://trac.osgeo.org/proj
// PROJ4 is originally written by Gerald Evenden (then of the USGS)
// PROJ4 is maintained by Frank Warmerdam
// PROJ4 is converted to Geometry Library by Barend Gehrels (Geodan, Amsterdam)
// Original copyright notice:
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the "Software"),
// to deal in the Software without restriction, including without limitation
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
// and/or sell copies of the Software, and to permit persons to whom the
// Software is furnished to do so, subject to the following conditions:
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Software.
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.
#ifndef BOOST_GEOMETRY_PROJECTIONS_IMPL_ADJLON_HPP
#define BOOST_GEOMETRY_PROJECTIONS_IMPL_ADJLON_HPP
#include <boost/math/constants/constants.hpp>
#include <boost/geometry/util/math.hpp>
namespace boost { namespace geometry { namespace projections
{
namespace detail
{
/* reduce argument to range +/- PI */
template <typename T>
inline T adjlon (T lon)
{
if (geometry::math::abs(lon) <= boost::math::constants::pi<T>())
{
return lon;
}
/* adjust to 0..2pi rad */
lon += boost::math::constants::pi<T>();
/* remove integral # of 'revolutions'*/
lon -= boost::math::constants::two_pi<T>() *
std::floor(lon / boost::math::constants::two_pi<T>());
/* adjust back to -pi..pi rad */
lon -= boost::math::constants::pi<T>();
return lon;
}
} // namespace detail
}}} // namespace boost::geometry::projections
#endif // BOOST_GEOMETRY_PROJECTIONS_IMPL_ADJLON_HPP

View File

@@ -0,0 +1,151 @@
// Boost.Geometry (aka GGL, Generic Geometry Library)
// Copyright (c) 2007-2012 Barend Gehrels, Amsterdam, the Netherlands.
// This file was modified by Oracle on 2017.
// Modifications copyright (c) 2017, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
#ifndef BOOST_GEOMETRY_PROJECTIONS_IMPL_BASE_DYNAMIC_HPP
#define BOOST_GEOMETRY_PROJECTIONS_IMPL_BASE_DYNAMIC_HPP
#include <string>
#include <boost/geometry/srs/projections/impl/projects.hpp>
namespace boost { namespace geometry { namespace projections
{
#ifndef DOXYGEN_NO_DETAIL
namespace detail
{
/*!
\brief projection virtual base class
\details class containing virtual methods
\ingroup projection
\tparam CT calculation type
\tparam P parameters type
*/
template <typename CT, typename P>
class base_v
{
public :
/// Forward projection, from Latitude-Longitude to Cartesian
template <typename LL, typename XY>
inline bool forward(LL const& lp, XY& xy) const
{
try
{
pj_fwd(*this, this->params(), lp, xy);
return true;
}
catch (...)
{
return false;
}
}
/// Inverse projection, from Cartesian to Latitude-Longitude
template <typename LL, typename XY>
inline bool inverse(XY const& xy, LL& lp) const
{
try
{
pj_inv(*this, this->params(), xy, lp);
return true;
}
catch (projection_not_invertible_exception &)
{
BOOST_RETHROW
}
catch (...)
{
return false;
}
}
/// Forward projection using lon / lat and x / y separately
virtual void fwd(CT& lp_lon, CT& lp_lat, CT& xy_x, CT& xy_y) const = 0;
/// Inverse projection using x / y and lon / lat
virtual void inv(CT& xy_x, CT& xy_y, CT& lp_lon, CT& lp_lat) const = 0;
/// Returns name of projection
virtual std::string name() const = 0;
/// Returns parameters of projection
virtual P const& params() const = 0;
/// Returns mutable parameters of projection
virtual P& mutable_params() = 0;
virtual ~base_v() {}
};
// Base-virtual-forward
template <typename Prj, typename CT, typename P>
class base_v_f : public base_v<CT, P>
{
public:
base_v_f(P const& params)
: m_proj(params)
{}
template <typename ProjP>
base_v_f(P const& params, ProjP const& proj_params)
: m_proj(params, proj_params)
{}
virtual void fwd(CT& lp_lon, CT& lp_lat, CT& xy_x, CT& xy_y) const
{
m_proj.fwd(lp_lon, lp_lat, xy_x, xy_y);
}
virtual void inv(CT& , CT& , CT& , CT& ) const
{
BOOST_THROW_EXCEPTION(projection_not_invertible_exception(params().name));
}
virtual std::string name() const { return m_proj.name(); }
virtual P const& params() const { return m_proj.params(); }
virtual P& mutable_params() { return m_proj.mutable_params(); }
protected:
Prj m_proj;
};
// Base-virtual-forward/inverse
template <typename Prj, typename CT, typename P>
class base_v_fi : public base_v_f<Prj, CT, P>
{
typedef base_v_f<Prj, CT, P> base_t;
public:
base_v_fi(P const& params)
: base_t(params)
{}
template <typename ProjP>
base_v_fi(P const& params, ProjP const& proj_params)
: base_t(params, proj_params)
{}
virtual void inv(CT& xy_x, CT& xy_y, CT& lp_lon, CT& lp_lat) const
{
this->m_proj.inv(xy_x, xy_y, lp_lon, lp_lat);
}
};
} // namespace detail
#endif // DOXYGEN_NO_DETAIL
}}} // namespace boost::geometry::projections
#endif // BOOST_GEOMETRY_PROJECTIONS_IMPL_BASE_DYNAMIC_HPP

View File

@@ -0,0 +1,139 @@
// Boost.Geometry (aka GGL, Generic Geometry Library)
// Copyright (c) 2007-2012 Barend Gehrels, Amsterdam, the Netherlands.
// This file was modified by Oracle on 2017.
// Modifications copyright (c) 2017, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
#ifndef BOOST_GEOMETRY_PROJECTIONS_IMPL_BASE_STATIC_HPP
#define BOOST_GEOMETRY_PROJECTIONS_IMPL_BASE_STATIC_HPP
#if defined(_MSC_VER)
// For CRTP, *this is acceptable in constructor -> turn warning off
#pragma warning( disable : 4355 )
#endif // defined(_MSC_VER)
#include <string>
#include <boost/geometry/core/tags.hpp>
#include <boost/geometry/srs/projections/impl/pj_fwd.hpp>
#include <boost/geometry/srs/projections/impl/pj_inv.hpp>
#include <boost/mpl/assert.hpp>
namespace boost { namespace geometry { namespace projections
{
#ifndef DOXYGEN_NO_DETAIL
namespace detail
{
template <typename Prj, typename CSTag, typename BGP, typename CT, typename P>
struct static_projection_type
{
BOOST_MPL_ASSERT_MSG((false),
NOT_IMPLEMENTED_FOR_THIS_PROJECTION_OR_CSTAG,
(Prj, CSTag));
};
#define BOOST_GEOMETRY_PROJECTIONS_DETAIL_STATIC_PROJECTION(PROJ, P_SPHERE, P_SPHEROID) \
template <typename BGP, typename CT, typename P> \
struct static_projection_type<PROJ, srs_sphere_tag, BGP, CT, P> \
{ \
typedef P_SPHERE<CT, P> type; \
}; \
template <typename BGP, typename CT, typename P> \
struct static_projection_type<PROJ, srs_spheroid_tag, BGP, CT, P> \
{ \
typedef P_SPHEROID<CT, P> type; \
}; \
// Base-template-forward
template <typename Prj, typename CT, typename P>
struct base_t_f
{
public:
inline base_t_f(Prj const& prj, P const& params)
: m_par(params), m_prj(prj)
{}
inline P const& params() const { return m_par; }
inline P& mutable_params() { return m_par; }
template <typename LL, typename XY>
inline bool forward(LL const& lp, XY& xy) const
{
try
{
pj_fwd(m_prj, m_par, lp, xy);
return true;
}
catch(...)
{
return false;
}
}
template <typename XY, typename LL>
inline bool inverse(XY const& , LL& ) const
{
BOOST_MPL_ASSERT_MSG((false),
PROJECTION_IS_NOT_INVERTABLE,
(Prj));
return false;
}
inline std::string name() const
{
return this->m_par.name;
}
protected:
P m_par;
const Prj& m_prj;
};
// Base-template-forward/inverse
template <typename Prj, typename CT, typename P>
struct base_t_fi : public base_t_f<Prj, CT, P>
{
public :
inline base_t_fi(Prj const& prj, P const& params)
: base_t_f<Prj, CT, P>(prj, params)
{}
template <typename XY, typename LL>
inline bool inverse(XY const& xy, LL& lp) const
{
try
{
pj_inv(this->m_prj, this->m_par, xy, lp);
return true;
}
catch(...)
{
return false;
}
}
};
} // namespace detail
#endif // DOXYGEN_NO_DETAIL
}}} // namespace boost::geometry::projections
#endif // BOOST_GEOMETRY_PROJECTIONS_IMPL_BASE_STATIC_HPP

View File

@@ -0,0 +1,265 @@
// Boost.Geometry (aka GGL, Generic Geometry Library)
// Copyright (c) 2007-2012 Barend Gehrels, Amsterdam, the Netherlands.
// This file was modified by Oracle on 2017.
// Modifications copyright (c) 2017, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
#ifndef BOOST_GEOMETRY_SRS_PROJECTIONS_IMPL_DMS_PARSER_HPP
#define BOOST_GEOMETRY_SRS_PROJECTIONS_IMPL_DMS_PARSER_HPP
// This file is totally revised from PROJ4 dmstor.c
// PROJ4 is originally written by Gerald Evenden (then of the USGS)
// PROJ4 is maintained by Frank Warmerdam
// PROJ4 is converted to Geometry Library by Barend Gehrels (Geodan, Amsterdam)
// Original copyright notice:
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the "Software"),
// to deal in the Software without restriction, including without limitation
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
// and/or sell copies of the Software, and to permit persons to whom the
// Software is furnished to do so, subject to the following conditions:
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Software.
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.
#include <string>
#include <boost/static_assert.hpp>
#if !defined(BOOST_GEOMETRY_NO_LEXICAL_CAST)
#include <boost/lexical_cast.hpp>
#endif // !defined(BOOST_GEOMETRY_NO_LEXICAL_CAST)
#include <boost/algorithm/string.hpp>
#include <boost/geometry/core/cs.hpp>
#include <boost/geometry/util/math.hpp>
namespace boost { namespace geometry { namespace projections
{
namespace detail
{
template <typename T>
struct dms_result
{
enum axis_selector {axis_lat = 1, axis_lon = 0};
private :
T m_angle;
axis_selector m_axis;
public :
explicit dms_result(T const& v, axis_selector ax)
: m_angle(v)
, m_axis(ax)
{}
inline axis_selector axis() const { return m_axis; }
inline T angle() const { return m_angle; }
template <typename CH, typename TR>
inline friend std::basic_ostream<CH, TR>& operator<<(std::basic_ostream<CH, TR>& os,
const dms_result& d)
{
os << d.m_angle;
return os;
}
};
template <typename T
, bool as_radian = true
, char N = 'N', char E = 'E', char S = 'S', char W = 'W' // translatable
, char MIN = '\'', char SEC = '"' // other char's possible
, char D = 'D', char R = 'R' // degree sign might be small o
>
struct dms_parser
{
// Question from Barend: can we compile-time select that it is case-sensitive/case-insensitive?
// We have to change the switch then -> specializations
// For now: make it (compile-time) case sensitive
static const int diff = 'a' - 'A';
#ifndef __GNUC__
BOOST_STATIC_ASSERT((diff > 0)); // make sure we've the right assumption. GCC does not accept this here.
#endif
static const char n_alter = N <= 'Z' ? N + diff : N - diff;
static const char e_alter = E <= 'Z' ? E + diff : E - diff;
static const char s_alter = S <= 'Z' ? S + diff : S - diff;
static const char w_alter = W <= 'Z' ? W + diff : W - diff;
static const char r_alter = R <= 'Z' ? R + diff : R - diff;
// degree is normally D (proj4) but might be superscript o
// Note d_alter is not correct then, so map it to NULL now, guarded by the while
static const char d_alter =
((D >= 'A' && D <= 'Z') || (D >= 'a' && D <= 'z')) ? (D <= 'Z' ? D + diff : D - diff) : '\0';
struct dms_value
{
T dms[3];
bool has_dms[3];
dms_value()
{
memset(this, 0, sizeof(dms_value));
}
};
template <size_t I>
static inline void assign_dms(dms_value& dms, std::string& value, bool& has_value)
{
#if !defined(BOOST_GEOMETRY_NO_LEXICAL_CAST)
dms.dms[I] = boost::lexical_cast<T>(value.c_str());
#else // !defined(BOOST_GEOMETRY_NO_LEXICAL_CAST)
dms.dms[I] = std::atof(value.c_str());
#endif // !defined(BOOST_GEOMETRY_NO_LEXICAL_CAST)
dms.has_dms[I] = true;
has_value = false;
value.clear();
}
static inline void process(dms_value& dms, std::string& value, bool& has_value)
{
if (has_value)
{
// Assign last one, sequentially
if (! dms.has_dms[0]) assign_dms<0>(dms, value, has_value);
else if (! dms.has_dms[1]) assign_dms<1>(dms, value, has_value);
else if (! dms.has_dms[2]) assign_dms<2>(dms, value, has_value);
}
}
dms_result<T> apply(const char* is) const
{
dms_value dms;
bool has_value = false;
std::string value;
T factor = 1.0; // + denotes N/E values, -1 denotes S/W values
typename dms_result<T>::axis_selector axis = dms_result<T>::axis_lon; // true denotes N/S values
bool in_radian = false; // true denotes values as "0.1R"
while(*is)
{
switch(*is)
{
case '-' :
if (! has_value && ! dms.has_dms[0])
{
factor = -factor;
}
break;
case N :
case n_alter :
axis = dms_result<T>::axis_lat;
break;
case S :
case s_alter :
axis = dms_result<T>::axis_lat;
factor = -factor;
break;
case E :
case e_alter :
axis = dms_result<T>::axis_lon;
break;
case W :
case w_alter :
axis = dms_result<T>::axis_lon;
factor = -factor;
break;
case D :
case d_alter :
if (! dms.has_dms[0] && has_value)
{
assign_dms<0>(dms, value, has_value);
}
break;
case R :
case r_alter :
if (! dms.has_dms[0] && has_value)
{
// specified value is in radian!
in_radian = true;
assign_dms<0>(dms, value, has_value);
}
break;
case MIN:
if (! dms.has_dms[1] && has_value)
{
assign_dms<1>(dms, value, has_value);
}
break;
case SEC :
if (! dms.has_dms[2] && has_value)
{
assign_dms<2>(dms, value, has_value);
}
break;
case ' ' :
case '\t' :
case '\n' :
process(dms, value, has_value);
break;
default :
value += *is;
has_value = true;
break;
}
is++;
}
// Assign last one, if any
process(dms, value, has_value);
T const d2r = math::d2r<T>();
T const r2d = math::r2d<T>();
return dms_result<T>(factor *
(in_radian && as_radian
? dms.dms[0]
: in_radian && ! as_radian
? dms.dms[0] * r2d
: ! in_radian && as_radian
? dms.dms[0] * d2r + dms.dms[1] * d2r / 60.0 + dms.dms[2] * d2r / 3600.0
: dms.dms[0] + dms.dms[1] / 60.0 + dms.dms[2] / 3600.0)
, axis);
}
};
} // namespace detail
}}} // namespace boost::geometry::projections
#endif // BOOST_GEOMETRY_SRS_PROJECTIONS_IMPL_DMS_PARSER_HPP

View File

@@ -0,0 +1,51 @@
// Boost.Geometry (aka GGL, Generic Geometry Library)
// Copyright (c) 2007-2012 Barend Gehrels, Amsterdam, the Netherlands.
// This file was modified by Oracle on 2017.
// Modifications copyright (c) 2017, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
#ifndef BOOST_GEOMETRY_PROJECTIONS_IMPL_FACTORY_ENTRY_HPP
#define BOOST_GEOMETRY_PROJECTIONS_IMPL_FACTORY_ENTRY_HPP
#include <string>
#include <boost/geometry/srs/projections/impl/base_dynamic.hpp>
namespace boost { namespace geometry { namespace projections
{
namespace detail
{
// forward declaration needed by some projections
template <typename CT, typename Parameters>
class factory;
template <typename CT, typename P>
class factory_entry
{
public:
virtual ~factory_entry() {}
virtual base_v<CT, P>* create_new(P const& par) const = 0;
};
template <typename CT, typename P>
class base_factory
{
public:
virtual ~base_factory() {}
virtual void add_to_factory(std::string const& name, factory_entry<CT, P>* sub) = 0;
};
} // namespace detail
}}} // namespace boost::geometry::projections
#endif // BOOST_GEOMETRY_PROJECTIONS_IMPL_FACTORY_ENTRY_HPP

View File

@@ -0,0 +1,46 @@
// Boost.Geometry (aka GGL, Generic Geometry Library)
// Copyright (c) 2007-2012 Barend Gehrels, Amsterdam, the Netherlands.
// This file was modified by Oracle on 2017.
// Modifications copyright (c) 2017, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
#ifndef BOOST_GEOMETRY_PROJECTIONS_IMPL_FUNCTION_OVERLOADS_HPP
#define BOOST_GEOMETRY_PROJECTIONS_IMPL_FUNCTION_OVERLOADS_HPP
#include <cmath>
namespace boost { namespace geometry { namespace projections
{
// Functions to resolve ambiguity when compiling with coordinates of different types
/*
template <typename T>
inline T atan2(T const& a, T const& b)
{
using std::atan2;
return atan2(a, b);
}
template <typename T>
inline T pow(T const& a, T const& b)
{
using std::pow;
return pow(a, b);
}
*/
template <typename T>
inline int int_floor(T const& f)
{
using std::floor;
return int(floor(f));
}
}}} // namespace boost::geometry::projections
#endif // BOOST_GEOMETRY_PROJECTIONS_IMPL_FUNCTION_OVERLOADS_HPP

View File

@@ -0,0 +1,487 @@
// Boost.Geometry
// This file is manually converted from PROJ4
// This file was modified by Oracle on 2017.
// Modifications copyright (c) 2017, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
// This file is converted from PROJ4, http://trac.osgeo.org/proj
// PROJ4 is originally written by Gerald Evenden (then of the USGS)
// PROJ4 is maintained by Frank Warmerdam
// This file was converted to Geometry Library by Adam Wulkiewicz
// Original copyright notice:
/***************************************************************************/
/* RSC IDENTIFIER: GEOCENTRIC
*
* ABSTRACT
*
* This component provides conversions between Geodetic coordinates (latitude,
* longitude in radians and height in meters) and Geocentric coordinates
* (X, Y, Z) in meters.
*
* ERROR HANDLING
*
* This component checks parameters for valid values. If an invalid value
* is found, the error code is combined with the current error code using
* the bitwise or. This combining allows multiple error codes to be
* returned. The possible error codes are:
*
* GEOCENT_NO_ERROR : No errors occurred in function
* GEOCENT_LAT_ERROR : Latitude out of valid range
* (-90 to 90 degrees)
* GEOCENT_LON_ERROR : Longitude out of valid range
* (-180 to 360 degrees)
* GEOCENT_A_ERROR : Semi-major axis lessthan or equal to zero
* GEOCENT_B_ERROR : Semi-minor axis lessthan or equal to zero
* GEOCENT_A_LESS_B_ERROR : Semi-major axis less than semi-minor axis
*
*
* REUSE NOTES
*
* GEOCENTRIC is intended for reuse by any application that performs
* coordinate conversions between geodetic coordinates and geocentric
* coordinates.
*
*
* REFERENCES
*
* An Improved Algorithm for Geocentric to Geodetic Coordinate Conversion,
* Ralph Toms, February 1996 UCRL-JC-123138.
*
* Further information on GEOCENTRIC can be found in the Reuse Manual.
*
* GEOCENTRIC originated from : U.S. Army Topographic Engineering Center
* Geospatial Information Division
* 7701 Telegraph Road
* Alexandria, VA 22310-3864
*
* LICENSES
*
* None apply to this component.
*
* RESTRICTIONS
*
* GEOCENTRIC has no restrictions.
*
* ENVIRONMENT
*
* GEOCENTRIC was tested and certified in the following environments:
*
* 1. Solaris 2.5 with GCC version 2.8.1
* 2. Windows 95 with MS Visual C++ version 6
*
* MODIFICATIONS
*
* Date Description
* ---- -----------
* 25-02-97 Original Code
*
*/
#ifndef BOOST_GEOMETRY_SRS_PROJECTIONS_IMPL_GEOCENT_HPP
#define BOOST_GEOMETRY_SRS_PROJECTIONS_IMPL_GEOCENT_HPP
#include <boost/geometry/util/math.hpp>
namespace boost { namespace geometry { namespace projections
{
namespace detail
{
/***************************************************************************/
/*
* DEFINES
*/
static const long GEOCENT_NO_ERROR = 0x0000;
static const long GEOCENT_LAT_ERROR = 0x0001;
static const long GEOCENT_LON_ERROR = 0x0002;
static const long GEOCENT_A_ERROR = 0x0004;
static const long GEOCENT_B_ERROR = 0x0008;
static const long GEOCENT_A_LESS_B_ERROR = 0x0010;
template <typename T>
struct GeocentricInfo
{
T Geocent_a; /* Semi-major axis of ellipsoid in meters */
T Geocent_b; /* Semi-minor axis of ellipsoid */
T Geocent_a2; /* Square of semi-major axis */
T Geocent_b2; /* Square of semi-minor axis */
T Geocent_e2; /* Eccentricity squared */
T Geocent_ep2; /* 2nd eccentricity squared */
};
template <typename T>
inline T COS_67P5()
{
/*return 0.38268343236508977*/;
return cos(T(67.5) * math::d2r<T>()); /* cosine of 67.5 degrees */
}
template <typename T>
inline T AD_C()
{
return 1.0026000; /* Toms region 1 constant */
}
/***************************************************************************/
/*
* FUNCTIONS
*/
template <typename T>
inline long pj_Set_Geocentric_Parameters (GeocentricInfo<T> & gi, T const& a, T const& b)
{ /* BEGIN Set_Geocentric_Parameters */
/*
* The function Set_Geocentric_Parameters receives the ellipsoid parameters
* as inputs and sets the corresponding state variables.
*
* a : Semi-major axis, in meters. (input)
* b : Semi-minor axis, in meters. (input)
*/
long Error_Code = GEOCENT_NO_ERROR;
if (a <= 0.0)
Error_Code |= GEOCENT_A_ERROR;
if (b <= 0.0)
Error_Code |= GEOCENT_B_ERROR;
if (a < b)
Error_Code |= GEOCENT_A_LESS_B_ERROR;
if (!Error_Code)
{
gi.Geocent_a = a;
gi.Geocent_b = b;
gi.Geocent_a2 = a * a;
gi.Geocent_b2 = b * b;
gi.Geocent_e2 = (gi.Geocent_a2 - gi.Geocent_b2) / gi.Geocent_a2;
gi.Geocent_ep2 = (gi.Geocent_a2 - gi.Geocent_b2) / gi.Geocent_b2;
}
return (Error_Code);
} /* END OF Set_Geocentric_Parameters */
template <typename T>
inline void pj_Get_Geocentric_Parameters (GeocentricInfo<T> const& gi,
T & a,
T & b)
{ /* BEGIN Get_Geocentric_Parameters */
/*
* The function Get_Geocentric_Parameters returns the ellipsoid parameters
* to be used in geocentric coordinate conversions.
*
* a : Semi-major axis, in meters. (output)
* b : Semi-minor axis, in meters. (output)
*/
a = gi.Geocent_a;
b = gi.Geocent_b;
} /* END OF Get_Geocentric_Parameters */
template <typename T>
inline long pj_Convert_Geodetic_To_Geocentric (GeocentricInfo<T> const& gi,
T Longitude, T Latitude, T Height,
T & X, T & Y, T & Z)
{ /* BEGIN Convert_Geodetic_To_Geocentric */
/*
* The function Convert_Geodetic_To_Geocentric converts geodetic coordinates
* (latitude, longitude, and height) to geocentric coordinates (X, Y, Z),
* according to the current ellipsoid parameters.
*
* Latitude : Geodetic latitude in radians (input)
* Longitude : Geodetic longitude in radians (input)
* Height : Geodetic height, in meters (input)
* X : Calculated Geocentric X coordinate, in meters (output)
* Y : Calculated Geocentric Y coordinate, in meters (output)
* Z : Calculated Geocentric Z coordinate, in meters (output)
*
*/
long Error_Code = GEOCENT_NO_ERROR;
T Rn; /* Earth radius at location */
T Sin_Lat; /* sin(Latitude) */
T Sin2_Lat; /* Square of sin(Latitude) */
T Cos_Lat; /* cos(Latitude) */
static const T PI = math::pi<T>();
static const T PI_OVER_2 = math::half_pi<T>();
/*
** Don't blow up if Latitude is just a little out of the value
** range as it may just be a rounding issue. Also removed longitude
** test, it should be wrapped by cos() and sin(). NFW for PROJ.4, Sep/2001.
*/
if( Latitude < -PI_OVER_2 && Latitude > -1.001 * PI_OVER_2 )
Latitude = -PI_OVER_2;
else if( Latitude > PI_OVER_2 && Latitude < 1.001 * PI_OVER_2 )
Latitude = PI_OVER_2;
else if ((Latitude < -PI_OVER_2) || (Latitude > PI_OVER_2))
{ /* Latitude out of range */
Error_Code |= GEOCENT_LAT_ERROR;
}
if (!Error_Code)
{ /* no errors */
if (Longitude > PI)
Longitude -= (2*PI);
Sin_Lat = sin(Latitude);
Cos_Lat = cos(Latitude);
Sin2_Lat = Sin_Lat * Sin_Lat;
Rn = gi.Geocent_a / (sqrt(1.0e0 - gi.Geocent_e2 * Sin2_Lat));
X = (Rn + Height) * Cos_Lat * cos(Longitude);
Y = (Rn + Height) * Cos_Lat * sin(Longitude);
Z = ((Rn * (1 - gi.Geocent_e2)) + Height) * Sin_Lat;
}
return (Error_Code);
} /* END OF Convert_Geodetic_To_Geocentric */
/*
* The function Convert_Geocentric_To_Geodetic converts geocentric
* coordinates (X, Y, Z) to geodetic coordinates (latitude, longitude,
* and height), according to the current ellipsoid parameters.
*
* X : Geocentric X coordinate, in meters. (input)
* Y : Geocentric Y coordinate, in meters. (input)
* Z : Geocentric Z coordinate, in meters. (input)
* Latitude : Calculated latitude value in radians. (output)
* Longitude : Calculated longitude value in radians. (output)
* Height : Calculated height value, in meters. (output)
*/
#define BOOST_GEOMETRY_PROJECTIONS_USE_ITERATIVE_METHOD
template <typename T>
inline void pj_Convert_Geocentric_To_Geodetic (GeocentricInfo<T> const& gi,
T X, T Y, T Z,
T & Longitude, T & Latitude, T & Height)
{ /* BEGIN Convert_Geocentric_To_Geodetic */
static const T PI_OVER_2 = math::half_pi<T>();
#if !defined(BOOST_GEOMETRY_PROJECTIONS_USE_ITERATIVE_METHOD)
static const T COS_67P5 = detail::COS_67P5<T>();
static const T AD_C = detail::AD_C<T>();
/*
* The method used here is derived from 'An Improved Algorithm for
* Geocentric to Geodetic Coordinate Conversion', by Ralph Toms, Feb 1996
*/
/* Note: Variable names follow the notation used in Toms, Feb 1996 */
T W; /* distance from Z axis */
T W2; /* square of distance from Z axis */
T T0; /* initial estimate of vertical component */
T T1; /* corrected estimate of vertical component */
T S0; /* initial estimate of horizontal component */
T S1; /* corrected estimate of horizontal component */
T Sin_B0; /* sin(B0), B0 is estimate of Bowring aux variable */
T Sin3_B0; /* cube of sin(B0) */
T Cos_B0; /* cos(B0) */
T Sin_p1; /* sin(phi1), phi1 is estimated latitude */
T Cos_p1; /* cos(phi1) */
T Rn; /* Earth radius at location */
T Sum; /* numerator of cos(phi1) */
bool At_Pole; /* indicates location is in polar region */
At_Pole = false;
if (X != 0.0)
{
Longitude = atan2(Y,X);
}
else
{
if (Y > 0)
{
Longitude = PI_OVER_2;
}
else if (Y < 0)
{
Longitude = -PI_OVER_2;
}
else
{
At_Pole = true;
Longitude = 0.0;
if (Z > 0.0)
{ /* north pole */
Latitude = PI_OVER_2;
}
else if (Z < 0.0)
{ /* south pole */
Latitude = -PI_OVER_2;
}
else
{ /* center of earth */
Latitude = PI_OVER_2;
Height = -Geocent_b;
return;
}
}
}
W2 = X*X + Y*Y;
W = sqrt(W2);
T0 = Z * AD_C;
S0 = sqrt(T0 * T0 + W2);
Sin_B0 = T0 / S0;
Cos_B0 = W / S0;
Sin3_B0 = Sin_B0 * Sin_B0 * Sin_B0;
T1 = Z + gi.Geocent_b * gi.Geocent_ep2 * Sin3_B0;
Sum = W - gi.Geocent_a * gi.Geocent_e2 * Cos_B0 * Cos_B0 * Cos_B0;
S1 = sqrt(T1*T1 + Sum * Sum);
Sin_p1 = T1 / S1;
Cos_p1 = Sum / S1;
Rn = gi.Geocent_a / sqrt(1.0 - gi.Geocent_e2 * Sin_p1 * Sin_p1);
if (Cos_p1 >= COS_67P5)
{
Height = W / Cos_p1 - Rn;
}
else if (Cos_p1 <= -COS_67P5)
{
Height = W / -Cos_p1 - Rn;
}
else
{
Height = Z / Sin_p1 + Rn * (gi.Geocent_e2 - 1.0);
}
if (At_Pole == false)
{
Latitude = atan(Sin_p1 / Cos_p1);
}
#else /* defined(BOOST_GEOMETRY_PROJECTIONS_USE_ITERATIVE_METHOD) */
/*
* Reference...
* ============
* Wenzel, H.-G.(1985): Hochauflösende Kugelfunktionsmodelle für
* das Gravitationspotential der Erde. Wiss. Arb. Univ. Hannover
* Nr. 137, p. 130-131.
* Programmed by GGA- Leibniz-Institute of Applied Geophysics
* Stilleweg 2
* D-30655 Hannover
* Federal Republic of Germany
* Internet: www.gga-hannover.de
*
* Hannover, March 1999, April 2004.
* see also: comments in statements
* remarks:
* Mathematically exact and because of symmetry of rotation-ellipsoid,
* each point (X,Y,Z) has at least two solutions (Latitude1,Longitude1,Height1) and
* (Latitude2,Longitude2,Height2). Is point=(0.,0.,Z) (P=0.), so you get even
* four solutions, every two symmetrical to the semi-minor axis.
* Here Height1 and Height2 have at least a difference in order of
* radius of curvature (e.g. (0,0,b)=> (90.,0.,0.) or (-90.,0.,-2b);
* (a+100.)*(sqrt(2.)/2.,sqrt(2.)/2.,0.) => (0.,45.,100.) or
* (0.,225.,-(2a+100.))).
* The algorithm always computes (Latitude,Longitude) with smallest |Height|.
* For normal computations, that means |Height|<10000.m, algorithm normally
* converges after to 2-3 steps!!!
* But if |Height| has the amount of length of ellipsoid's axis
* (e.g. -6300000.m), algorithm needs about 15 steps.
*/
/* local definitions and variables */
/* end-criterium of loop, accuracy of sin(Latitude) */
static const T genau = 1.E-12;
static const T genau2 = (genau*genau);
static const int maxiter = 30;
T P; /* distance between semi-minor axis and location */
T RR; /* distance between center and location */
T CT; /* sin of geocentric latitude */
T ST; /* cos of geocentric latitude */
T RX;
T RK;
T RN; /* Earth radius at location */
T CPHI0; /* cos of start or old geodetic latitude in iterations */
T SPHI0; /* sin of start or old geodetic latitude in iterations */
T CPHI; /* cos of searched geodetic latitude */
T SPHI; /* sin of searched geodetic latitude */
T SDPHI; /* end-criterium: addition-theorem of sin(Latitude(iter)-Latitude(iter-1)) */
int iter; /* # of continuous iteration, max. 30 is always enough (s.a.) */
P = sqrt(X*X+Y*Y);
RR = sqrt(X*X+Y*Y+Z*Z);
/* special cases for latitude and longitude */
if (P/gi.Geocent_a < genau) {
/* special case, if P=0. (X=0., Y=0.) */
Longitude = 0.;
/* if (X,Y,Z)=(0.,0.,0.) then Height becomes semi-minor axis
* of ellipsoid (=center of mass), Latitude becomes PI/2 */
if (RR/gi.Geocent_a < genau) {
Latitude = PI_OVER_2;
Height = -gi.Geocent_b;
return ;
}
}
else {
/* ellipsoidal (geodetic) longitude
* interval: -PI < Longitude <= +PI */
Longitude=atan2(Y,X);
}
/* --------------------------------------------------------------
* Following iterative algorithm was developed by
* "Institut für Erdmessung", University of Hannover, July 1988.
* Internet: www.ife.uni-hannover.de
* Iterative computation of CPHI,SPHI and Height.
* Iteration of CPHI and SPHI to 10**-12 radian resp.
* 2*10**-7 arcsec.
* --------------------------------------------------------------
*/
CT = Z/RR;
ST = P/RR;
RX = 1.0/sqrt(1.0-gi.Geocent_e2*(2.0-gi.Geocent_e2)*ST*ST);
CPHI0 = ST*(1.0-gi.Geocent_e2)*RX;
SPHI0 = CT*RX;
iter = 0;
/* loop to find sin(Latitude) resp. Latitude
* until |sin(Latitude(iter)-Latitude(iter-1))| < genau */
do
{
iter++;
RN = gi.Geocent_a/sqrt(1.0-gi.Geocent_e2*SPHI0*SPHI0);
/* ellipsoidal (geodetic) height */
Height = P*CPHI0+Z*SPHI0-RN*(1.0-gi.Geocent_e2*SPHI0*SPHI0);
RK = gi.Geocent_e2*RN/(RN+Height);
RX = 1.0/sqrt(1.0-RK*(2.0-RK)*ST*ST);
CPHI = ST*(1.0-RK)*RX;
SPHI = CT*RX;
SDPHI = SPHI*CPHI0-CPHI*SPHI0;
CPHI0 = CPHI;
SPHI0 = SPHI;
}
while (SDPHI*SDPHI > genau2 && iter < maxiter);
/* ellipsoidal (geodetic) latitude */
Latitude=atan(SPHI/fabs(CPHI));
return;
#endif /* defined(BOOST_GEOMETRY_PROJECTIONS_USE_ITERATIVE_METHOD) */
} /* END OF Convert_Geocentric_To_Geodetic */
} // namespace detail
}}} // namespace boost::geometry::projections
#endif // BOOST_GEOMETRY_SRS_PROJECTIONS_IMPL_GEOCENT_HPP

View File

@@ -0,0 +1,95 @@
// Boost.Geometry (aka GGL, Generic Geometry Library)
// This file is manually converted from PROJ4
// Copyright (c) 2008-2012 Barend Gehrels, Amsterdam, the Netherlands.
// This file was modified by Oracle on 2017.
// Modifications copyright (c) 2017, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
// This file is converted from PROJ4, http://trac.osgeo.org/proj
// PROJ4 is originally written by Gerald Evenden (then of the USGS)
// PROJ4 is maintained by Frank Warmerdam
// PROJ4 is converted to Geometry Library by Barend Gehrels (Geodan, Amsterdam)
// Original copyright notice:
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the "Software"),
// to deal in the Software without restriction, including without limitation
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
// and/or sell copies of the Software, and to permit persons to whom the
// Software is furnished to do so, subject to the following conditions:
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Software.
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.
#ifndef BOOST_GEOMETRY_PROJECTIONS_IMPL_PJ_AUTH_HPP
#define BOOST_GEOMETRY_PROJECTIONS_IMPL_PJ_AUTH_HPP
#include <cassert>
#include <cmath>
#include <boost/geometry/core/assert.hpp>
namespace boost { namespace geometry { namespace projections {
namespace detail {
static const int APA_SIZE = 3;
/* determine latitude from authalic latitude */
template <typename T>
inline bool pj_authset(T const& es, T* APA)
{
BOOST_GEOMETRY_ASSERT(0 != APA);
static const T P00 = .33333333333333333333;
static const T P01 = .17222222222222222222;
static const T P02 = .10257936507936507936;
static const T P10 = .06388888888888888888;
static const T P11 = .06640211640211640211;
static const T P20 = .01641501294219154443;
T t = 0;
// if (APA = (double *)pj_malloc(APA_SIZE * sizeof(double)))
{
APA[0] = es * P00;
t = es * es;
APA[0] += t * P01;
APA[1] = t * P10;
t *= es;
APA[0] += t * P02;
APA[1] += t * P11;
APA[2] = t * P20;
}
return true;
}
template <typename T>
inline T pj_authlat(T const& beta, const T* APA)
{
BOOST_GEOMETRY_ASSERT(0 != APA);
T const t = beta + beta;
return(beta + APA[0] * sin(t) + APA[1] * sin(t + t) + APA[2] * sin(t + t + t));
}
} // namespace detail
}}} // namespace boost::geometry::projections
#endif // BOOST_GEOMETRY_PROJECTIONS_IMPL_PJ_AUTH_HPP

View File

@@ -0,0 +1,213 @@
// Boost.Geometry (aka GGL, Generic Geometry Library)
// This file is manually converted from PROJ4
// Copyright (c) 2008-2012 Barend Gehrels, Amsterdam, the Netherlands.
// This file was modified by Oracle on 2017, 2018.
// Modifications copyright (c) 2017-2018, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
// This file is converted from PROJ4, http://trac.osgeo.org/proj
// PROJ4 is originally written by Gerald Evenden (then of the USGS)
// PROJ4 is maintained by Frank Warmerdam
// PROJ4 is converted to Geometry Library by Barend Gehrels (Geodan, Amsterdam)
// Original copyright notice:
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the "Software"),
// to deal in the Software without restriction, including without limitation
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
// and/or sell copies of the Software, and to permit persons to whom the
// Software is furnished to do so, subject to the following conditions:
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Software.
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.
#ifndef BOOST_GEOMETRY_PROJECTIONS_IMPL_PJ_DATUM_SET_HPP
#define BOOST_GEOMETRY_PROJECTIONS_IMPL_PJ_DATUM_SET_HPP
#include <string>
#include <vector>
#include <boost/algorithm/string.hpp>
#include <boost/geometry/srs/projections/exception.hpp>
#include <boost/geometry/srs/projections/impl/projects.hpp>
#include <boost/geometry/srs/projections/impl/pj_datums.hpp>
#include <boost/geometry/srs/projections/impl/pj_param.hpp>
#include <boost/geometry/srs/projections/par4.hpp>
#include <boost/geometry/srs/projections/proj4.hpp>
namespace boost { namespace geometry { namespace projections {
namespace detail {
/* SEC_TO_RAD = Pi/180/3600 */
template <typename T>
inline T SEC_TO_RAD() { return 4.84813681109535993589914102357e-6; }
template <typename BGParams, typename T>
inline void pj_datum_add_defn(BGParams const& , std::vector<pvalue<T> >& pvalues)
{
/* -------------------------------------------------------------------- */
/* Is there a datum definition in the parameter list? If so, */
/* add the defining values to the parameter list. Note that */
/* this will append the ellipse definition as well as the */
/* towgs84= and related parameters. It should also be pointed */
/* out that the addition is permanent rather than temporary */
/* like most other keyword expansion so that the ellipse */
/* definition will last into the pj_ell_set() function called */
/* after this one. */
/* -------------------------------------------------------------------- */
std::string name = pj_param(pvalues, "sdatum").s;
if(! name.empty())
{
/* find the datum definition */
const int n = sizeof(pj_datums) / sizeof(pj_datums[0]);
int index = -1;
for (int i = 0; i < n && index == -1; i++)
{
if(pj_datums[i].id == name)
{
index = i;
}
}
if (index == -1)
{
BOOST_THROW_EXCEPTION( projection_exception(-9) );
}
if(! pj_datums[index].ellipse_id.empty())
{
std::string entry("ellps=");
entry +=pj_datums[index].ellipse_id;
pvalues.push_back(pj_mkparam<T>(entry));
}
if(! pj_datums[index].defn.empty())
{
pvalues.push_back(pj_mkparam<T>(pj_datums[index].defn));
}
}
}
template <BOOST_GEOMETRY_PROJECTIONS_DETAIL_TYPENAME_PX, typename T>
inline void pj_datum_add_defn(srs::static_proj4<BOOST_GEOMETRY_PROJECTIONS_DETAIL_PX> const& /*bg_params*/,
std::vector<pvalue<T> >& pvalues)
{
typedef srs::static_proj4<BOOST_GEOMETRY_PROJECTIONS_DETAIL_PX> bg_parameters_type;
typedef typename srs::par4::detail::tuples_find_if
<
bg_parameters_type,
//srs::par4::detail::is_datum
srs::par4::detail::is_param_t<srs::par4::datum>::pred
>::type datum_type;
typedef typename srs::par4::detail::datum_traits
<
datum_type
> datum_traits;
// is unknown if datum parameter found but traits are not specialized
static const bool not_set_or_known = boost::is_same<datum_type, void>::value
|| ! boost::is_same<typename datum_traits::ellps_type, void>::value;
BOOST_MPL_ASSERT_MSG((not_set_or_known), UNKNOWN_DATUM, (bg_parameters_type));
std::string defn = datum_traits::definition();
if (! defn.empty())
{
pvalues.push_back(pj_mkparam<T>(defn));
}
}
/************************************************************************/
/* pj_datum_set() */
/************************************************************************/
template <typename BGParams, typename T>
inline void pj_datum_set(BGParams const& bg_params, std::vector<pvalue<T> >& pvalues, parameters<T>& projdef)
{
static const T SEC_TO_RAD = detail::SEC_TO_RAD<T>();
projdef.datum_type = PJD_UNKNOWN;
pj_datum_add_defn(bg_params, pvalues);
/* -------------------------------------------------------------------- */
/* Check for nadgrids parameter. */
/* -------------------------------------------------------------------- */
std::string nadgrids = pj_param(pvalues, "snadgrids").s;
std::string towgs84 = pj_param(pvalues, "stowgs84").s;
if(! nadgrids.empty())
{
/* We don't actually save the value separately. It will continue
to exist int he param list for use in pj_apply_gridshift.c */
projdef.datum_type = PJD_GRIDSHIFT;
}
/* -------------------------------------------------------------------- */
/* Check for towgs84 parameter. */
/* -------------------------------------------------------------------- */
else if(! towgs84.empty())
{
int parm_count = 0;
int n = sizeof(projdef.datum_params) / sizeof(projdef.datum_params[0]);
/* parse out the pvalues */
std::vector<std::string> parm;
boost::split(parm, towgs84, boost::is_any_of(" ,"));
for (std::vector<std::string>::const_iterator it = parm.begin();
it != parm.end() && parm_count < n;
++it)
{
projdef.datum_params[parm_count++] = atof(it->c_str());
}
if( projdef.datum_params[3] != 0.0
|| projdef.datum_params[4] != 0.0
|| projdef.datum_params[5] != 0.0
|| projdef.datum_params[6] != 0.0 )
{
projdef.datum_type = PJD_7PARAM;
/* transform from arc seconds to radians */
projdef.datum_params[3] *= SEC_TO_RAD;
projdef.datum_params[4] *= SEC_TO_RAD;
projdef.datum_params[5] *= SEC_TO_RAD;
/* transform from parts per million to scaling factor */
projdef.datum_params[6] =
(projdef.datum_params[6]/1000000.0) + 1;
}
else
{
projdef.datum_type = PJD_3PARAM;
}
/* Note that pj_init() will later switch datum_type to
PJD_WGS84 if shifts are all zero, and ellipsoid is WGS84 or GRS80 */
}
}
} // namespace detail
}}} // namespace boost::geometry::projections
#endif // BOOST_GEOMETRY_PROJECTIONS_IMPL_PJ_DATUM_SET_HPP

View File

@@ -0,0 +1,112 @@
// Boost.Geometry (aka GGL, Generic Geometry Library)
// This file is manually converted from PROJ4
// Copyright (c) 2008-2012 Barend Gehrels, Amsterdam, the Netherlands.
// This file was modified by Oracle on 2017.
// Modifications copyright (c) 2017, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
// This file is converted from PROJ4, http://trac.osgeo.org/proj
// PROJ4 is originally written by Gerald Evenden (then of the USGS)
// PROJ4 is maintained by Frank Warmerdam
// PROJ4 is converted to Geometry Library by Barend Gehrels (Geodan, Amsterdam)
// Original copyright notice:
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the "Software"),
// to deal in the Software without restriction, including without limitation
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
// and/or sell copies of the Software, and to permit persons to whom the
// Software is furnished to do so, subject to the following conditions:
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Software.
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.
#ifndef BOOST_GEOMETRY_PROJECTIONS_IMPL_PJ_DATUMS_HPP
#define BOOST_GEOMETRY_PROJECTIONS_IMPL_PJ_DATUMS_HPP
#include <boost/geometry/srs/projections/impl/projects.hpp>
namespace boost { namespace geometry { namespace projections {
namespace detail {
/*
* The ellipse code must match one from pj_ellps.c. The datum id should
* be kept to 12 characters or less if possible. Use the official OGC
* datum name for the comments if available.
*/
static const PJ_DATUMS pj_datums[] =
{
/* id definition ellipse comments */
/* -- ---------- ------- -------- */
{"WGS84", "towgs84=0,0,0",
"WGS84", ""},
{"GGRS87", "towgs84=-199.87,74.79,246.62",
"GRS80", "Greek_Geodetic_Reference_System_1987"},
{"NAD83", "towgs84=0,0,0",
"GRS80", "North_American_Datum_1983"},
{"NAD27", "nadgrids=@conus,@alaska,@ntv2_0.gsb,@ntv1_can.dat",
"clrk66", "North_American_Datum_1927"},
{"potsdam", "towgs84=598.1,73.7,418.2,0.202,0.045,-2.455,6.7",
"bessel", "Potsdam Rauenberg 1950 DHDN"},
{"carthage", "towgs84=-263.0,6.0,431.0",
"clrk80ign", "Carthage 1934 Tunisia"},
{"hermannskogel", "towgs84=577.326,90.129,463.919,5.137,1.474,5.297,2.4232",
"bessel", "Hermannskogel"},
{"ire65", "towgs84=482.530,-130.596,564.557,-1.042,-0.214,-0.631,8.15",
"mod_airy", "Ireland 1965"},
{"nzgd49", "towgs84=59.47,-5.04,187.44,0.47,-0.1,1.024,-4.5993",
"intl", "New Zealand Geodetic Datum 1949"},
{"OSGB36", "towgs84=446.448,-125.157,542.060,0.1502,0.2470,0.8421,-20.4894",
"airy", "Airy 1830"}
};
static const PJ_PRIME_MERIDIANS pj_prime_meridians[] =
{
/* id definition */
/* -- ---------- */
{ "greenwich", "0dE" },
{ "lisbon", "9d07'54.862\"W" },
{ "paris", "2d20'14.025\"E" },
{ "bogota", "74d04'51.3\"W" },
{ "madrid", "3d41'16.58\"W" },
{ "rome", "12d27'8.4\"E" },
{ "bern", "7d26'22.5\"E" },
{ "jakarta", "106d48'27.79\"E" },
{ "ferro", "17d40'W" },
{ "brussels", "4d22'4.71\"E" },
{ "stockholm", "18d3'29.8\"E" },
{ "athens", "23d42'58.815\"E" },
{ "oslo", "10d43'22.5\"E" }
};
} // namespace detail
}}} // namespace boost::geometry::projections
#endif // BOOST_GEOMETRY_PROJECTIONS_IMPL_PJ_DATUMS_HPP

View File

@@ -0,0 +1,205 @@
// Boost.Geometry (aka GGL, Generic Geometry Library)
// This file is manually converted from PROJ4
// Copyright (c) 2008-2012 Barend Gehrels, Amsterdam, the Netherlands.
// This file was modified by Oracle on 2017, 2018.
// Modifications copyright (c) 2017-2018, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
// This file is converted from PROJ4, http://trac.osgeo.org/proj
// PROJ4 is originally written by Gerald Evenden (then of the USGS)
// PROJ4 is maintained by Frank Warmerdam
// PROJ4 is converted to Geometry Library by Barend Gehrels (Geodan, Amsterdam)
// Original copyright notice:
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the "Software"),
// to deal in the Software without restriction, including without limitation
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
// and/or sell copies of the Software, and to permit persons to whom the
// Software is furnished to do so, subject to the following conditions:
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Software.
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.
#ifndef BOOST_GEOMETRY_PROJECTIONS_IMPL_PJ_ELL_SET_HPP
#define BOOST_GEOMETRY_PROJECTIONS_IMPL_PJ_ELL_SET_HPP
#include <string>
#include <vector>
#include <boost/geometry/formulas/eccentricity_sqr.hpp>
#include <boost/geometry/util/math.hpp>
#include <boost/geometry/srs/projections/impl/pj_ellps.hpp>
#include <boost/geometry/srs/projections/impl/pj_param.hpp>
#include <boost/geometry/srs/projections/proj4.hpp>
namespace boost { namespace geometry { namespace projections {
namespace detail {
/* set ellipsoid parameters a and es */
template <typename T>
inline T SIXTH() { return .1666666666666666667; } /* 1/6 */
template <typename T>
inline T RA4() { return .04722222222222222222; } /* 17/360 */
template <typename T>
inline T RA6() { return .02215608465608465608; } /* 67/3024 */
template <typename T>
inline T RV4() { return .06944444444444444444; } /* 5/72 */
template <typename T>
inline T RV6() { return .04243827160493827160; } /* 55/1296 */
/* initialize geographic shape parameters */
template <typename BGParams, typename T>
inline void pj_ell_set(BGParams const& /*bg_params*/, std::vector<pvalue<T> >& parameters, T &a, T &es)
{
T b = 0.0;
T e = 0.0;
std::string name;
/* check for varying forms of ellipsoid input */
a = es = 0.;
/* R takes precedence */
if (pj_param(parameters, "tR").i)
a = pj_param(parameters, "dR").f;
else { /* probable elliptical figure */
/* check if ellps present and temporarily append its values to pl */
name = pj_param(parameters, "sellps").s;
if (! name.empty())
{
const int n = sizeof(pj_ellps) / sizeof(pj_ellps[0]);
int index = -1;
for (int i = 0; i < n && index == -1; i++)
{
if(pj_ellps[i].id == name)
{
index = i;
}
}
if (index == -1) {
BOOST_THROW_EXCEPTION( projection_exception(-9) );
}
parameters.push_back(pj_mkparam<T>(pj_ellps[index].major));
parameters.push_back(pj_mkparam<T>(pj_ellps[index].ell));
}
a = pj_param(parameters, "da").f;
if (pj_param(parameters, "tes").i) /* eccentricity squared */
es = pj_param(parameters, "des").f;
else if (pj_param(parameters, "te").i) { /* eccentricity */
e = pj_param(parameters, "de").f;
es = e * e;
} else if (pj_param(parameters, "trf").i) { /* recip flattening */
es = pj_param(parameters, "drf").f;
if (!es) {
BOOST_THROW_EXCEPTION( projection_exception(-10) );
}
es = 1./ es;
es = es * (2. - es);
} else if (pj_param(parameters, "tf").i) { /* flattening */
es = pj_param(parameters, "df").f;
es = es * (2. - es);
} else if (pj_param(parameters, "tb").i) { /* minor axis */
b = pj_param(parameters, "db").f;
es = 1. - (b * b) / (a * a);
} /* else es == 0. and sphere of radius a */
if (!b)
b = a * sqrt(1. - es);
/* following options turn ellipsoid into equivalent sphere */
if (pj_param(parameters, "bR_A").i) { /* sphere--area of ellipsoid */
a *= 1. - es * (SIXTH<T>() + es * (RA4<T>() + es * RA6<T>()));
es = 0.;
} else if (pj_param(parameters, "bR_V").i) { /* sphere--vol. of ellipsoid */
a *= 1. - es * (SIXTH<T>() + es * (RV4<T>() + es * RV6<T>()));
es = 0.;
} else if (pj_param(parameters, "bR_a").i) { /* sphere--arithmetic mean */
a = .5 * (a + b);
es = 0.;
} else if (pj_param(parameters, "bR_g").i) { /* sphere--geometric mean */
a = sqrt(a * b);
es = 0.;
} else if (pj_param(parameters, "bR_h").i) { /* sphere--harmonic mean */
a = 2. * a * b / (a + b);
es = 0.;
} else {
int i = pj_param(parameters, "tR_lat_a").i;
if (i || /* sphere--arith. */
pj_param(parameters, "tR_lat_g").i) { /* or geom. mean at latitude */
T tmp;
tmp = sin(pj_param(parameters, i ? "rR_lat_a" : "rR_lat_g").f);
if (geometry::math::abs(tmp) > geometry::math::half_pi<T>()) {
BOOST_THROW_EXCEPTION( projection_exception(-11) );
}
tmp = 1. - es * tmp * tmp;
a *= i ? .5 * (1. - es + tmp) / ( tmp * sqrt(tmp)) :
sqrt(1. - es) / tmp;
es = 0.;
}
}
}
/* some remaining checks */
if (es < 0.) {
BOOST_THROW_EXCEPTION( projection_exception(-12) );
}
if (a <= 0.) {
BOOST_THROW_EXCEPTION( projection_exception(-13) );
}
}
template <BOOST_GEOMETRY_PROJECTIONS_DETAIL_TYPENAME_PX, typename T>
inline void pj_ell_set(srs::static_proj4<BOOST_GEOMETRY_PROJECTIONS_DETAIL_PX> const& bg_params,
std::vector<pvalue<T> >& /*parameters*/, T &a, T &es)
{
typedef srs::static_proj4<BOOST_GEOMETRY_PROJECTIONS_DETAIL_PX> static_parameters_type;
typedef typename srs::par4::detail::pick_ellps
<
static_parameters_type
> pick_ellps;
typename pick_ellps::model_type model = pick_ellps::model(bg_params);
a = geometry::get_radius<0>(model);
T b = geometry::get_radius<2>(model);
es = 0.;
if (a != b)
{
es = formula::eccentricity_sqr<T>(model);
// Ignore all other parameters passed in string, at least for now
}
/* some remaining checks */
if (es < 0.) {
BOOST_THROW_EXCEPTION( projection_exception(-12) );
}
if (a <= 0.) {
BOOST_THROW_EXCEPTION( projection_exception(-13) );
}
}
} // namespace detail
}}} // namespace boost::geometry::projections
#endif // BOOST_GEOMETRY_PROJECTIONS_IMPL_PJ_ELL_SET_HPP

View File

@@ -0,0 +1,98 @@
// Boost.Geometry (aka GGL, Generic Geometry Library)
// This file is manually converted from PROJ4
// Copyright (c) 2008-2012 Barend Gehrels, Amsterdam, the Netherlands.
// This file was modified by Oracle on 2017.
// Modifications copyright (c) 2017, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
// This file is converted from PROJ4, http://trac.osgeo.org/proj
// PROJ4 is originally written by Gerald Evenden (then of the USGS)
// PROJ4 is maintained by Frank Warmerdam
// PROJ4 is converted to Geometry Library by Barend Gehrels (Geodan, Amsterdam)
// Original copyright notice:
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the "Software"),
// to deal in the Software without restriction, including without limitation
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
// and/or sell copies of the Software, and to permit persons to whom the
// Software is furnished to do so, subject to the following conditions:
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Software.
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.
#ifndef BOOST_GEOMETRY_PROJECTIONS_IMPL_PJ_ELLPS_HPP
#define BOOST_GEOMETRY_PROJECTIONS_IMPL_PJ_ELLPS_HPP
#include <boost/geometry/srs/projections/impl/projects.hpp>
namespace boost { namespace geometry { namespace projections {
namespace detail {
static const PJ_ELLPS pj_ellps[] =
{
{"MERIT", "a=6378137.0", "rf=298.257", "MERIT 1983"},
{"SGS85", "a=6378136.0", "rf=298.257", "Soviet Geodetic System 85"},
{"GRS80", "a=6378137.0", "rf=298.257222101", "GRS 1980(IUGG, 1980)"},
{"IAU76", "a=6378140.0", "rf=298.257", "IAU 1976"},
{"airy", "a=6377563.396", "b=6356256.910", "Airy 1830"},
{"APL4.9", "a=6378137.0.", "rf=298.25", "Appl. Physics. 1965"},
{"NWL9D", "a=6378145.0.", "rf=298.25", "Naval Weapons Lab., 1965"},
{"mod_airy", "a=6377340.189", "b=6356034.446", "Modified Airy"},
{"andrae", "a=6377104.43", "rf=300.0", "Andrae 1876 (Den., Iclnd.)"},
{"aust_SA", "a=6378160.0", "rf=298.25", "Australian Natl & S. Amer. 1969"},
{"GRS67", "a=6378160.0", "rf=298.2471674270", "GRS 67(IUGG 1967)"},
{"bessel", "a=6377397.155", "rf=299.1528128", "Bessel 1841"},
{"bess_nam", "a=6377483.865", "rf=299.1528128", "Bessel 1841 (Namibia)"},
{"clrk66", "a=6378206.4", "b=6356583.8", "Clarke 1866"},
{"clrk80", "a=6378249.145", "rf=293.4663", "Clarke 1880 mod."},
{"clrk80ign", "a=6378249.2", "rf=293.4660212936269", "Clarke 1880 (IGN)."},
{"CPM", "a=6375738.7", "rf=334.29", "Comm. des Poids et Mesures 1799"},
{"delmbr", "a=6376428.", "rf=311.5", "Delambre 1810 (Belgium)"},
{"engelis", "a=6378136.05", "rf=298.2566", "Engelis 1985"},
{"evrst30", "a=6377276.345", "rf=300.8017", "Everest 1830"},
{"evrst48", "a=6377304.063", "rf=300.8017", "Everest 1948"},
{"evrst56", "a=6377301.243", "rf=300.8017", "Everest 1956"},
{"evrst69", "a=6377295.664", "rf=300.8017", "Everest 1969"},
{"evrstSS", "a=6377298.556", "rf=300.8017", "Everest (Sabah & Sarawak)"},
{"fschr60", "a=6378166.", "rf=298.3", "Fischer (Mercury Datum) 1960"},
{"fschr60m", "a=6378155.", "rf=298.3", "Modified Fischer 1960"},
{"fschr68", "a=6378150.", "rf=298.3", "Fischer 1968"},
{"helmert", "a=6378200.", "rf=298.3", "Helmert 1906"},
{"hough", "a=6378270.0", "rf=297.", "Hough"},
{"intl", "a=6378388.0", "rf=297.", "International 1909 (Hayford)"},
{"krass", "a=6378245.0", "rf=298.3", "Krassovsky, 1942"},
{"kaula", "a=6378163.", "rf=298.24", "Kaula 1961"},
{"lerch", "a=6378139.", "rf=298.257", "Lerch 1979"},
{"mprts", "a=6397300.", "rf=191.", "Maupertius 1738"},
{"new_intl", "a=6378157.5", "b=6356772.2", "New International 1967"},
{"plessis", "a=6376523.", "b=6355863.", "Plessis 1817 (France)"},
{"SEasia", "a=6378155.0", "b=6356773.3205", "Southeast Asia"},
{"walbeck", "a=6376896.0", "b=6355834.8467", "Walbeck"},
{"WGS60", "a=6378165.0", "rf=298.3", "WGS 60"},
{"WGS66", "a=6378145.0", "rf=298.25", "WGS 66"},
{"WGS72", "a=6378135.0", "rf=298.26", "WGS 72"},
{"WGS84", "a=6378137.0", "rf=298.257223563", "WGS 84"},
{"sphere", "a=6370997.0", "b=6370997.0", "Normal Sphere (r=6370997)"}
};
} // namespace detail
}}} // namespace boost::geometry::projections
#endif // BOOST_GEOMETRY_PROJECTIONS_IMPL_PJ_ELLPS_HPP

View File

@@ -0,0 +1,101 @@
// Boost.Geometry (aka GGL, Generic Geometry Library)
// This file is manually converted from PROJ4
// Copyright (c) 2008-2012 Barend Gehrels, Amsterdam, the Netherlands.
// This file was modified by Oracle on 2017.
// Modifications copyright (c) 2017, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
// This file is converted from PROJ4, http://trac.osgeo.org/proj
// PROJ4 is originally written by Gerald Evenden (then of the USGS)
// PROJ4 is maintained by Frank Warmerdam
// PROJ4 is converted to Geometry Library by Barend Gehrels (Geodan, Amsterdam)
// Original copyright notice:
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the "Software"),
// to deal in the Software without restriction, including without limitation
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
// and/or sell copies of the Software, and to permit persons to whom the
// Software is furnished to do so, subject to the following conditions:
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Software.
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.
#ifndef BOOST_GEOMETRY_PROJECTIONS_IMPL_PJ_FWD_HPP
#define BOOST_GEOMETRY_PROJECTIONS_IMPL_PJ_FWD_HPP
#include <boost/geometry/core/radian_access.hpp>
#include <boost/geometry/util/math.hpp>
#include <boost/geometry/srs/projections/impl/adjlon.hpp>
#include <boost/geometry/srs/projections/impl/projects.hpp>
#include <boost/math/constants/constants.hpp>
/* general forward projection */
namespace boost { namespace geometry { namespace projections {
namespace detail {
/* forward projection entry */
template <typename Prj, typename LL, typename XY, typename P>
inline void pj_fwd(Prj const& prj, P const& par, LL const& ll, XY& xy)
{
typedef typename P::type calc_t;
static const calc_t EPS = 1.0e-12;
using namespace detail;
calc_t lp_lon = geometry::get_as_radian<0>(ll);
calc_t lp_lat = geometry::get_as_radian<1>(ll);
calc_t const t = geometry::math::abs(lp_lat) - geometry::math::half_pi<calc_t>();
/* check for forward and latitude or longitude overange */
if (t > EPS || geometry::math::abs(lp_lon) > 10.)
{
BOOST_THROW_EXCEPTION( projection_exception(-14) );
}
if (geometry::math::abs(t) <= EPS)
{
lp_lat = lp_lat < 0. ? -geometry::math::half_pi<calc_t>() : geometry::math::half_pi<calc_t>();
}
else if (par.geoc)
{
lp_lat = atan(par.rone_es * tan(lp_lat));
}
lp_lon -= par.lam0; /* compute del lp.lam */
if (! par.over)
{
lp_lon = adjlon(lp_lon); /* post_forward del longitude */
}
calc_t x = 0;
calc_t y = 0;
prj.fwd(lp_lon, lp_lat, x, y);
geometry::set<0>(xy, par.fr_meter * (par.a * x + par.x0));
geometry::set<1>(xy, par.fr_meter * (par.a * y + par.y0));
}
} // namespace detail
}}} // namespace boost::geometry::projections
#endif // BOOST_GEOMETRY_PROJECTIONS_IMPL_PJ_FWD_HPP

View File

@@ -0,0 +1,142 @@
// Boost.Geometry (aka GGL, Generic Geometry Library)
// This file is manually converted from PROJ4
// Copyright (c) 2008-2012 Barend Gehrels, Amsterdam, the Netherlands.
// This file was modified by Oracle on 2017.
// Modifications copyright (c) 2017, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
// This file is converted from PROJ4, http://trac.osgeo.org/proj
// PROJ4 is originally written by Gerald Evenden (then of the USGS)
// PROJ4 is maintained by Frank Warmerdam
// PROJ4 is converted to Geometry Library by Barend Gehrels (Geodan, Amsterdam)
// Original copyright notice:
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the "Software"),
// to deal in the Software without restriction, including without limitation
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
// and/or sell copies of the Software, and to permit persons to whom the
// Software is furnished to do so, subject to the following conditions:
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Software.
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.
#ifndef BOOST_GEOMETRY_PROJECTIONS_IMPL_PJ_GAUSS_HPP
#define BOOST_GEOMETRY_PROJECTIONS_IMPL_PJ_GAUSS_HPP
#include <boost/geometry/util/math.hpp>
namespace boost { namespace geometry { namespace projections {
namespace detail { namespace gauss {
static const int MAX_ITER = 20;
template <typename T>
struct GAUSS
{
T C;
T K;
T e;
T ratexp;
};
template <typename T>
inline T srat(T const& esinp, T const& exp)
{
return (pow((1.0 - esinp) / (1.0 + esinp), exp));
}
template <typename T>
inline GAUSS<T> gauss_ini(T const& e, T const& phi0, T& chi, T& rc)
{
static const T FORTPI = detail::FORTPI<T>();
using std::asin;
using std::cos;
using std::sin;
using std::sqrt;
using std::tan;
T sphi = 0;
T cphi = 0;
T es = 0;
GAUSS<T> en;
es = e * e;
en.e = e;
sphi = sin(phi0);
cphi = cos(phi0);
cphi *= cphi;
rc = sqrt(1.0 - es) / (1.0 - es * sphi * sphi);
en.C = sqrt(1.0 + es * cphi * cphi / (1.0 - es));
chi = asin(sphi / en.C);
en.ratexp = 0.5 * en.C * e;
en.K = tan(0.5 * chi + FORTPI)
/ (pow(tan(0.5 * phi0 + FORTPI), en.C) * srat(en.e * sphi, en.ratexp));
return en;
}
template <typename T>
inline void gauss(GAUSS<T> const& en, T& lam, T& phi)
{
static const T FORTPI = detail::FORTPI<T>();
phi = 2.0 * atan(en.K * pow(tan(0.5 * phi + FORTPI), en.C)
* srat(en.e * sin(phi), en.ratexp) ) - geometry::math::half_pi<T>();
lam *= en.C;
}
template <typename T>
inline void inv_gauss(GAUSS<T> const& en, T& lam, T& phi)
{
static const T FORTPI = detail::FORTPI<T>();
static const T DEL_TOL = 1e-14;
lam /= en.C;
const T num = pow(tan(0.5 * phi + FORTPI) / en.K, 1.0 / en.C);
int i = 0;
for (i = MAX_ITER; i; --i)
{
const T elp_phi = 2.0 * atan(num * srat(en.e * sin(phi), - 0.5 * en.e)) - geometry::math::half_pi<T>();
if (geometry::math::abs(elp_phi - phi) < DEL_TOL)
{
break;
}
phi = elp_phi;
}
/* convergence failed */
if (!i)
{
BOOST_THROW_EXCEPTION( projection_exception(-17) );
}
}
}} // namespace detail::gauss
}}} // namespace boost::geometry::projections
#endif // BOOST_GEOMETRY_PROJECTIONS_IMPL_PJ_GAUSS_HPP

View File

@@ -0,0 +1,388 @@
// Boost.Geometry (aka GGL, Generic Geometry Library)
// This file is manually converted from PROJ4
// Copyright (c) 2008-2012 Barend Gehrels, Amsterdam, the Netherlands.
// This file was modified by Oracle on 2017, 2018.
// Modifications copyright (c) 2017-2018, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
// This file is converted from PROJ4, http://trac.osgeo.org/proj
// PROJ4 is originally written by Gerald Evenden (then of the USGS)
// PROJ4 is maintained by Frank Warmerdam
// PROJ4 is converted to Geometry Library by Barend Gehrels (Geodan, Amsterdam)
// Original copyright notice:
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the "Software"),
// to deal in the Software without restriction, including without limitation
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
// and/or sell copies of the Software, and to permit persons to whom the
// Software is furnished to do so, subject to the following conditions:
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Software.
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.
#ifndef BOOST_GEOMETRY_PROJECTIONS_IMPL_PJ_INIT_HPP
#define BOOST_GEOMETRY_PROJECTIONS_IMPL_PJ_INIT_HPP
#include <cstdlib>
#include <string>
#include <vector>
#include <boost/algorithm/string.hpp>
#include <boost/lexical_cast.hpp>
#include <boost/range.hpp>
#include <boost/type_traits/is_same.hpp>
#include <boost/geometry/util/math.hpp>
#include <boost/geometry/util/condition.hpp>
#include <boost/geometry/srs/projections/impl/dms_parser.hpp>
#include <boost/geometry/srs/projections/impl/pj_datum_set.hpp>
#include <boost/geometry/srs/projections/impl/pj_datums.hpp>
#include <boost/geometry/srs/projections/impl/pj_ell_set.hpp>
#include <boost/geometry/srs/projections/impl/pj_param.hpp>
#include <boost/geometry/srs/projections/impl/pj_units.hpp>
#include <boost/geometry/srs/projections/impl/projects.hpp>
#include <boost/geometry/srs/projections/proj4.hpp>
namespace boost { namespace geometry { namespace projections
{
namespace detail
{
template <typename BGParams, typename T>
inline void pj_push_defaults(BGParams const& /*bg_params*/, parameters<T>& pin)
{
pin.params.push_back(pj_mkparam<T>("ellps=WGS84"));
if (pin.name == "aea")
{
pin.params.push_back(pj_mkparam<T>("lat_1=29.5"));
pin.params.push_back(pj_mkparam<T>("lat_2=45.5 "));
}
else if (pin.name == "lcc")
{
pin.params.push_back(pj_mkparam<T>("lat_1=33"));
pin.params.push_back(pj_mkparam<T>("lat_2=45"));
}
else if (pin.name == "lagrng")
{
pin.params.push_back(pj_mkparam<T>("W=2"));
}
}
template <BOOST_GEOMETRY_PROJECTIONS_DETAIL_TYPENAME_PX, typename T>
inline void pj_push_defaults(srs::static_proj4<BOOST_GEOMETRY_PROJECTIONS_DETAIL_PX> const& /*bg_params*/,
parameters<T>& pin)
{
typedef srs::static_proj4<BOOST_GEOMETRY_PROJECTIONS_DETAIL_PX> static_parameters_type;
typedef typename srs::par4::detail::pick_proj_tag
<
static_parameters_type
>::type proj_tag;
// statically defaulting to WGS84
//pin.params.push_back(pj_mkparam("ellps=WGS84"));
if (BOOST_GEOMETRY_CONDITION((boost::is_same<proj_tag, srs::par4::aea>::value)))
{
pin.params.push_back(pj_mkparam<T>("lat_1=29.5"));
pin.params.push_back(pj_mkparam<T>("lat_2=45.5 "));
}
else if (BOOST_GEOMETRY_CONDITION((boost::is_same<proj_tag, srs::par4::lcc>::value)))
{
pin.params.push_back(pj_mkparam<T>("lat_1=33"));
pin.params.push_back(pj_mkparam<T>("lat_2=45"));
}
else if (BOOST_GEOMETRY_CONDITION((boost::is_same<proj_tag, srs::par4::lagrng>::value)))
{
pin.params.push_back(pj_mkparam<T>("W=2"));
}
}
template <typename T>
inline void pj_init_units(std::vector<pvalue<T> > const& params,
std::string const& sunits,
std::string const& sto_meter,
T & to_meter,
T & fr_meter,
T const& default_to_meter,
T const& default_fr_meter)
{
std::string s;
std::string units = pj_param(params, sunits).s;
if (! units.empty())
{
const int n = sizeof(pj_units) / sizeof(pj_units[0]);
int index = -1;
for (int i = 0; i < n && index == -1; i++)
{
if(pj_units[i].id == units)
{
index = i;
}
}
if (index == -1) {
BOOST_THROW_EXCEPTION( projection_exception(-7) );
}
s = pj_units[index].to_meter;
}
if (s.empty())
{
s = pj_param(params, sto_meter).s;
}
if (! s.empty())
{
std::size_t const pos = s.find('/');
if (pos == std::string::npos)
{
to_meter = lexical_cast<T>(s);
}
else
{
T const numerator = lexical_cast<T>(s.substr(0, pos));
T const denominator = lexical_cast<T>(s.substr(pos + 1));
if (numerator == 0.0 || denominator == 0.0)
{
BOOST_THROW_EXCEPTION( projection_exception(-99) );
}
to_meter = numerator / denominator;
}
if (to_meter == 0.0)
{
BOOST_THROW_EXCEPTION( projection_exception(-99) );
}
fr_meter = 1. / to_meter;
}
else
{
to_meter = default_to_meter;
fr_meter = default_fr_meter;
}
}
/************************************************************************/
/* pj_init() */
/* */
/* Main entry point for initialing a PJ projections */
/* definition. Note that the projection specific function is */
/* called to do the initial allocation so it can be created */
/* large enough to hold projection specific parameters. */
/************************************************************************/
template <typename T, typename BGParams, typename R>
inline parameters<T> pj_init(BGParams const& bg_params, R const& arguments, bool use_defaults = true)
{
parameters<T> pin;
for (std::vector<std::string>::const_iterator it = boost::begin(arguments);
it != boost::end(arguments); it++)
{
pin.params.push_back(pj_mkparam<T>(*it));
}
/* check if +init present */
if (pj_param(pin.params, "tinit").i)
{
// maybe TODO: handle "init" parameter
//if (!(curr = get_init(&arguments, curr, pj_param(pin.params, "sinit").s)))
}
// find projection -> implemented in projection factory
pin.name = pj_param(pin.params, "sproj").s;
// exception thrown in projection<>
// TODO: consider throwing here both projection_unknown_id_exception and
// projection_not_named_exception in order to throw before other exceptions
//if (pin.name.empty())
//{ BOOST_THROW_EXCEPTION( projection_not_named_exception() ); }
// set defaults, unless inhibited
// GL-Addition, if use_defaults is false then defaults are ignored
if (use_defaults && ! pj_param(pin.params, "bno_defs").i)
{
// proj4 gets defaults from "proj_def.dat", file of 94/02/23 with a few defaults.
// Here manually
pj_push_defaults(bg_params, pin);
//curr = get_defaults(&arguments, curr, name);
}
/* allocate projection structure */
// done by BGParams constructor:
// pin.is_latlong = 0;
// pin.is_geocent = 0;
// pin.long_wrap_center = 0.0;
// pin.long_wrap_center = 0.0;
pin.is_long_wrap_set = false;
/* set datum parameters */
pj_datum_set(bg_params, pin.params, pin);
/* set ellipsoid/sphere parameters */
pj_ell_set(bg_params, pin.params, pin.a, pin.es);
pin.a_orig = pin.a;
pin.es_orig = pin.es;
pin.e = sqrt(pin.es);
pin.ra = 1. / pin.a;
pin.one_es = 1. - pin.es;
if (pin.one_es == 0.) {
BOOST_THROW_EXCEPTION( projection_exception(-6) );
}
pin.rone_es = 1./pin.one_es;
/* Now that we have ellipse information check for WGS84 datum */
if( pin.datum_type == PJD_3PARAM
&& pin.datum_params[0] == 0.0
&& pin.datum_params[1] == 0.0
&& pin.datum_params[2] == 0.0
&& pin.a == 6378137.0
&& geometry::math::abs(pin.es - 0.006694379990) < 0.000000000050 )/*WGS84/GRS80*/
{
pin.datum_type = PJD_WGS84;
}
/* set pin.geoc coordinate system */
pin.geoc = (pin.es && pj_param(pin.params, "bgeoc").i);
/* over-ranging flag */
pin.over = pj_param(pin.params, "bover").i;
/* longitude center for wrapping */
pin.is_long_wrap_set = pj_param(pin.params, "tlon_wrap").i != 0;
if (pin.is_long_wrap_set)
pin.long_wrap_center = pj_param(pin.params, "rlon_wrap").f;
/* central meridian */
pin.lam0 = pj_param(pin.params, "rlon_0").f;
/* central latitude */
pin.phi0 = pj_param(pin.params, "rlat_0").f;
/* false easting and northing */
pin.x0 = pj_param(pin.params, "dx_0").f;
pin.y0 = pj_param(pin.params, "dy_0").f;
/* general scaling factor */
if (pj_param(pin.params, "tk_0").i)
pin.k0 = pj_param(pin.params, "dk_0").f;
else if (pj_param(pin.params, "tk").i)
pin.k0 = pj_param(pin.params, "dk").f;
else
pin.k0 = 1.;
if (pin.k0 <= 0.) {
BOOST_THROW_EXCEPTION( projection_exception(-31) );
}
/* set units */
pj_init_units(pin.params, "sunits", "sto_meter",
pin.to_meter, pin.fr_meter, 1., 1.);
pj_init_units(pin.params, "svunits", "svto_meter",
pin.vto_meter, pin.vfr_meter, pin.to_meter, pin.fr_meter);
/* prime meridian */
std::string pm = pj_param(pin.params, "spm").s;
if (! pm.empty())
{
std::string value;
int n = sizeof(pj_prime_meridians) / sizeof(pj_prime_meridians[0]);
int index = -1;
for (int i = 0; i < n && index == -1; i++)
{
if(pj_prime_meridians[i].id == pm)
{
value = pj_prime_meridians[i].defn;
index = i;
}
}
if (index == -1) {
BOOST_THROW_EXCEPTION( projection_exception(-7) );
}
if (value.empty()) {
BOOST_THROW_EXCEPTION( projection_exception(-46) );
}
dms_parser<T, true> parser;
pin.from_greenwich = parser.apply(value.c_str()).angle();
}
else
{
pin.from_greenwich = 0.0;
}
return pin;
}
/************************************************************************/
/* pj_init_plus() */
/* */
/* Same as pj_init() except it takes one argument string with */
/* individual arguments preceeded by '+', such as "+proj=utm */
/* +zone=11 +ellps=WGS84". */
/************************************************************************/
template <typename T, typename BGParams>
inline parameters<T> pj_init_plus(BGParams const& bg_params, std::string const& definition, bool use_defaults = true)
{
const char* sep = " +";
/* split into arguments based on '+' and trim white space */
// boost::split splits on one character, here it should be on " +", so implementation below
// todo: put in different routine or sort out
std::vector<std::string> arguments;
std::string def = boost::trim_copy(definition);
boost::trim_left_if(def, boost::is_any_of(sep));
std::string::size_type loc = def.find(sep);
while (loc != std::string::npos)
{
std::string par = def.substr(0, loc);
boost::trim(par);
if (! par.empty())
{
arguments.push_back(par);
}
def.erase(0, loc);
boost::trim_left_if(def, boost::is_any_of(sep));
loc = def.find(sep);
}
if (! def.empty())
{
arguments.push_back(def);
}
/*boost::split(arguments, definition, boost::is_any_of("+"));
for (std::vector<std::string>::iterator it = arguments.begin(); it != arguments.end(); it++)
{
boost::trim(*it);
}*/
return pj_init<T>(bg_params, arguments, use_defaults);
}
} // namespace detail
}}} // namespace boost::geometry::projections
#endif // BOOST_GEOMETRY_PROJECTIONS_IMPL_PJ_INIT_HPP

View File

@@ -0,0 +1,82 @@
// Boost.Geometry (aka GGL, Generic Geometry Library)
// This file is manually converted from PROJ4
// Copyright (c) 2008-2012 Barend Gehrels, Amsterdam, the Netherlands.
// This file was modified by Oracle on 2017.
// Modifications copyright (c) 2017, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
// This file is converted from PROJ4, http://trac.osgeo.org/proj
// PROJ4 is originally written by Gerald Evenden (then of the USGS)
// PROJ4 is maintained by Frank Warmerdam
// PROJ4 is converted to Geometry Library by Barend Gehrels (Geodan, Amsterdam)
// Original copyright notice:
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the "Software"),
// to deal in the Software without restriction, including without limitation
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
// and/or sell copies of the Software, and to permit persons to whom the
// Software is furnished to do so, subject to the following conditions:
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Software.
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.
#ifndef BOOST_GEOMETRY_PROJECTIONS_PJ_INV_HPP
#define BOOST_GEOMETRY_PROJECTIONS_PJ_INV_HPP
#include <boost/geometry/srs/projections/impl/adjlon.hpp>
#include <boost/geometry/core/radian_access.hpp>
#include <boost/geometry/util/math.hpp>
/* general inverse projection */
namespace boost { namespace geometry { namespace projections
{
namespace detail
{
/* inverse projection entry */
template <typename PRJ, typename LL, typename XY, typename PAR>
inline void pj_inv(PRJ const& prj, PAR const& par, XY const& xy, LL& ll)
{
typedef typename PAR::type calc_t;
static const calc_t EPS = 1.0e-12;
/* can't do as much preliminary checking as with forward */
/* descale and de-offset */
calc_t xy_x = (geometry::get<0>(xy) * par.to_meter - par.x0) * par.ra;
calc_t xy_y = (geometry::get<1>(xy) * par.to_meter - par.y0) * par.ra;
calc_t lon = 0, lat = 0;
prj.inv(xy_x, xy_y, lon, lat); /* inverse project */
lon += par.lam0; /* reduce from del lp.lam */
if (!par.over)
lon = adjlon(lon); /* adjust longitude to CM */
if (par.geoc && geometry::math::abs(geometry::math::abs(lat)-geometry::math::half_pi<calc_t>()) > EPS)
lat = atan(par.one_es * tan(lat));
geometry::set_from_radian<0>(ll, lon);
geometry::set_from_radian<1>(ll, lat);
}
} // namespace detail
}}} // namespace boost::geometry::projections
#endif

View File

@@ -0,0 +1,121 @@
// Boost.Geometry (aka GGL, Generic Geometry Library)
// This file is manually converted from PROJ4
// Copyright (c) 2008-2012 Barend Gehrels, Amsterdam, the Netherlands.
// This file was modified by Oracle on 2017.
// Modifications copyright (c) 2017, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
// This file is converted from PROJ4, http://trac.osgeo.org/proj
// PROJ4 is originally written by Gerald Evenden (then of the USGS)
// PROJ4 is maintained by Frank Warmerdam
// PROJ4 is converted to Geometry Library by Barend Gehrels (Geodan, Amsterdam)
// Original copyright notice:
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the "Software"),
// to deal in the Software without restriction, including without limitation
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
// and/or sell copies of the Software, and to permit persons to whom the
// Software is furnished to do so, subject to the following conditions:
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Software.
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.
#ifndef BOOST_GEOMETRY_PROJECTIONS_PJ_MLFN_HPP
#define BOOST_GEOMETRY_PROJECTIONS_PJ_MLFN_HPP
#include <boost/geometry/util/math.hpp>
namespace boost { namespace geometry { namespace projections {
namespace detail {
static const int EN_SIZE = 5;
template <typename T>
inline bool pj_enfn(T const& es, T* en)
{
static const T C00 = 1.;
static const T C02 = .25;
static const T C04 = .046875;
static const T C06 = .01953125;
static const T C08 = .01068115234375;
static const T C22 = .75;
static const T C44 = .46875;
static const T C46 = .01302083333333333333;
static const T C48 = .00712076822916666666;
static const T C66 = .36458333333333333333;
static const T C68 = .00569661458333333333;
static const T C88 = .3076171875;
T t; //, *en;
//if (en = (double *)pj_malloc(EN_SIZE * sizeof(double)))
{
en[0] = C00 - es * (C02 + es * (C04 + es * (C06 + es * C08)));
en[1] = es * (C22 - es * (C04 + es * (C06 + es * C08)));
en[2] = (t = es * es) * (C44 - es * (C46 + es * C48));
en[3] = (t *= es) * (C66 - es * C68);
en[4] = t * es * C88;
}
// return en;
return true;
}
template <typename T>
inline T pj_mlfn(T const& phi, T sphi, T cphi, const T *en)
{
cphi *= sphi;
sphi *= sphi;
return(en[0] * phi - cphi * (en[1] + sphi*(en[2]
+ sphi*(en[3] + sphi*en[4]))));
}
template <typename T>
inline T pj_inv_mlfn(T const& arg, T const& es, const T *en)
{
/* meridinal distance for ellipsoid and inverse
** 8th degree - accurate to < 1e-5 meters when used in conjuction
** with typical major axis values.
** Inverse determines phi to EPS (1e-11) radians, about 1e-6 seconds.
*/
static const T EPS = 1e-11;
static const int MAX_ITER = 10;
T s, t, phi, k = 1./(1.-es);
int i;
phi = arg;
for (i = MAX_ITER; i ; --i) { /* rarely goes over 2 iterations */
s = sin(phi);
t = 1. - es * s * s;
phi -= t = (pj_mlfn(phi, s, cos(phi), en) - arg) * (t * sqrt(t)) * k;
if (geometry::math::abs(t) < EPS)
return phi;
}
BOOST_THROW_EXCEPTION( projection_exception(-17) );
return phi;
}
} // namespace detail
}}} // namespace boost::geometry::projections
#endif

View File

@@ -0,0 +1,59 @@
// Boost.Geometry (aka GGL, Generic Geometry Library)
// This file is manually converted from PROJ4
// Copyright (c) 2008-2012 Barend Gehrels, Amsterdam, the Netherlands.
// This file was modified by Oracle on 2017.
// Modifications copyright (c) 2017, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
// This file is converted from PROJ4, http://trac.osgeo.org/proj
// PROJ4 is originally written by Gerald Evenden (then of the USGS)
// PROJ4 is maintained by Frank Warmerdam
// PROJ4 is converted to Geometry Library by Barend Gehrels (Geodan, Amsterdam)
// Original copyright notice:
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the "Software"),
// to deal in the Software without restriction, including without limitation
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
// and/or sell copies of the Software, and to permit persons to whom the
// Software is furnished to do so, subject to the following conditions:
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Software.
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.
#ifndef BOOST_GEOMETRY_PROJECTIONS_PJ_MSFN_HPP
#define BOOST_GEOMETRY_PROJECTIONS_PJ_MSFN_HPP
namespace boost { namespace geometry { namespace projections {
namespace detail {
/* determine constant small m */
template <typename T>
inline T pj_msfn(T const& sinphi, T const& cosphi, T const& es)
{
return (cosphi / sqrt (1. - es * sinphi * sinphi));
}
} // namespace detail
}}} // namespace boost::geometry::projections
#endif

View File

@@ -0,0 +1,161 @@
// Boost.Geometry (aka GGL, Generic Geometry Library)
// This file is manually converted from PROJ4
// Copyright (c) 2008-2012 Barend Gehrels, Amsterdam, the Netherlands.
// This file was modified by Oracle on 2017.
// Modifications copyright (c) 2017, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
// This file is converted from PROJ4, http://trac.osgeo.org/proj
// PROJ4 is originally written by Gerald Evenden (then of the USGS)
// PROJ4 is maintained by Frank Warmerdam
// PROJ4 is converted to Geometry Library by Barend Gehrels (Geodan, Amsterdam)
// Original copyright notice:
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the "Software"),
// to deal in the Software without restriction, including without limitation
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
// and/or sell copies of the Software, and to permit persons to whom the
// Software is furnished to do so, subject to the following conditions:
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Software.
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.
#ifndef BOOST_GEOMETRY_PROJECTIONS_PJ_PARAM_HPP
#define BOOST_GEOMETRY_PROJECTIONS_PJ_PARAM_HPP
#include <string>
#include <vector>
#include <boost/geometry/srs/projections/impl/dms_parser.hpp>
#include <boost/geometry/srs/projections/impl/projects.hpp>
namespace boost { namespace geometry { namespace projections {
namespace detail {
/* create pvalue list entry */
template <typename T>
inline pvalue<T> pj_mkparam(std::string const& str)
{
std::string name = str;
std::string value;
boost::trim_left_if(name, boost::is_any_of("+"));
std::string::size_type loc = name.find("=");
if (loc != std::string::npos)
{
value = name.substr(loc + 1);
name.erase(loc);
}
pvalue<T> newitem;
newitem.param = name;
newitem.s = value;
newitem.used = 0;
newitem.i = atoi(value.c_str());
newitem.f = atof(value.c_str());
return newitem;
}
/************************************************************************/
/* pj_param() */
/* */
/* Test for presence or get pvalue value. The first */
/* character in `opt' is a pvalue type which can take the */
/* values: */
/* */
/* `t' - test for presence, return TRUE/FALSE in pvalue.i */
/* `i' - integer value returned in pvalue.i */
/* `d' - simple valued real input returned in pvalue.f */
/* `r' - degrees (DMS translation applied), returned as */
/* radians in pvalue.f */
/* `s' - string returned in pvalue.s */
/* `b' - test for t/T/f/F, return in pvalue.i */
/* */
/************************************************************************/
template <typename T>
inline pvalue<T> pj_param(std::vector<pvalue<T> > const& pl, std::string opt)
{
char type = opt[0];
opt.erase(opt.begin());
pvalue<T> value;
/* simple linear lookup */
typedef typename std::vector<pvalue<T> >::const_iterator iterator;
for (iterator it = pl.begin(); it != pl.end(); it++)
{
if (it->param == opt)
{
//it->used = 1;
switch (type)
{
case 't':
value.i = 1;
break;
case 'i': /* integer input */
value.i = atoi(it->s.c_str());
break;
case 'd': /* simple real input */
value.f = atof(it->s.c_str());
break;
case 'r': /* degrees input */
{
dms_parser<T, true> parser;
value.f = parser.apply(it->s.c_str()).angle();
}
break;
case 's': /* char string */
value.s = it->s;
break;
case 'b': /* boolean */
switch (it->s[0])
{
case 'F': case 'f':
value.i = 0;
break;
case '\0': case 'T': case 't':
value.i = 1;
break;
default:
value.i = 0;
break;
}
break;
}
return value;
}
}
value.i = 0;
value.f = 0.0;
value.s = "";
return value;
}
} // namespace detail
}}} // namespace boost::geometry::projections
#endif

View File

@@ -0,0 +1,73 @@
// Boost.Geometry (aka GGL, Generic Geometry Library)
// This file is manually converted from PROJ4
// Copyright (c) 2008-2012 Barend Gehrels, Amsterdam, the Netherlands.
// This file was modified by Oracle on 2017.
// Modifications copyright (c) 2017, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
// This file is converted from PROJ4, http://trac.osgeo.org/proj
// PROJ4 is originally written by Gerald Evenden (then of the USGS)
// PROJ4 is maintained by Frank Warmerdam
// PROJ4 is converted to Geometry Library by Barend Gehrels (Geodan, Amsterdam)
// Original copyright notice:
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the "Software"),
// to deal in the Software without restriction, including without limitation
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
// and/or sell copies of the Software, and to permit persons to whom the
// Software is furnished to do so, subject to the following conditions:
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Software.
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.
#ifndef BOOST_GEOMETRY_PROJECTIONS_PHI2_HPP
#define BOOST_GEOMETRY_PROJECTIONS_PHI2_HPP
#include <boost/geometry/util/math.hpp>
namespace boost { namespace geometry { namespace projections {
namespace detail {
template <typename T>
inline T pj_phi2(T const& ts, T const& e)
{
static const T TOL = 1.0e-10;
static const int N_ITER = 15;
T eccnth, Phi, con, dphi;
int i;
eccnth = .5 * e;
Phi = geometry::math::half_pi<T>() - 2. * atan (ts);
i = N_ITER;
do {
con = e * sin (Phi);
dphi = geometry::math::half_pi<T>() - 2. * atan (ts * pow((1. - con) /
(1. + con), eccnth)) - Phi;
Phi += dphi;
} while ( geometry::math::abs(dphi) > TOL && --i);
if (i <= 0)
BOOST_THROW_EXCEPTION( projection_exception(-18) );
return Phi;
}
} // namespace detail
}}} // namespace boost::geometry::projections
#endif

View File

@@ -0,0 +1,95 @@
// Boost.Geometry (aka GGL, Generic Geometry Library)
// This file is manually converted from PROJ4
// Copyright (c) 2008-2012 Barend Gehrels, Amsterdam, the Netherlands.
// This file was modified by Oracle on 2017.
// Modifications copyright (c) 2017, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
// This file is converted from PROJ4, http://trac.osgeo.org/proj
// PROJ4 is originally written by Gerald Evenden (then of the USGS)
// PROJ4 is maintained by Frank Warmerdam
// PROJ4 is converted to Geometry Library by Barend Gehrels (Geodan, Amsterdam)
// Original copyright notice:
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the "Software"),
// to deal in the Software without restriction, including without limitation
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
// and/or sell copies of the Software, and to permit persons to whom the
// Software is furnished to do so, subject to the following conditions:
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Software.
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.
#ifndef BOOST_GEOMETRY_PROJECTIONS_PJ_QSFN_HPP
#define BOOST_GEOMETRY_PROJECTIONS_PJ_QSFN_HPP
namespace boost { namespace geometry { namespace projections
{
namespace detail {
/* determine small q */
template <typename T>
inline T pj_qsfn(T const& sinphi, T const& e, T const& one_es)
{
static const T EPSILON = 1.0e-7;
if (e >= EPSILON)
{
T con = e * sinphi;
return (one_es * (sinphi / (1. - con * con) -
(.5 / e) * log ((1. - con) / (1. + con))));
} else
return (sinphi + sinphi);
}
static const int MAX_C = 9;
template <typename T>
struct AUTHALIC
{
T C[MAX_C], CP[MAX_C], CQ[MAX_C];
};
/**
* @brief determine authalic latitude
* @param[in] phi geographic latitude
* @param[in] a initialized structure pointer
* @return authalic latitude
*/
template <typename T>
inline T proj_qsfn(T const& phi, AUTHALIC<T> const& a)
{
T s, s2, sum;
int i = MAX_C;
s = sin(phi);
s2 = s * s;
sum = a.CQ[MAX_C - 1];
while (--i) sum = a.CQ[i] + s2 * sum;
return(s * sum);
}
} // namespace detail
}}} // namespace boost::geometry::projections
#endif

View File

@@ -0,0 +1,120 @@
// Boost.Geometry
// This file is manually converted from PROJ4
// This file was modified by Oracle on 2017.
// Modifications copyright (c) 2017, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
// This file is converted from PROJ4, http://trac.osgeo.org/proj
// PROJ4 is originally written by Gerald Evenden (then of the USGS)
// PROJ4 is maintained by Frank Warmerdam
// This file was converted to Geometry Library by Adam Wulkiewicz
// Original copyright notice:
// None
/* list of projection system pj_errno values */
#ifndef BOOST_GEOMETRY_PROJECTIONS_IMPL_PJ_STRERRNO_HPP
#define BOOST_GEOMETRY_PROJECTIONS_IMPL_PJ_STRERRNO_HPP
#include <cstring>
#include <sstream>
#include <string>
namespace boost { namespace geometry { namespace projections
{
namespace detail
{
static const char *
pj_err_list[] = {
"no arguments in initialization list", /* -1 */
"no options found in 'init' file", /* -2 */
"no colon in init= string", /* -3 */
"projection not named", /* -4 */
"unknown projection id", /* -5 */
"effective eccentricity = 1.", /* -6 */
"unknown unit conversion id", /* -7 */
"invalid boolean param argument", /* -8 */
"unknown elliptical parameter name", /* -9 */
"reciprocal flattening (1/f) = 0", /* -10 */
"|radius reference latitude| > 90", /* -11 */
"squared eccentricity < 0", /* -12 */
"major axis or radius = 0 or not given", /* -13 */
"latitude or longitude exceeded limits", /* -14 */
"invalid x or y", /* -15 */
"improperly formed DMS value", /* -16 */
"non-convergent inverse meridional dist", /* -17 */
"non-convergent inverse phi2", /* -18 */
"acos/asin: |arg| >1.+1e-14", /* -19 */
"tolerance condition error", /* -20 */
"conic lat_1 = -lat_2", /* -21 */
"lat_1 >= 90", /* -22 */
"lat_1 = 0", /* -23 */
"lat_ts >= 90", /* -24 */
"no distance between control points", /* -25 */
"projection not selected to be rotated", /* -26 */
"W <= 0 or M <= 0", /* -27 */
"lsat not in 1-5 range", /* -28 */
"path not in range", /* -29 */
"h <= 0", /* -30 */
"k <= 0", /* -31 */
"lat_0 = 0 or 90 or alpha = 90", /* -32 */
"lat_1=lat_2 or lat_1=0 or lat_2=90", /* -33 */
"elliptical usage required", /* -34 */
"invalid UTM zone number", /* -35 */
"arg(s) out of range for Tcheby eval", /* -36 */
"failed to find projection to be rotated", /* -37 */
"failed to load datum shift file", /* -38 */
"both n & m must be spec'd and > 0", /* -39 */
"n <= 0, n > 1 or not specified", /* -40 */
"lat_1 or lat_2 not specified", /* -41 */
"|lat_1| == |lat_2|", /* -42 */
"lat_0 is pi/2 from mean lat", /* -43 */
"unparseable coordinate system definition", /* -44 */
"geocentric transformation missing z or ellps", /* -45 */
"unknown prime meridian conversion id", /* -46 */
"illegal axis orientation combination", /* -47 */
"point not within available datum shift grids", /* -48 */
"invalid sweep axis, choose x or y", /* -49 */
"malformed pipeline", /* -50 */
};
inline std::string pj_strerrno(int err) {
if (0==err)
return "";
if (err > 0) {
//#ifdef HAVE_STRERROR
return ::strerror(err);
//#else
// std::stringstream ss;
// ss << "no system list, errno: " << err;
// return ss.str();
//#endif
}
else /*if (err < 0)*/ {
size_t adjusted_err = - err - 1;
if (adjusted_err < (sizeof(pj_err_list) / sizeof(char *)))
return(pj_err_list[adjusted_err]);
else {
std::stringstream ss;
ss << "invalid projection system error (" << err << ")";
return ss.str();
}
}
}
} // namespace detail
}}} // namespace boost::geometry::projections
#endif // BOOST_GEOMETRY_PROJECTIONS_IMPL_PJ_STRERRNO_HPP

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,58 @@
// Boost.Geometry (aka GGL, Generic Geometry Library)
// This file is manually converted from PROJ4
// Copyright (c) 2008-2012 Barend Gehrels, Amsterdam, the Netherlands.
// This file was modified by Oracle on 2017.
// Modifications copyright (c) 2017, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
// This file is converted from PROJ4, http://trac.osgeo.org/proj
// PROJ4 is originally written by Gerald Evenden (then of the USGS)
// PROJ4 is maintained by Frank Warmerdam
// PROJ4 is converted to Geometry Library by Barend Gehrels (Geodan, Amsterdam)
// Original copyright notice:
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the "Software"),
// to deal in the Software without restriction, including without limitation
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
// and/or sell copies of the Software, and to permit persons to whom the
// Software is furnished to do so, subject to the following conditions:
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Software.
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.
#ifndef BOOST_GEOMETRY_PROJECTIONS_PJ_TSFN_HPP
#define BOOST_GEOMETRY_PROJECTIONS_PJ_TSFN_HPP
#include <boost/geometry/util/math.hpp>
namespace boost { namespace geometry { namespace projections {
namespace detail {
/* determine small t */
template <typename T>
inline T pj_tsfn(T const& phi, T sinphi, T const& e)
{
sinphi *= e;
return (tan (.5 * (geometry::math::half_pi<T>() - phi)) /
pow((1. - sinphi) / (1. + sinphi), .5 * e));
}
} // namespace detail
}}} // namespace boost::geometry::projections
#endif

View File

@@ -0,0 +1,79 @@
// Boost.Geometry (aka GGL, Generic Geometry Library)
// This file is manually converted from PROJ4
// Copyright (c) 2008-2012 Barend Gehrels, Amsterdam, the Netherlands.
// This file was modified by Oracle on 2017.
// Modifications copyright (c) 2017, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
// This file is converted from PROJ4, http://trac.osgeo.org/proj
// PROJ4 is originally written by Gerald Evenden (then of the USGS)
// PROJ4 is maintained by Frank Warmerdam
// PROJ4 is converted to Geometry Library by Barend Gehrels (Geodan, Amsterdam)
// Original copyright notice:
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the "Software"),
// to deal in the Software without restriction, including without limitation
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
// and/or sell copies of the Software, and to permit persons to whom the
// Software is furnished to do so, subject to the following conditions:
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Software.
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.
#ifndef BOOST_GEOMETRY_PROJECTIONS_IMPL_PJ_UNITS_HPP
#define BOOST_GEOMETRY_PROJECTIONS_IMPL_PJ_UNITS_HPP
#include <boost/geometry/srs/projections/impl/projects.hpp>
namespace boost { namespace geometry { namespace projections {
namespace detail {
/* Field 2 that contains the multiplier to convert named units to meters
** may be expressed by either a simple floating point constant or a
** numerator/denomenator values (e.g. 1/1000) */
static const PJ_UNITS pj_units[] =
{
{ "km", "1000.", "Kilometer" },
{ "m", "1.", "Meter" },
{ "dm", "1/10", "Decimeter" },
{ "cm", "1/100", "Centimeter" },
{ "mm", "1/1000", "Millimeter" },
{ "kmi", "1852.0", "International Nautical Mile" },
{ "in", "0.0254", "International Inch" },
{ "ft", "0.3048", "International Foot" },
{ "yd", "0.9144", "International Yard" },
{ "mi", "1609.344", "International Statute Mile" },
{ "fath", "1.8288", "International Fathom" },
{ "ch", "20.1168", "International Chain" },
{ "link", "0.201168", "International Link" },
{ "us-in", "1./39.37", "U.S. Surveyor's Inch" },
{ "us-ft", "0.304800609601219", "U.S. Surveyor's Foot" },
{ "us-yd", "0.914401828803658", "U.S. Surveyor's Yard" },
{ "us-ch", "20.11684023368047", "U.S. Surveyor's Chain" },
{ "us-mi", "1609.347218694437", "U.S. Surveyor's Statute Mile" },
{ "ind-yd", "0.91439523", "Indian Yard" },
{ "ind-ft", "0.30479841", "Indian Foot" },
{ "ind-ch", "20.11669506", "Indian Chain" }
};
} // detail
}}} // namespace boost::geometry::projections
#endif // BOOST_GEOMETRY_PROJECTIONS_IMPL_PJ_UNITS_HPP

View File

@@ -0,0 +1,106 @@
// Boost.Geometry (aka GGL, Generic Geometry Library)
// This file is manually converted from PROJ4
// Copyright (c) 2008-2012 Barend Gehrels, Amsterdam, the Netherlands.
// This file was modified by Oracle on 2017.
// Modifications copyright (c) 2017, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
// This file is converted from PROJ4, http://trac.osgeo.org/proj
// PROJ4 is originally written by Gerald Evenden (then of the USGS)
// PROJ4 is maintained by Frank Warmerdam
// PROJ4 is converted to Geometry Library by Barend Gehrels (Geodan, Amsterdam)
// Original copyright notice:
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the "Software"),
// to deal in the Software without restriction, including without limitation
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
// and/or sell copies of the Software, and to permit persons to whom the
// Software is furnished to do so, subject to the following conditions:
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Software.
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.
#ifndef BOOST_GEOMETRY_PROJECTIONS_ZPOLY1_HPP
#define BOOST_GEOMETRY_PROJECTIONS_ZPOLY1_HPP
#include <boost/geometry/srs/projections/impl/projects.hpp>
namespace boost { namespace geometry { namespace projections { namespace detail {
/* evaluate complex polynomial */
/* note: coefficients are always from C_1 to C_n
** i.e. C_0 == (0., 0)
** n should always be >= 1 though no checks are made
*/
template <typename T>
inline COMPLEX<T>
pj_zpoly1(COMPLEX<T> z, const COMPLEX<T> *C, int n)
{
COMPLEX<T> a;
T t;
a = *(C += n);
while (n-- > 0)
{
a.r = (--C)->r + z.r * (t = a.r) - z.i * a.i;
a.i = C->i + z.r * a.i + z.i * t;
}
a.r = z.r * (t = a.r) - z.i * a.i;
a.i = z.r * a.i + z.i * t;
return a;
}
/* evaluate complex polynomial and derivative */
template <typename T>
inline COMPLEX<T>
pj_zpolyd1(COMPLEX<T> z, const COMPLEX<T> *C, int n, COMPLEX<T> *der)
{
T t;
bool first = true;
COMPLEX<T> a = *(C += n);
COMPLEX<T> b = a;
while (n-- > 0)
{
if (first)
{
first = false;
}
else
{
b.r = a.r + z.r * (t = b.r) - z.i * b.i;
b.i = a.i + z.r * b.i + z.i * t;
}
a.r = (--C)->r + z.r * (t = a.r) - z.i * a.i;
a.i = C->i + z.r * a.i + z.i * t;
}
b.r = a.r + z.r * (t = b.r) - z.i * b.i;
b.i = a.i + z.r * b.i + z.i * t;
a.r = z.r * (t = a.r) - z.i * a.i;
a.i = z.r * a.i + z.i * t;
*der = b;
return a;
}
}}}} // namespace boost::geometry::projections::detail
#endif

View File

@@ -0,0 +1,144 @@
// Boost.Geometry (aka GGL, Generic Geometry Library)
// This file is manually converted from PROJ4
// Copyright (c) 2008-2012 Barend Gehrels, Amsterdam, the Netherlands.
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
// This file is converted from PROJ4, http://trac.osgeo.org/proj
// PROJ4 is originally written by Gerald Evenden (then of the USGS)
// PROJ4 is maintained by Frank Warmerdam
// PROJ4 is converted to Geometry Library by Barend Gehrels (Geodan, Amsterdam)
// Original copyright notice:
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the "Software"),
// to deal in the Software without restriction, including without limitation
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
// and/or sell copies of the Software, and to permit persons to whom the
// Software is furnished to do so, subject to the following conditions:
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Software.
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.
#ifndef BOOST_GEOMETRY_PROJECTIONS_PROJ_MDIST_HPP
#define BOOST_GEOMETRY_PROJECTIONS_PROJ_MDIST_HPP
#include <boost/geometry/util/math.hpp>
namespace boost { namespace geometry { namespace projections
{
namespace detail
{
static const int MDIST_MAX_ITER = 20;
template <typename T>
struct MDIST
{
int nb;
T es;
T E;
T b[MDIST_MAX_ITER];
};
template <typename CT>
inline bool proj_mdist_ini(CT const& es, MDIST<CT>& b)
{
CT numf, numfi, twon1, denf, denfi, ens, T, twon;
CT den, El, Es;
CT E[MDIST_MAX_ITER];
int i, j;
/* generate E(e^2) and its terms E[] */
ens = es;
numf = twon1 = denfi = 1.;
denf = 1.;
twon = 4.;
Es = El = E[0] = 1.;
for (i = 1; i < MDIST_MAX_ITER ; ++i)
{
numf *= (twon1 * twon1);
den = twon * denf * denf * twon1;
T = numf/den;
Es -= (E[i] = T * ens);
ens *= es;
twon *= 4.;
denf *= ++denfi;
twon1 += 2.;
if (Es == El) /* jump out if no change */
break;
El = Es;
}
b.nb = i - 1;
b.es = es;
b.E = Es;
/* generate b_n coefficients--note: collapse with prefix ratios */
b.b[0] = Es = 1. - Es;
numf = denf = 1.;
numfi = 2.;
denfi = 3.;
for (j = 1; j < i; ++j)
{
Es -= E[j];
numf *= numfi;
denf *= denfi;
b.b[j] = Es * numf / denf;
numfi += 2.;
denfi += 2.;
}
return true;
}
template <typename T>
inline T proj_mdist(T const& phi, T const& sphi, T const& cphi, MDIST<T> const& b)
{
T sc, sum, sphi2, D;
int i;
sc = sphi * cphi;
sphi2 = sphi * sphi;
D = phi * b.E - b.es * sc / sqrt(1. - b.es * sphi2);
sum = b.b[i = b.nb];
while (i) sum = b.b[--i] + sphi2 * sum;
return(D + sc * sum);
}
template <typename T>
inline T proj_inv_mdist(T const& dist, MDIST<T> const& b)
{
static const T TOL = 1e-14;
T s, t, phi, k;
int i;
k = 1./(1.- b.es);
i = MDIST_MAX_ITER;
phi = dist;
while ( i-- ) {
s = sin(phi);
t = 1. - b.es * s * s;
phi -= t = (proj_mdist(phi, s, cos(phi), b) - dist) *
(t * sqrt(t)) * k;
if (geometry::math::abs(t) < TOL) /* that is no change */
return phi;
}
/* convergence failed */
BOOST_THROW_EXCEPTION( projection_exception(-17) );
}
} // namespace detail
}}} // namespace boost::geometry::projections
#endif

View File

@@ -0,0 +1,272 @@
// Boost.Geometry (aka GGL, Generic Geometry Library)
// This file is manually converted from PROJ4 (projects.h)
// Copyright (c) 2008-2012 Barend Gehrels, Amsterdam, the Netherlands.
// This file was modified by Oracle on 2017.
// Modifications copyright (c) 2017, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
// This file is converted from PROJ4, http://trac.osgeo.org/proj
// PROJ4 is originally written by Gerald Evenden (then of the USGS)
// PROJ4 is maintained by Frank Warmerdam
// PROJ4 is converted to Geometry Library by Barend Gehrels (Geodan, Amsterdam)
// Original copyright notice:
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the "Software"),
// to deal in the Software without restriction, including without limitation
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
// and/or sell copies of the Software, and to permit persons to whom the
// Software is furnished to do so, subject to the following conditions:
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Software.
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.
#ifndef BOOST_GEOMETRY_PROJECTIONS_IMPL_PROJECTS_HPP
#define BOOST_GEOMETRY_PROJECTIONS_IMPL_PROJECTS_HPP
#include <cstring>
#include <string>
#include <vector>
#include <boost/geometry/srs/projections/exception.hpp>
#include <boost/math/constants/constants.hpp>
#include <boost/mpl/if.hpp>
#include <boost/type_traits/is_pod.hpp>
namespace boost { namespace geometry { namespace projections
{
#ifndef DOXYGEN_NO_DETAIL
namespace detail
{
/* some useful constants */
template <typename T>
inline T ONEPI() { return boost::math::constants::pi<T>(); }
template <typename T>
inline T HALFPI() { return boost::math::constants::half_pi<T>(); }
template <typename T>
inline T FORTPI() { return boost::math::constants::pi<T>() / T(4); }
template <typename T>
inline T TWOPI() { return boost::math::constants::two_pi<T>(); }
template <typename T>
inline T TWO_D_PI() { return boost::math::constants::two_div_pi<T>(); }
template <typename T>
inline T HALFPI_SQR() { return 2.4674011002723396547086227499689; }
template <typename T>
inline T PI_SQR() { return boost::math::constants::pi_sqr<T>(); }
template <typename T>
inline T THIRD() { return 0.3333333333333333333333333333333; }
template <typename T>
inline T TWOTHIRD() { return 0.6666666666666666666666666666666; }
template <typename T>
inline T PI_HALFPI() { return 4.7123889803846898576939650749193; }
template <typename T>
inline T TWOPI_HALFPI() { return 7.8539816339744830961566084581988; }
template <typename T>
inline T PI_DIV_3() { return 1.0471975511965977461542144610932; }
/* datum_type values */
static const int PJD_UNKNOWN = 0;
static const int PJD_3PARAM = 1;
static const int PJD_7PARAM = 2;
static const int PJD_GRIDSHIFT = 3;
static const int PJD_WGS84 = 4; /* WGS84 (or anything considered equivelent) */
/* library errors */
static const int PJD_ERR_GEOCENTRIC = -45;
static const int PJD_ERR_AXIS = -47;
static const int PJD_ERR_GRID_AREA = -48;
static const int PJD_ERR_CATALOG = -49;
template <typename T>
struct pvalue
{
std::string param;
int used;
int i;
T f;
std::string s;
};
template <typename T>
struct pj_const_pod
{
int over; /* over-range flag */
int geoc; /* geocentric latitude flag */
int is_latlong; /* proj=latlong ... not really a projection at all */
int is_geocent; /* proj=geocent ... not really a projection at all */
T
a, /* major axis or radius if es==0 */
a_orig, /* major axis before any +proj related adjustment */
es, /* e ^ 2 */
es_orig, /* es before any +proj related adjustment */
e, /* eccentricity */
ra, /* 1/A */
one_es, /* 1 - e^2 */
rone_es, /* 1/one_es */
lam0, phi0, /* central longitude, latitude */
x0, y0, /* easting and northing */
k0, /* general scaling factor */
to_meter, fr_meter, /* cartesian scaling */
vto_meter, vfr_meter; /* Vertical scaling. Internal unit [m] */
int datum_type; /* PJD_UNKNOWN/3PARAM/7PARAM/GRIDSHIFT/WGS84 */
T datum_params[7];
T from_greenwich; /* prime meridian offset (in radians) */
T long_wrap_center; /* 0.0 for -180 to 180, actually in radians*/
bool is_long_wrap_set;
// Initialize all variables to zero
pj_const_pod()
{
std::memset(this, 0, sizeof(pj_const_pod));
}
};
template <typename T>
struct pj_const_non_pod
{
int over; /* over-range flag */
int geoc; /* geocentric latitude flag */
int is_latlong; /* proj=latlong ... not really a projection at all */
int is_geocent; /* proj=geocent ... not really a projection at all */
T
a, /* major axis or radius if es==0 */
a_orig, /* major axis before any +proj related adjustment */
es, /* e ^ 2 */
es_orig, /* es before any +proj related adjustment */
e, /* eccentricity */
ra, /* 1/A */
one_es, /* 1 - e^2 */
rone_es, /* 1/one_es */
lam0, phi0, /* central longitude, latitude */
x0, y0, /* easting and northing */
k0, /* general scaling factor */
to_meter, fr_meter, /* cartesian scaling */
vto_meter, vfr_meter; /* Vertical scaling. Internal unit [m] */
int datum_type; /* PJD_UNKNOWN/3PARAM/7PARAM/GRIDSHIFT/WGS84 */
T datum_params[7];
T from_greenwich; /* prime meridian offset (in radians) */
T long_wrap_center; /* 0.0 for -180 to 180, actually in radians*/
bool is_long_wrap_set;
// Initialize all variables to zero
pj_const_non_pod()
: over(0), geoc(0), is_latlong(0), is_geocent(0)
, a(0), a_orig(0), es(0), es_orig(0), e(0), ra(0)
, one_es(0), rone_es(0), lam0(0), phi0(0), x0(0), y0(0), k0(0)
, to_meter(0), fr_meter(0), vto_meter(0), vfr_meter(0)
, datum_type(PJD_UNKNOWN)
, from_greenwich(0), long_wrap_center(0), is_long_wrap_set(false)
{
datum_params[0] = 0;
datum_params[1] = 0;
datum_params[2] = 0;
datum_params[3] = 0;
datum_params[4] = 0;
datum_params[5] = 0;
datum_params[6] = 0;
}
};
template <typename T>
struct pj_const
: boost::mpl::if_c
<
boost::is_pod<T>::value,
pj_const_pod<T>,
pj_const_non_pod<T>
>::type
{};
// PROJ4 complex. Might be replaced with std::complex
template <typename T>
struct COMPLEX { T r, i; };
struct PJ_ELLPS
{
std::string id; /* ellipse keyword name */
std::string major; /* a= value */
std::string ell; /* elliptical parameter */
std::string name; /* comments */
};
struct PJ_DATUMS
{
std::string id; /* datum keyword */
std::string defn; /* ie. "to_wgs84=..." */
std::string ellipse_id; /* ie from ellipse table */
std::string comments; /* EPSG code, etc */
};
struct PJ_PRIME_MERIDIANS
{
std::string id; /* prime meridian keyword */
std::string defn; /* offset from greenwich in DMS format. */
};
struct PJ_UNITS
{
std::string id; /* units keyword */
std::string to_meter; /* multiply by value to get meters */
std::string name; /* comments */
};
template <typename T>
struct DERIVS
{
T x_l, x_p; /* derivatives of x for lambda-phi */
T y_l, y_p; /* derivatives of y for lambda-phi */
};
template <typename T>
struct FACTORS
{
DERIVS<T> der;
T h, k; /* meridinal, parallel scales */
T omega, thetap; /* angular distortion, theta prime */
T conv; /* convergence */
T s; /* areal scale factor */
T a, b; /* max-min scale error */
int code; /* info as to analytics, see following */
};
} // namespace detail
#endif // DOXYGEN_NO_DETAIL
/*!
\brief parameters, projection parameters
\details This structure initializes all projections
\ingroup projection
*/
template <typename T>
struct parameters : public detail::pj_const<T>
{
typedef T type;
std::string name;
std::vector<detail::pvalue<T> > params;
};
}}} // namespace boost::geometry::projections
#endif // BOOST_GEOMETRY_PROJECTIONS_IMPL_PROJECTS_HPP

View File

@@ -0,0 +1,38 @@
// Boost.Geometry
// Copyright (c) 2017-2018, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
#ifndef BOOST_GEOMETRY_PROJECTIONS_INVALID_POINT_HPP
#define BOOST_GEOMETRY_PROJECTIONS_INVALID_POINT_HPP
#include <cmath>
#include <boost/geometry/core/access.hpp>
namespace boost { namespace geometry { namespace projections
{
// Originally in pj_transform()
template <typename Point>
inline void set_invalid_point(Point & point)
{
geometry::set<0>(point, HUGE_VAL);
geometry::set<1>(point, HUGE_VAL);
}
template <typename Point>
inline bool is_invalid_point(Point const& point)
{
return geometry::get<0>(point) == HUGE_VAL;
}
}}} // namespace boost::geometry::projections
#endif // BOOST_GEOMETRY_PROJECTIONS_INVALID_POINT_HPP

View File

@@ -0,0 +1,501 @@
// Boost.Geometry
// Copyright (c) 2017-2018, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
#ifndef BOOST_GEOMETRY_SRS_PROJECTIONS_PAR4_HPP
#define BOOST_GEOMETRY_SRS_PROJECTIONS_PAR4_HPP
#include <boost/geometry/core/tag.hpp>
#include <boost/geometry/core/tags.hpp>
#include <boost/geometry/srs/sphere.hpp>
#include <boost/geometry/srs/spheroid.hpp>
#include <boost/mpl/assert.hpp>
#include <boost/mpl/if.hpp>
#include <boost/tuple/tuple.hpp>
#include <boost/type_traits/integral_constant.hpp>
#include <boost/type_traits/is_same.hpp>
#include <boost/type_traits/is_void.hpp>
namespace boost { namespace geometry { namespace srs { namespace par4
{
// proj
// defined in projections' implementation files
// ellps
struct MERIT {};
struct SGS85 {};
struct GRS80 {};
struct IAU76 {};
struct airy {};
struct APL4_9 {};
struct NWL9D {};
struct mod_airy {};
struct andrae {};
struct aust_SA {};
struct GRS67 {};
struct bessel {};
struct bess_nam {};
struct clrk66 {};
struct clrk80 {};
struct clrk80ign {};
struct CPM {};
struct delmbr {};
struct engelis {};
struct evrst30 {};
struct evrst48 {};
struct evrst56 {};
struct evrst69 {};
struct evrstSS {};
struct fschr60 {};
struct fschr60m {};
struct fschr68 {};
struct helmert {};
struct hough {};
struct intl {};
struct krass {};
struct kaula {};
struct lerch {};
struct mprts {};
struct new_intl {};
struct plessis {};
struct SEasia {};
struct walbeck {};
struct WGS60 {};
struct WGS66 {};
struct WGS72 {};
struct WGS84 {};
struct sphere {};
// datum
//struct WGS84 {}; // already defined above
struct GGRS87 {};
struct NAD83 {};
struct NAD27 {};
struct potsdam {};
struct carthage {};
struct hermannskogel {};
struct ire65 {};
struct nzgd49 {};
struct OSGB36 {};
template <typename P>
struct proj
{
typedef P type;
};
#ifndef DOXYGEN_NO_DETAIL
namespace detail
{
template
<
typename E,
typename Tag = typename geometry::tag<E>::type
>
struct ellps_impl
: private E // empty base optimization
{
typedef E type;
ellps_impl() : E() {}
explicit ellps_impl(E const& e) : E(e) {}
E const& model() const { return *this; }
};
template <typename E>
struct ellps_impl<E, void>
{
typedef E type;
};
} // namespace detail
#endif // DOXYGEN_NO_DETAIL
template<typename E>
struct ellps
: par4::detail::ellps_impl<E>
{
ellps() {}
explicit ellps(E const& e)
: par4::detail::ellps_impl<E>(e)
{}
};
template <typename D>
struct datum
{
typedef D type;
};
template <typename P>
struct o_proj
{
typedef P type;
};
struct guam {};
#ifndef DOXYGEN_NO_DETAIL
namespace detail
{
inline double b_from_a_rf(double a, double rf)
{
return a * (1.0 - 1.0 / rf);
}
template
<
typename Ellps,
typename Tag = typename geometry::tag<typename Ellps::type>::type
>
struct ellps_traits
{
typedef typename Ellps::type model_type;
static model_type model(Ellps const& e) { return e.model(); }
};
#define BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_ELLPS_A_B(NAME, A, B) \
template <> \
struct ellps_traits<ellps<par4::NAME>, void> \
{ \
typedef srs::spheroid<double> model_type; \
static model_type model(ellps<par4::NAME> const&) { return model_type(A, B); } \
};
#define BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_ELLPS_A_RF(NAME, A, RF) \
template <> \
struct ellps_traits<ellps<par4::NAME>, void> \
{ \
typedef srs::spheroid<double> model_type; \
static model_type model(ellps<par4::NAME> const&) { return model_type(A, b_from_a_rf(A, RF)); } \
};
#define BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_SPHERE(NAME, R) \
template <> \
struct ellps_traits<ellps<par4::NAME>, void> \
{ \
typedef srs::sphere<double> model_type; \
static model_type model(ellps<par4::NAME> const&) { return model_type(R); } \
};
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_ELLPS_A_RF(MERIT, 6378137.0, 298.257)
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_ELLPS_A_RF(SGS85, 6378136.0, 298.257)
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_ELLPS_A_RF(GRS80, 6378137.0, 298.257222101)
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_ELLPS_A_RF(IAU76, 6378140.0, 298.257)
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_ELLPS_A_B (airy, 6377563.396, 6356256.910)
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_ELLPS_A_RF(APL4_9, 6378137.0, 298.25)
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_ELLPS_A_RF(NWL9D, 6378145.0, 298.25)
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_ELLPS_A_B (mod_airy, 6377340.189, 6356034.446)
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_ELLPS_A_RF(andrae, 6377104.43, 300.0)
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_ELLPS_A_RF(aust_SA, 6378160.0, 298.25)
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_ELLPS_A_RF(GRS67, 6378160.0, 298.2471674270)
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_ELLPS_A_RF(bessel, 6377397.155, 299.1528128)
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_ELLPS_A_RF(bess_nam, 6377483.865, 299.1528128)
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_ELLPS_A_B (clrk66, 6378206.4, 6356583.8)
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_ELLPS_A_RF(clrk80, 6378249.145, 293.4663)
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_ELLPS_A_RF(clrk80ign, 6378249.2, 293.4660212936269)
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_ELLPS_A_RF(CPM, 6375738.7, 334.29)
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_ELLPS_A_RF(delmbr, 6376428.0, 311.5)
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_ELLPS_A_RF(engelis, 6378136.05, 298.2566)
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_ELLPS_A_RF(evrst30, 6377276.345, 300.8017)
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_ELLPS_A_RF(evrst48, 6377304.063, 300.8017)
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_ELLPS_A_RF(evrst56, 6377301.243, 300.8017)
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_ELLPS_A_RF(evrst69, 6377295.664, 300.8017)
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_ELLPS_A_RF(evrstSS, 6377298.556, 300.8017)
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_ELLPS_A_RF(fschr60, 6378166.0, 298.3)
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_ELLPS_A_RF(fschr60m, 6378155.0, 298.3)
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_ELLPS_A_RF(fschr68, 6378150.0, 298.3)
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_ELLPS_A_RF(helmert, 6378200.0, 298.3)
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_ELLPS_A_RF(hough, 6378270.0, 297.0)
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_ELLPS_A_RF(intl, 6378388.0, 297.0)
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_ELLPS_A_RF(krass, 6378245.0, 298.3)
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_ELLPS_A_RF(kaula, 6378163.0, 298.24)
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_ELLPS_A_RF(lerch, 6378139.0, 298.257)
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_ELLPS_A_RF(mprts, 6397300.0, 191.0)
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_ELLPS_A_B (new_intl, 6378157.5, 6356772.2)
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_ELLPS_A_B (plessis, 6376523.0, 6355863.0)
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_ELLPS_A_B (SEasia, 6378155.0, 6356773.3205)
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_ELLPS_A_B (walbeck, 6376896.0, 6355834.8467)
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_ELLPS_A_RF(WGS60, 6378165.0, 298.3)
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_ELLPS_A_RF(WGS66, 6378145.0, 298.25)
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_ELLPS_A_RF(WGS72, 6378135.0, 298.26)
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_ELLPS_A_RF(WGS84, 6378137.0, 298.257223563)
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_SPHERE (sphere, 6370997.0)
template <typename D>
struct datum_traits
{
typedef void ellps_type;
static std::string id() { return ""; }
static std::string definition() { return ""; }
};
#define BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_DATUM(NAME, ID, ELLPS, DEF) \
template <> \
struct datum_traits< datum<par4::NAME> > \
{ \
typedef par4::ellps<par4::ELLPS> ellps_type; \
static std::string id() { return ID; } \
static std::string definition() { return DEF; } \
};
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_DATUM(WGS84, "WGS84", WGS84, "towgs84=0,0,0")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_DATUM(GGRS87, "GGRS87", GRS80, "towgs84=-199.87,74.79,246.62")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_DATUM(NAD83, "NAD83", GRS80, "towgs84=0,0,0")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_DATUM(NAD27, "NAD27", clrk66, "nadgrids=@conus,@alaska,@ntv2_0.gsb,@ntv1_can.dat")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_DATUM(potsdam, "potsdam", bessel, "towgs84=598.1,73.7,418.2,0.202,0.045,-2.455,6.7")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_DATUM(carthage, "carthage", clrk80ign, "towgs84=-263.0,6.0,431.0")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_DATUM(hermannskogel, "hermannskogel", bessel, "towgs84=577.326,90.129,463.919,5.137,1.474,5.297,2.4232")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_DATUM(ire65, "ire65", mod_airy, "towgs84=482.530,-130.596,564.557,-1.042,-0.214,-0.631,8.15")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_DATUM(nzgd49, "nzgd49", intl, "towgs84=59.47,-5.04,187.44,0.47,-0.1,1.024,-4.5993")
BOOST_GEOMETRY_PROJECTIONS_DETAIL_REGISTER_DATUM(OSGB36, "OSGB36", airy, "towgs84=446.448,-125.157,542.060,0.1502,0.2470,0.8421,-20.4894")
template
<
typename Tuple,
template <typename> class IsSamePred,
int I = 0,
int N = boost::tuples::length<Tuple>::value
>
struct tuples_find_index_if
: boost::mpl::if_c
<
IsSamePred<typename boost::tuples::element<I, Tuple>::type>::value,
boost::integral_constant<int, I>,
typename tuples_find_index_if<Tuple, IsSamePred, I+1, N>::type
>::type
{};
template
<
typename Tuple,
template <typename> class IsSamePred,
int N
>
struct tuples_find_index_if<Tuple, IsSamePred, N, N>
: boost::integral_constant<int, N>
{};
template
<
typename Tuple,
template <typename> class IsSamePred,
int I = tuples_find_index_if<Tuple, IsSamePred>::value,
int N = boost::tuples::length<Tuple>::value
>
struct tuples_find_if
: boost::tuples::element<I, Tuple>
{};
template
<
typename Tuple,
template <typename> class IsSamePred,
int N
>
struct tuples_find_if<Tuple, IsSamePred, N, N>
{
typedef void type;
};
/*template <typename Param>
struct is_param
{
template <typename T, int D = 0>
struct is_same_impl : boost::false_type {};
template <int D>
struct is_same_impl<Param, D> : boost::true_type {};
template <typename T>
struct is_same : is_same_impl<T> {};
};
template <template <typename> class Param>
struct is_param_t
{
template <typename T>
struct is_same : boost::false_type {};
template <typename T>
struct is_same<Param<T> > : boost::true_type {};
};*/
// NOTE: The following metafunctions are implemented one for each parameter
// because mingw-gcc-4.1.2 is unable to compile a solution based on template
// template parameter and member struct template partial specialization
// (see above).
/*template <typename T>
struct is_proj : boost::false_type {};
template <typename T>
struct is_proj<proj<T> > : boost::true_type {};
template <typename T>
struct is_ellps : boost::false_type {};
template <typename T>
struct is_ellps<ellps<T> > : boost::true_type {};
template <typename T>
struct is_datum : boost::false_type {};
template <typename T>
struct is_datum<datum<T> > : boost::true_type {};
template <typename T>
struct is_o_proj : boost::false_type {};
template <typename T>
struct is_o_proj<o_proj<T> > : boost::true_type {};
template <typename T>
struct is_guam : boost::false_type {};
template <>
struct is_guam<guam> : boost::true_type {};*/
// NOTE: The following implementation seems to work as well.
// TEST
template <typename T, template <typename> class Param>
struct is_same_t : boost::false_type {};
template <typename T, template <typename> class Param>
struct is_same_t<Param<T>, Param> : boost::true_type {};
template <typename Param>
struct is_param
{
template <typename T>
struct pred : boost::is_same<T, Param> {};
};
template <template <typename> class Param>
struct is_param_t
{
template <typename T>
struct pred : is_same_t<T, Param> {};
};
// pick proj static name
template <typename Tuple>
struct pick_proj_tag
{
typedef typename tuples_find_if
<
Tuple,
// is_proj
is_param_t<proj>::pred
>::type proj_type;
static const bool is_non_void = ! boost::is_void<proj_type>::value;
BOOST_MPL_ASSERT_MSG((is_non_void), PROJECTION_NOT_NAMED, (Tuple));
typedef typename proj_type::type type;
};
template <typename Ellps, typename Datum, int EllpsIndex>
struct pick_ellps_impl
{
typedef Ellps type;
typedef typename ellps_traits<Ellps>::model_type model_type;
template <typename Tuple>
static model_type model(Tuple const& tup)
{
return ellps_traits<Ellps>::model(boost::get<EllpsIndex>(tup));
}
};
template <typename Ellps, int EllpsIndex>
struct pick_ellps_impl<Ellps, void, EllpsIndex>
{
typedef Ellps type;
typedef typename ellps_traits<Ellps>::model_type model_type;
template <typename Tuple>
static model_type model(Tuple const& tup)
{
return ellps_traits<Ellps>::model(boost::get<EllpsIndex>(tup));
}
};
template <typename Datum, int EllpsIndex>
struct pick_ellps_impl<void, Datum, EllpsIndex>
{
typedef typename datum_traits<Datum>::ellps_type type;
static const bool is_datum_known = ! boost::is_void<type>::value;
BOOST_MPL_ASSERT_MSG((is_datum_known), UNKNOWN_DATUM, (types<Datum>));
typedef typename ellps_traits<type>::model_type model_type;
template <typename Tuple>
static model_type model(Tuple const& )
{
return ellps_traits<type>::model(type());
}
};
template <int EllpsIndex>
struct pick_ellps_impl<void, void, EllpsIndex>
{
// default ellipsoid
typedef ellps<WGS84> type;
typedef typename ellps_traits<type>::model_type model_type;
template <typename Tuple>
static model_type model(Tuple const& )
{
return ellps_traits<type>::model(type());
}
};
// Pick spheroid/sphere model from ellps or datum
// mimic pj_init() calling pj_datum_set() and pj_ell_set()
template <typename Tuple>
struct pick_ellps
: pick_ellps_impl
<
typename tuples_find_if<Tuple, /*is_ellps*/is_param_t<ellps>::pred>::type,
typename tuples_find_if<Tuple, /*is_datum*/is_param_t<datum>::pred>::type,
tuples_find_index_if<Tuple, /*is_ellps*/is_param_t<ellps>::pred>::value
>
{};
template <typename Tuple>
struct pick_o_proj_tag
{
typedef typename tuples_find_if
<
Tuple,
//is_o_proj
is_param_t<o_proj>::pred
>::type proj_type;
static const bool is_non_void = ! boost::is_void<proj_type>::value;
BOOST_MPL_ASSERT_MSG((is_non_void), PROJECTION_NOT_NAMED, (Tuple));
typedef typename proj_type::type type;
};
} // namespace detail
#endif // DOXYGEN_NO_DETAIL
}}}} // namespace boost::geometry::srs::par4
#endif // BOOST_GEOMETRY_SRS_PROJECTIONS_PAR4_HPP

View File

@@ -0,0 +1,349 @@
#ifndef BOOST_GEOMETRY_PROJECTIONS_AEA_HPP
#define BOOST_GEOMETRY_PROJECTIONS_AEA_HPP
// Boost.Geometry - extensions-gis-projections (based on PROJ4)
// This file is automatically generated. DO NOT EDIT.
// Copyright (c) 2008-2015 Barend Gehrels, Amsterdam, the Netherlands.
// This file was modified by Oracle on 2017.
// Modifications copyright (c) 2017, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle.
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
// This file is converted from PROJ4, http://trac.osgeo.org/proj
// PROJ4 is originally written by Gerald Evenden (then of the USGS)
// PROJ4 is maintained by Frank Warmerdam
// PROJ4 is converted to Boost.Geometry by Barend Gehrels
// Last updated version of proj: 4.9.1
// Original copyright notice:
// Purpose: Implementation of the aea (Albers Equal Area) projection.
// Author: Gerald Evenden
// Copyright (c) 1995, Gerald Evenden
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the "Software"),
// to deal in the Software without restriction, including without limitation
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
// and/or sell copies of the Software, and to permit persons to whom the
// Software is furnished to do so, subject to the following conditions:
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Software.
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.
#include <boost/core/ignore_unused.hpp>
#include <boost/geometry/util/math.hpp>
#include <boost/math/special_functions/hypot.hpp>
#include <boost/geometry/srs/projections/impl/base_static.hpp>
#include <boost/geometry/srs/projections/impl/base_dynamic.hpp>
#include <boost/geometry/srs/projections/impl/projects.hpp>
#include <boost/geometry/srs/projections/impl/factory_entry.hpp>
#include <boost/geometry/srs/projections/impl/pj_mlfn.hpp>
#include <boost/geometry/srs/projections/impl/pj_msfn.hpp>
#include <boost/geometry/srs/projections/impl/pj_qsfn.hpp>
namespace boost { namespace geometry
{
namespace srs { namespace par4
{
struct aea {};
struct leac {};
}} //namespace srs::par4
namespace projections
{
#ifndef DOXYGEN_NO_DETAIL
namespace detail { namespace aea
{
static const double EPS10 = 1.e-10;
static const double TOL7 = 1.e-7;
static const double EPSILON = 1.0e-7;
static const double TOL = 1.0e-10;
static const int N_ITER = 15;
template <typename T>
struct par_aea
{
T ec;
T n;
T c;
T dd;
T n2;
T rho0;
T phi1;
T phi2;
T en[EN_SIZE];
int ellips;
};
/* determine latitude angle phi-1 */
template <typename T>
inline T phi1_(T const& qs, T const& Te, T const& Tone_es)
{
int i;
T Phi, sinpi, cospi, con, com, dphi;
Phi = asin (.5 * qs);
if (Te < EPSILON)
return( Phi );
i = N_ITER;
do {
sinpi = sin (Phi);
cospi = cos (Phi);
con = Te * sinpi;
com = 1. - con * con;
dphi = .5 * com * com / cospi * (qs / Tone_es -
sinpi / com + .5 / Te * log ((1. - con) /
(1. + con)));
Phi += dphi;
} while (fabs(dphi) > TOL && --i);
return( i ? Phi : HUGE_VAL );
}
// template class, using CRTP to implement forward/inverse
template <typename CalculationType, typename Parameters>
struct base_aea_ellipsoid : public base_t_fi<base_aea_ellipsoid<CalculationType, Parameters>,
CalculationType, Parameters>
{
typedef CalculationType geographic_type;
typedef CalculationType cartesian_type;
par_aea<CalculationType> m_proj_parm;
inline base_aea_ellipsoid(const Parameters& par)
: base_t_fi<base_aea_ellipsoid<CalculationType, Parameters>,
CalculationType, Parameters>(*this, par) {}
// FORWARD(e_forward) ellipsoid & spheroid
// Project coordinates from geographic (lon, lat) to cartesian (x, y)
inline void fwd(geographic_type& lp_lon, geographic_type& lp_lat, cartesian_type& xy_x, cartesian_type& xy_y) const
{
CalculationType rho = 0.0;
if ((rho = this->m_proj_parm.c - (this->m_proj_parm.ellips ? this->m_proj_parm.n * pj_qsfn(sin(lp_lat),
this->m_par.e, this->m_par.one_es) : this->m_proj_parm.n2 * sin(lp_lat))) < 0.)
BOOST_THROW_EXCEPTION( projection_exception(-20) );
rho = this->m_proj_parm.dd * sqrt(rho);
xy_x = rho * sin( lp_lon *= this->m_proj_parm.n );
xy_y = this->m_proj_parm.rho0 - rho * cos(lp_lon);
}
// INVERSE(e_inverse) ellipsoid & spheroid
// Project coordinates from cartesian (x, y) to geographic (lon, lat)
inline void inv(cartesian_type& xy_x, cartesian_type& xy_y, geographic_type& lp_lon, geographic_type& lp_lat) const
{
static const CalculationType HALFPI = detail::HALFPI<CalculationType>();
CalculationType rho = 0.0;
if( (rho = boost::math::hypot(xy_x, xy_y = this->m_proj_parm.rho0 - xy_y)) != 0.0 ) {
if (this->m_proj_parm.n < 0.) {
rho = -rho;
xy_x = -xy_x;
xy_y = -xy_y;
}
lp_lat = rho / this->m_proj_parm.dd;
if (this->m_proj_parm.ellips) {
lp_lat = (this->m_proj_parm.c - lp_lat * lp_lat) / this->m_proj_parm.n;
if (fabs(this->m_proj_parm.ec - fabs(lp_lat)) > TOL7) {
if ((lp_lat = phi1_(lp_lat, this->m_par.e, this->m_par.one_es)) == HUGE_VAL)
BOOST_THROW_EXCEPTION( projection_exception(-20) );
} else
lp_lat = lp_lat < 0. ? -HALFPI : HALFPI;
} else if (fabs(lp_lat = (this->m_proj_parm.c - lp_lat * lp_lat) / this->m_proj_parm.n2) <= 1.)
lp_lat = asin(lp_lat);
else
lp_lat = lp_lat < 0. ? -HALFPI : HALFPI;
lp_lon = atan2(xy_x, xy_y) / this->m_proj_parm.n;
} else {
lp_lon = 0.;
lp_lat = this->m_proj_parm.n > 0. ? HALFPI : - HALFPI;
}
}
static inline std::string get_name()
{
return "aea_ellipsoid";
}
};
template <typename Parameters, typename T>
inline void setup(Parameters& par, par_aea<T>& proj_parm)
{
T cosphi, sinphi;
int secant;
if (fabs(proj_parm.phi1 + proj_parm.phi2) < EPS10)
BOOST_THROW_EXCEPTION( projection_exception(-21) );
proj_parm.n = sinphi = sin(proj_parm.phi1);
cosphi = cos(proj_parm.phi1);
secant = fabs(proj_parm.phi1 - proj_parm.phi2) >= EPS10;
if( (proj_parm.ellips = (par.es > 0.))) {
T ml1, m1;
if (!pj_enfn(par.es, proj_parm.en))
BOOST_THROW_EXCEPTION( projection_exception(0) );
m1 = pj_msfn(sinphi, cosphi, par.es);
ml1 = pj_qsfn(sinphi, par.e, par.one_es);
if (secant) { /* secant cone */
T ml2, m2;
sinphi = sin(proj_parm.phi2);
cosphi = cos(proj_parm.phi2);
m2 = pj_msfn(sinphi, cosphi, par.es);
ml2 = pj_qsfn(sinphi, par.e, par.one_es);
proj_parm.n = (m1 * m1 - m2 * m2) / (ml2 - ml1);
}
proj_parm.ec = 1. - .5 * par.one_es * log((1. - par.e) /
(1. + par.e)) / par.e;
proj_parm.c = m1 * m1 + proj_parm.n * ml1;
proj_parm.dd = 1. / proj_parm.n;
proj_parm.rho0 = proj_parm.dd * sqrt(proj_parm.c - proj_parm.n * pj_qsfn(sin(par.phi0),
par.e, par.one_es));
} else {
if (secant) proj_parm.n = .5 * (proj_parm.n + sin(proj_parm.phi2));
proj_parm.n2 = proj_parm.n + proj_parm.n;
proj_parm.c = cosphi * cosphi + proj_parm.n2 * sinphi;
proj_parm.dd = 1. / proj_parm.n;
proj_parm.rho0 = proj_parm.dd * sqrt(proj_parm.c - proj_parm.n2 * sin(par.phi0));
}
}
// Albers Equal Area
template <typename Parameters, typename T>
inline void setup_aea(Parameters& par, par_aea<T>& proj_parm)
{
proj_parm.phi1 = pj_param(par.params, "rlat_1").f;
proj_parm.phi2 = pj_param(par.params, "rlat_2").f;
setup(par, proj_parm);
}
// Lambert Equal Area Conic
template <typename Parameters, typename T>
inline void setup_leac(Parameters& par, par_aea<T>& proj_parm)
{
static const T HALFPI = detail::HALFPI<T>();
proj_parm.phi2 = pj_param(par.params, "rlat_1").f;
proj_parm.phi1 = pj_param(par.params, "bsouth").i ? -HALFPI : HALFPI;
setup(par, proj_parm);
}
}} // namespace detail::aea
#endif // doxygen
/*!
\brief Albers Equal Area projection
\ingroup projections
\tparam Geographic latlong point type
\tparam Cartesian xy point type
\tparam Parameters parameter type
\par Projection characteristics
- Conic
- Spheroid
- Ellipsoid
\par Projection parameters
- lat_1: Latitude of first standard parallel (degrees)
- lat_2: Latitude of second standard parallel (degrees)
\par Example
\image html ex_aea.gif
*/
template <typename CalculationType, typename Parameters>
struct aea_ellipsoid : public detail::aea::base_aea_ellipsoid<CalculationType, Parameters>
{
inline aea_ellipsoid(const Parameters& par) : detail::aea::base_aea_ellipsoid<CalculationType, Parameters>(par)
{
detail::aea::setup_aea(this->m_par, this->m_proj_parm);
}
};
/*!
\brief Lambert Equal Area Conic projection
\ingroup projections
\tparam Geographic latlong point type
\tparam Cartesian xy point type
\tparam Parameters parameter type
\par Projection characteristics
- Conic
- Spheroid
- Ellipsoid
\par Projection parameters
- lat_1: Latitude of first standard parallel (degrees)
- south: Denotes southern hemisphere UTM zone (boolean)
\par Example
\image html ex_leac.gif
*/
template <typename CalculationType, typename Parameters>
struct leac_ellipsoid : public detail::aea::base_aea_ellipsoid<CalculationType, Parameters>
{
inline leac_ellipsoid(const Parameters& par) : detail::aea::base_aea_ellipsoid<CalculationType, Parameters>(par)
{
detail::aea::setup_leac(this->m_par, this->m_proj_parm);
}
};
#ifndef DOXYGEN_NO_DETAIL
namespace detail
{
// Static projection
BOOST_GEOMETRY_PROJECTIONS_DETAIL_STATIC_PROJECTION(srs::par4::aea, aea_ellipsoid, aea_ellipsoid)
BOOST_GEOMETRY_PROJECTIONS_DETAIL_STATIC_PROJECTION(srs::par4::leac, leac_ellipsoid, leac_ellipsoid)
// Factory entry(s)
template <typename CalculationType, typename Parameters>
class aea_entry : public detail::factory_entry<CalculationType, Parameters>
{
public :
virtual base_v<CalculationType, Parameters>* create_new(const Parameters& par) const
{
return new base_v_fi<aea_ellipsoid<CalculationType, Parameters>, CalculationType, Parameters>(par);
}
};
template <typename CalculationType, typename Parameters>
class leac_entry : public detail::factory_entry<CalculationType, Parameters>
{
public :
virtual base_v<CalculationType, Parameters>* create_new(const Parameters& par) const
{
return new base_v_fi<leac_ellipsoid<CalculationType, Parameters>, CalculationType, Parameters>(par);
}
};
template <typename CalculationType, typename Parameters>
inline void aea_init(detail::base_factory<CalculationType, Parameters>& factory)
{
factory.add_to_factory("aea", new aea_entry<CalculationType, Parameters>);
factory.add_to_factory("leac", new leac_entry<CalculationType, Parameters>);
}
} // namespace detail
#endif // doxygen
} // namespace projections
}} // namespace boost::geometry
#endif // BOOST_GEOMETRY_PROJECTIONS_AEA_HPP

View File

@@ -0,0 +1,654 @@
#ifndef BOOST_GEOMETRY_PROJECTIONS_AEQD_HPP
#define BOOST_GEOMETRY_PROJECTIONS_AEQD_HPP
// Boost.Geometry - extensions-gis-projections (based on PROJ4)
// This file is automatically generated. DO NOT EDIT.
// Copyright (c) 2008-2015 Barend Gehrels, Amsterdam, the Netherlands.
// This file was modified by Oracle on 2017, 2018.
// Modifications copyright (c) 2017-2018, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle.
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
// This file is converted from PROJ4, http://trac.osgeo.org/proj
// PROJ4 is originally written by Gerald Evenden (then of the USGS)
// PROJ4 is maintained by Frank Warmerdam
// PROJ4 is converted to Boost.Geometry by Barend Gehrels
// Last updated version of proj: 4.9.1
// Original copyright notice:
// Purpose: Implementation of the aeqd (Azimuthal Equidistant) projection.
// Author: Gerald Evenden
// Copyright (c) 1995, Gerald Evenden
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the "Software"),
// to deal in the Software without restriction, including without limitation
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
// and/or sell copies of the Software, and to permit persons to whom the
// Software is furnished to do so, subject to the following conditions:
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Software.
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.
#include <boost/config.hpp>
#include <boost/geometry/util/math.hpp>
#include <boost/math/special_functions/hypot.hpp>
#include <boost/geometry/srs/projections/impl/base_static.hpp>
#include <boost/geometry/srs/projections/impl/base_dynamic.hpp>
#include <boost/geometry/srs/projections/impl/projects.hpp>
#include <boost/geometry/srs/projections/impl/factory_entry.hpp>
#include <boost/geometry/srs/projections/impl/aasincos.hpp>
#include <boost/geometry/srs/projections/impl/pj_mlfn.hpp>
#include <boost/geometry/srs/projections/par4.hpp>
#include <boost/type_traits/is_same.hpp>
namespace boost { namespace geometry
{
namespace srs { namespace par4
{
struct aeqd {};
//struct aeqd_guam {};
}} //namespace srs::par4
namespace projections
{
#ifndef DOXYGEN_NO_DETAIL
namespace detail { namespace aeqd
{
static const double EPS10 = 1.e-10;
static const double TOL = 1.e-14;
static const int N_POLE = 0;
static const int S_POLE = 1;
static const int EQUIT = 2;
static const int OBLIQ = 3;
template <typename T>
struct par_aeqd
{
T sinph0;
T cosph0;
T en[EN_SIZE];
T M1;
T N1;
T Mp;
T He;
T G;
int mode;
};
template <typename T, typename Par, typename ProjParm>
inline void e_forward(T& lp_lon, T& lp_lat, T& xy_x, T& xy_y, Par const& par, ProjParm const& proj_parm)
{
T coslam, cosphi, sinphi, rho, s, H, H2, c, Az, t, ct, st, cA, sA;
coslam = cos(lp_lon);
cosphi = cos(lp_lat);
sinphi = sin(lp_lat);
switch (proj_parm.mode) {
case N_POLE:
coslam = - coslam;
BOOST_FALLTHROUGH;
case S_POLE:
xy_x = (rho = fabs(proj_parm.Mp - pj_mlfn(lp_lat, sinphi, cosphi, proj_parm.en))) *
sin(lp_lon);
xy_y = rho * coslam;
break;
case EQUIT:
case OBLIQ:
if (fabs(lp_lon) < EPS10 && fabs(lp_lat - par.phi0) < EPS10) {
xy_x = xy_y = 0.;
break;
}
t = atan2(par.one_es * sinphi + par.es * proj_parm.N1 * proj_parm.sinph0 *
sqrt(1. - par.es * sinphi * sinphi), cosphi);
ct = cos(t); st = sin(t);
Az = atan2(sin(lp_lon) * ct, proj_parm.cosph0 * st - proj_parm.sinph0 * coslam * ct);
cA = cos(Az); sA = sin(Az);
s = aasin(fabs(sA) < TOL ?
(proj_parm.cosph0 * st - proj_parm.sinph0 * coslam * ct) / cA :
sin(lp_lon) * ct / sA );
H = proj_parm.He * cA;
H2 = H * H;
c = proj_parm.N1 * s * (1. + s * s * (- H2 * (1. - H2)/6. +
s * ( proj_parm.G * H * (1. - 2. * H2 * H2) / 8. +
s * ((H2 * (4. - 7. * H2) - 3. * proj_parm.G * proj_parm.G * (1. - 7. * H2)) /
120. - s * proj_parm.G * H / 48.))));
xy_x = c * sA;
xy_y = c * cA;
break;
}
}
template <typename T, typename Par, typename ProjParm>
inline void e_inverse(T& xy_x, T& xy_y, T& lp_lon, T& lp_lat, Par const& par, ProjParm const& proj_parm)
{
static const T HALFPI = detail::HALFPI<T>();
T c, Az, cosAz, A, B, D, E, F, psi, t;
if ((c = boost::math::hypot(xy_x, xy_y)) < EPS10) {
lp_lat = par.phi0;
lp_lon = 0.;
return;
}
if (proj_parm.mode == OBLIQ || proj_parm.mode == EQUIT) {
cosAz = cos(Az = atan2(xy_x, xy_y));
t = proj_parm.cosph0 * cosAz;
B = par.es * t / par.one_es;
A = - B * t;
B *= 3. * (1. - A) * proj_parm.sinph0;
D = c / proj_parm.N1;
E = D * (1. - D * D * (A * (1. + A) / 6. + B * (1. + 3.*A) * D / 24.));
F = 1. - E * E * (A / 2. + B * E / 6.);
psi = aasin(proj_parm.sinph0 * cos(E) + t * sin(E));
lp_lon = aasin(sin(Az) * sin(E) / cos(psi));
if ((t = fabs(psi)) < EPS10)
lp_lat = 0.;
else if (fabs(t - HALFPI) < 0.)
lp_lat = HALFPI;
else
lp_lat = atan((1. - par.es * F * proj_parm.sinph0 / sin(psi)) * tan(psi) /
par.one_es);
} else { /* Polar */
lp_lat = pj_inv_mlfn(proj_parm.mode == N_POLE ? proj_parm.Mp - c : proj_parm.Mp + c,
par.es, proj_parm.en);
lp_lon = atan2(xy_x, proj_parm.mode == N_POLE ? -xy_y : xy_y);
}
}
template <typename T, typename Par, typename ProjParm>
inline void e_guam_fwd(T& lp_lon, T& lp_lat, T& xy_x, T& xy_y, Par const& par, ProjParm const& proj_parm)
{
T cosphi, sinphi, t;
cosphi = cos(lp_lat);
sinphi = sin(lp_lat);
t = 1. / sqrt(1. - par.es * sinphi * sinphi);
xy_x = lp_lon * cosphi * t;
xy_y = pj_mlfn(lp_lat, sinphi, cosphi, proj_parm.en) - proj_parm.M1 +
.5 * lp_lon * lp_lon * cosphi * sinphi * t;
}
template <typename T, typename Par, typename ProjParm>
inline void e_guam_inv(T& xy_x, T& xy_y, T& lp_lon, T& lp_lat, Par const& par, ProjParm const& proj_parm)
{
T x2, t;
int i;
x2 = 0.5 * xy_x * xy_x;
lp_lat = par.phi0;
for (i = 0; i < 3; ++i) {
t = par.e * sin(lp_lat);
lp_lat = pj_inv_mlfn(proj_parm.M1 + xy_y -
x2 * tan(lp_lat) * (t = sqrt(1. - t * t)), par.es, proj_parm.en);
}
lp_lon = xy_x * t / cos(lp_lat);
}
template <typename T, typename Par, typename ProjParm>
inline void s_forward(T& lp_lon, T& lp_lat, T& xy_x, T& xy_y, Par const& /*par*/, ProjParm const& proj_parm)
{
static const T HALFPI = detail::HALFPI<T>();
T coslam, cosphi, sinphi;
sinphi = sin(lp_lat);
cosphi = cos(lp_lat);
coslam = cos(lp_lon);
switch (proj_parm.mode) {
case EQUIT:
xy_y = cosphi * coslam;
goto oblcon;
case OBLIQ:
xy_y = proj_parm.sinph0 * sinphi + proj_parm.cosph0 * cosphi * coslam;
oblcon:
if (fabs(fabs(xy_y) - 1.) < TOL)
if (xy_y < 0.)
BOOST_THROW_EXCEPTION( projection_exception(-20) );
else
xy_x = xy_y = 0.;
else {
xy_y = acos(xy_y);
xy_y /= sin(xy_y);
xy_x = xy_y * cosphi * sin(lp_lon);
xy_y *= (proj_parm.mode == EQUIT) ? sinphi :
proj_parm.cosph0 * sinphi - proj_parm.sinph0 * cosphi * coslam;
}
break;
case N_POLE:
lp_lat = -lp_lat;
coslam = -coslam;
BOOST_FALLTHROUGH;
case S_POLE:
if (fabs(lp_lat - HALFPI) < EPS10)
BOOST_THROW_EXCEPTION( projection_exception(-20) );
xy_x = (xy_y = (HALFPI + lp_lat)) * sin(lp_lon);
xy_y *= coslam;
break;
}
}
template <typename T, typename Par, typename ProjParm>
inline void s_inverse(T& xy_x, T& xy_y, T& lp_lon, T& lp_lat, Par const& par, ProjParm const& proj_parm)
{
static const T ONEPI = detail::ONEPI<T>();
static const T HALFPI = detail::HALFPI<T>();
T cosc, c_rh, sinc;
if ((c_rh = boost::math::hypot(xy_x, xy_y)) > ONEPI) {
if (c_rh - EPS10 > ONEPI)
BOOST_THROW_EXCEPTION( projection_exception(-20) );
c_rh = ONEPI;
} else if (c_rh < EPS10) {
lp_lat = par.phi0;
lp_lon = 0.;
return;
}
if (proj_parm.mode == OBLIQ || proj_parm.mode == EQUIT) {
sinc = sin(c_rh);
cosc = cos(c_rh);
if (proj_parm.mode == EQUIT) {
lp_lat = aasin(xy_y * sinc / c_rh);
xy_x *= sinc;
xy_y = cosc * c_rh;
} else {
lp_lat = aasin(cosc * proj_parm.sinph0 + xy_y * sinc * proj_parm.cosph0 /
c_rh);
xy_y = (cosc - proj_parm.sinph0 * sin(lp_lat)) * c_rh;
xy_x *= sinc * proj_parm.cosph0;
}
lp_lon = atan2(xy_x, xy_y);
} else if (proj_parm.mode == N_POLE) {
lp_lat = HALFPI - c_rh;
lp_lon = atan2(xy_x, -xy_y);
} else {
lp_lat = c_rh - HALFPI;
lp_lon = atan2(xy_x, xy_y);
}
}
// Azimuthal Equidistant
template <typename Parameters, typename T>
inline void setup_aeqd(Parameters& par, par_aeqd<T>& proj_parm, bool is_sphere, bool is_guam)
{
static const T HALFPI = detail::HALFPI<T>();
par.phi0 = pj_param(par.params, "rlat_0").f;
if (fabs(fabs(par.phi0) - HALFPI) < EPS10) {
proj_parm.mode = par.phi0 < 0. ? S_POLE : N_POLE;
proj_parm.sinph0 = par.phi0 < 0. ? -1. : 1.;
proj_parm.cosph0 = 0.;
} else if (fabs(par.phi0) < EPS10) {
proj_parm.mode = EQUIT;
proj_parm.sinph0 = 0.;
proj_parm.cosph0 = 1.;
} else {
proj_parm.mode = OBLIQ;
proj_parm.sinph0 = sin(par.phi0);
proj_parm.cosph0 = cos(par.phi0);
}
if (is_sphere) {
} else {
if (!pj_enfn(par.es, proj_parm.en))
BOOST_THROW_EXCEPTION( projection_exception(0) );
if (is_guam) {
proj_parm.M1 = pj_mlfn(par.phi0, proj_parm.sinph0, proj_parm.cosph0, proj_parm.en);
} else {
switch (proj_parm.mode) {
case N_POLE:
proj_parm.Mp = pj_mlfn<T>(HALFPI, 1., 0., proj_parm.en);
break;
case S_POLE:
proj_parm.Mp = pj_mlfn<T>(-HALFPI, -1., 0., proj_parm.en);
break;
case EQUIT:
case OBLIQ:
proj_parm.N1 = 1. / sqrt(1. - par.es * proj_parm.sinph0 * proj_parm.sinph0);
proj_parm.G = proj_parm.sinph0 * (proj_parm.He = par.e / sqrt(par.one_es));
proj_parm.He *= proj_parm.cosph0;
break;
}
}
}
}
// template class, using CRTP to implement forward/inverse
template <typename CalculationType, typename Parameters>
struct base_aeqd_e : public base_t_fi<base_aeqd_e<CalculationType, Parameters>,
CalculationType, Parameters>
{
typedef CalculationType geographic_type;
typedef CalculationType cartesian_type;
par_aeqd<CalculationType> m_proj_parm;
inline base_aeqd_e(const Parameters& par)
: base_t_fi<base_aeqd_e<CalculationType, Parameters>,
CalculationType, Parameters>(*this, par) {}
// FORWARD(e_forward) elliptical
// Project coordinates from geographic (lon, lat) to cartesian (x, y)
inline void fwd(geographic_type& lp_lon, geographic_type& lp_lat, cartesian_type& xy_x, cartesian_type& xy_y) const
{
e_forward(lp_lon, lp_lat, xy_x, xy_y, this->m_par, this->m_proj_parm);
}
// INVERSE(e_inverse) elliptical
// Project coordinates from cartesian (x, y) to geographic (lon, lat)
inline void inv(cartesian_type& xy_x, cartesian_type& xy_y, geographic_type& lp_lon, geographic_type& lp_lat) const
{
e_inverse(xy_x, xy_y, lp_lon, lp_lat, this->m_par, this->m_proj_parm);
}
static inline std::string get_name()
{
return "aeqd_e";
}
};
// template class, using CRTP to implement forward/inverse
template <typename CalculationType, typename Parameters>
struct base_aeqd_e_guam : public base_t_fi<base_aeqd_e_guam<CalculationType, Parameters>,
CalculationType, Parameters>
{
typedef CalculationType geographic_type;
typedef CalculationType cartesian_type;
par_aeqd<CalculationType> m_proj_parm;
inline base_aeqd_e_guam(const Parameters& par)
: base_t_fi<base_aeqd_e_guam<CalculationType, Parameters>,
CalculationType, Parameters>(*this, par) {}
// FORWARD(e_guam_fwd) Guam elliptical
// Project coordinates from geographic (lon, lat) to cartesian (x, y)
inline void fwd(geographic_type& lp_lon, geographic_type& lp_lat, cartesian_type& xy_x, cartesian_type& xy_y) const
{
e_guam_fwd(lp_lon, lp_lat, xy_x, xy_y, this->m_par, this->m_proj_parm);
}
// INVERSE(e_guam_inv) Guam elliptical
// Project coordinates from cartesian (x, y) to geographic (lon, lat)
inline void inv(cartesian_type& xy_x, cartesian_type& xy_y, geographic_type& lp_lon, geographic_type& lp_lat) const
{
e_guam_inv(xy_x, xy_y, lp_lon, lp_lat, this->m_par, this->m_proj_parm);
}
static inline std::string get_name()
{
return "aeqd_e_guam";
}
};
// template class, using CRTP to implement forward/inverse
template <typename BGParameters, typename CalculationType, typename Parameters>
struct base_aeqd_e_static : public base_t_fi<base_aeqd_e_static<BGParameters, CalculationType, Parameters>,
CalculationType, Parameters>
{
typedef CalculationType geographic_type;
typedef CalculationType cartesian_type;
par_aeqd<CalculationType> m_proj_parm;
static const bool is_guam = ! boost::is_same
<
typename srs::par4::detail::tuples_find_if
<
BGParameters,
//srs::par4::detail::is_guam
srs::par4::detail::is_param<srs::par4::guam>::pred
>::type,
void
>::value;
inline base_aeqd_e_static(const Parameters& par)
: base_t_fi<base_aeqd_e_static<BGParameters, CalculationType, Parameters>,
CalculationType, Parameters>(*this, par)
{}
// FORWARD(e_forward or e_guam_fwd) elliptical
// Project coordinates from geographic (lon, lat) to cartesian (x, y)
inline void fwd(geographic_type& lp_lon, geographic_type& lp_lat, cartesian_type& xy_x, cartesian_type& xy_y) const
{
if (is_guam)
e_guam_fwd(lp_lon, lp_lat, xy_x, xy_y, this->m_par, this->m_proj_parm);
else
e_forward(lp_lon, lp_lat, xy_x, xy_y, this->m_par, this->m_proj_parm);
}
// INVERSE(e_inverse or e_guam_inv) elliptical
// Project coordinates from cartesian (x, y) to geographic (lon, lat)
inline void inv(cartesian_type& xy_x, cartesian_type& xy_y, geographic_type& lp_lon, geographic_type& lp_lat) const
{
if (is_guam)
e_guam_inv(xy_x, xy_y, lp_lon, lp_lat, this->m_par, this->m_proj_parm);
else
e_inverse(xy_x, xy_y, lp_lon, lp_lat, this->m_par, this->m_proj_parm);
}
static inline std::string get_name()
{
return "aeqd_e_static";
}
};
// template class, using CRTP to implement forward/inverse
template <typename CalculationType, typename Parameters>
struct base_aeqd_s : public base_t_fi<base_aeqd_s<CalculationType, Parameters>,
CalculationType, Parameters>
{
typedef CalculationType geographic_type;
typedef CalculationType cartesian_type;
par_aeqd<CalculationType> m_proj_parm;
inline base_aeqd_s(const Parameters& par)
: base_t_fi<base_aeqd_s<CalculationType, Parameters>,
CalculationType, Parameters>(*this, par) {}
// FORWARD(s_forward) spherical
// Project coordinates from geographic (lon, lat) to cartesian (x, y)
inline void fwd(geographic_type& lp_lon, geographic_type& lp_lat, cartesian_type& xy_x, cartesian_type& xy_y) const
{
s_forward(lp_lon, lp_lat, xy_x, xy_y, this->m_par, this->m_proj_parm);
}
// INVERSE(s_inverse) spherical
// Project coordinates from cartesian (x, y) to geographic (lon, lat)
inline void inv(cartesian_type& xy_x, cartesian_type& xy_y, geographic_type& lp_lon, geographic_type& lp_lat) const
{
s_inverse(xy_x, xy_y, lp_lon, lp_lat, this->m_par, this->m_proj_parm);
}
static inline std::string get_name()
{
return "aeqd_s";
}
};
}} // namespace detail::aeqd
#endif // doxygen
/*!
\brief Azimuthal Equidistant projection
\ingroup projections
\tparam Geographic latlong point type
\tparam Cartesian xy point type
\tparam Parameters parameter type
\par Projection characteristics
- Azimuthal
- Spheroid
- Ellipsoid
\par Projection parameters
- lat_0: Latitude of origin (degrees)
- guam (boolean)
\par Example
\image html ex_aeqd.gif
*/
template <typename CalculationType, typename Parameters>
struct aeqd_e : public detail::aeqd::base_aeqd_e<CalculationType, Parameters>
{
inline aeqd_e(const Parameters& par) : detail::aeqd::base_aeqd_e<CalculationType, Parameters>(par)
{
detail::aeqd::setup_aeqd(this->m_par, this->m_proj_parm, false, false);
}
};
/*!
\brief Azimuthal Equidistant projection
\ingroup projections
\tparam Geographic latlong point type
\tparam Cartesian xy point type
\tparam Parameters parameter type
\par Projection characteristics
- Azimuthal
- Spheroid
- Ellipsoid
\par Projection parameters
- lat_0: Latitude of origin (degrees)
- guam (boolean)
\par Example
\image html ex_aeqd.gif
*/
template <typename CalculationType, typename Parameters>
struct aeqd_e_guam : public detail::aeqd::base_aeqd_e_guam<CalculationType, Parameters>
{
inline aeqd_e_guam(const Parameters& par) : detail::aeqd::base_aeqd_e_guam<CalculationType, Parameters>(par)
{
detail::aeqd::setup_aeqd(this->m_par, this->m_proj_parm, false, true);
}
};
/*!
\brief Azimuthal Equidistant projection
\ingroup projections
\tparam Geographic latlong point type
\tparam Cartesian xy point type
\tparam Parameters parameter type
\par Projection characteristics
- Azimuthal
- Spheroid
- Ellipsoid
\par Projection parameters
- lat_0: Latitude of origin (degrees)
- guam (boolean)
\par Example
\image html ex_aeqd.gif
*/
template <typename BGParameters, typename CalculationType, typename Parameters>
struct aeqd_e_static : public detail::aeqd::base_aeqd_e_static<BGParameters, CalculationType, Parameters>
{
inline aeqd_e_static(const Parameters& par) : detail::aeqd::base_aeqd_e_static<BGParameters, CalculationType, Parameters>(par)
{
detail::aeqd::setup_aeqd(this->m_par, this->m_proj_parm,
false,
detail::aeqd::base_aeqd_e_static<BGParameters, CalculationType, Parameters>::is_guam);
}
};
/*!
\brief Azimuthal Equidistant projection
\ingroup projections
\tparam Geographic latlong point type
\tparam Cartesian xy point type
\tparam Parameters parameter type
\par Projection characteristics
- Azimuthal
- Spheroid
- Ellipsoid
\par Projection parameters
- lat_0: Latitude of origin (degrees)
- guam (boolean)
\par Example
\image html ex_aeqd.gif
*/
template <typename CalculationType, typename Parameters>
struct aeqd_s : public detail::aeqd::base_aeqd_s<CalculationType, Parameters>
{
inline aeqd_s(const Parameters& par) : detail::aeqd::base_aeqd_s<CalculationType, Parameters>(par)
{
detail::aeqd::setup_aeqd(this->m_par, this->m_proj_parm, true, false);
}
};
#ifndef DOXYGEN_NO_DETAIL
namespace detail
{
// Static projection
template <typename BGP, typename CT, typename P>
struct static_projection_type<srs::par4::aeqd, srs_sphere_tag, BGP, CT, P>
{
typedef aeqd_s<CT, P> type;
};
template <typename BGP, typename CT, typename P>
struct static_projection_type<srs::par4::aeqd, srs_spheroid_tag, BGP, CT, P>
{
typedef aeqd_e_static<BGP, CT, P> type;
};
//BOOST_GEOMETRY_PROJECTIONS_DETAIL_STATIC_PROJECTION(srs::par4::aeqd, aeqd_s, aeqd_e_static)
//BOOST_GEOMETRY_PROJECTIONS_DETAIL_STATIC_PROJECTION(srs::par4::aeqd_guam, aeqd_guam, aeqd_guam)
// Factory entry(s)
template <typename CalculationType, typename Parameters>
class aeqd_entry : public detail::factory_entry<CalculationType, Parameters>
{
public :
virtual base_v<CalculationType, Parameters>* create_new(const Parameters& par) const
{
bool const guam = pj_param(par.params, "bguam").i != 0;
if (par.es && ! guam)
return new base_v_fi<aeqd_e<CalculationType, Parameters>, CalculationType, Parameters>(par);
else if (par.es && guam)
return new base_v_fi<aeqd_e_guam<CalculationType, Parameters>, CalculationType, Parameters>(par);
else
return new base_v_fi<aeqd_s<CalculationType, Parameters>, CalculationType, Parameters>(par);
}
};
template <typename CalculationType, typename Parameters>
inline void aeqd_init(detail::base_factory<CalculationType, Parameters>& factory)
{
factory.add_to_factory("aeqd", new aeqd_entry<CalculationType, Parameters>);
}
} // namespace detail
#endif // doxygen
} // namespace projections
}} // namespace boost::geometry
#endif // BOOST_GEOMETRY_PROJECTIONS_AEQD_HPP

View File

@@ -0,0 +1,257 @@
#ifndef BOOST_GEOMETRY_PROJECTIONS_AIRY_HPP
#define BOOST_GEOMETRY_PROJECTIONS_AIRY_HPP
// Boost.Geometry - extensions-gis-projections (based on PROJ4)
// This file is automatically generated. DO NOT EDIT.
// Copyright (c) 2008-2015 Barend Gehrels, Amsterdam, the Netherlands.
// This file was modified by Oracle on 2017.
// Modifications copyright (c) 2017, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle.
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
// This file is converted from PROJ4, http://trac.osgeo.org/proj
// PROJ4 is originally written by Gerald Evenden (then of the USGS)
// PROJ4 is maintained by Frank Warmerdam
// PROJ4 is converted to Boost.Geometry by Barend Gehrels
// Last updated version of proj: 4.9.1
// Original copyright notice:
// Purpose: Implementation of the airy (Airy) projection.
// Author: Gerald Evenden
// Copyright (c) 1995, Gerald Evenden
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the "Software"),
// to deal in the Software without restriction, including without limitation
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
// and/or sell copies of the Software, and to permit persons to whom the
// Software is furnished to do so, subject to the following conditions:
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Software.
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.
#include <boost/geometry/util/math.hpp>
#include <boost/geometry/srs/projections/impl/base_static.hpp>
#include <boost/geometry/srs/projections/impl/base_dynamic.hpp>
#include <boost/geometry/srs/projections/impl/projects.hpp>
#include <boost/geometry/srs/projections/impl/factory_entry.hpp>
#include <boost/geometry/srs/projections/par4.hpp> // airy tag
namespace boost { namespace geometry
{
namespace srs { namespace par4
{
// already defined in par4.hpp as ellps name
//struct airy {};
}} //namespace srs::par4
namespace projections
{
#ifndef DOXYGEN_NO_DETAIL
namespace detail { namespace airy
{
static const double EPS = 1.e-10;
static const int N_POLE = 0;
static const int S_POLE = 1;
static const int EQUIT = 2;
static const int OBLIQ = 3;
template <typename T>
struct par_airy
{
T p_halfpi;
T sinph0;
T cosph0;
T Cb;
int mode;
int no_cut; /* do not cut at hemisphere limit */
};
// template class, using CRTP to implement forward/inverse
template <typename CalculationType, typename Parameters>
struct base_airy_spheroid : public base_t_f<base_airy_spheroid<CalculationType, Parameters>,
CalculationType, Parameters>
{
typedef CalculationType geographic_type;
typedef CalculationType cartesian_type;
par_airy<CalculationType> m_proj_parm;
inline base_airy_spheroid(const Parameters& par)
: base_t_f<base_airy_spheroid<CalculationType, Parameters>,
CalculationType, Parameters>(*this, par) {}
// FORWARD(s_forward) spheroid
// Project coordinates from geographic (lon, lat) to cartesian (x, y)
inline void fwd(geographic_type& lp_lon, geographic_type& lp_lat, cartesian_type& xy_x, cartesian_type& xy_y) const
{
static const CalculationType HALFPI = detail::HALFPI<CalculationType>();
CalculationType sinlam, coslam, cosphi, sinphi, t, s, Krho, cosz;
sinlam = sin(lp_lon);
coslam = cos(lp_lon);
switch (this->m_proj_parm.mode) {
case EQUIT:
case OBLIQ:
sinphi = sin(lp_lat);
cosphi = cos(lp_lat);
cosz = cosphi * coslam;
if (this->m_proj_parm.mode == OBLIQ)
cosz = this->m_proj_parm.sinph0 * sinphi + this->m_proj_parm.cosph0 * cosz;
if (!this->m_proj_parm.no_cut && cosz < -EPS)
BOOST_THROW_EXCEPTION( projection_exception(-20) );
if (fabs(s = 1. - cosz) > EPS) {
t = 0.5 * (1. + cosz);
Krho = -log(t)/s - this->m_proj_parm.Cb / t;
} else
Krho = 0.5 - this->m_proj_parm.Cb;
xy_x = Krho * cosphi * sinlam;
if (this->m_proj_parm.mode == OBLIQ)
xy_y = Krho * (this->m_proj_parm.cosph0 * sinphi -
this->m_proj_parm.sinph0 * cosphi * coslam);
else
xy_y = Krho * sinphi;
break;
case S_POLE:
case N_POLE:
lp_lat = fabs(this->m_proj_parm.p_halfpi - lp_lat);
if (!this->m_proj_parm.no_cut && (lp_lat - EPS) > HALFPI)
BOOST_THROW_EXCEPTION( projection_exception(-20) );
if ((lp_lat *= 0.5) > EPS) {
t = tan(lp_lat);
Krho = -2.*(log(cos(lp_lat)) / t + t * this->m_proj_parm.Cb);
xy_x = Krho * sinlam;
xy_y = Krho * coslam;
if (this->m_proj_parm.mode == N_POLE)
xy_y = -xy_y;
} else
xy_x = xy_y = 0.;
}
}
static inline std::string get_name()
{
return "airy_spheroid";
}
};
// Airy
template <typename Parameters, typename T>
inline void setup_airy(Parameters& par, par_airy<T>& proj_parm)
{
static const T HALFPI = detail::HALFPI<T>();
T beta;
proj_parm.no_cut = pj_param(par.params, "bno_cut").i;
beta = 0.5 * (HALFPI - pj_param(par.params, "rlat_b").f);
if (fabs(beta) < EPS)
proj_parm.Cb = -0.5;
else {
proj_parm.Cb = 1./tan(beta);
proj_parm.Cb *= proj_parm.Cb * log(cos(beta));
}
if (fabs(fabs(par.phi0) - HALFPI) < EPS)
if (par.phi0 < 0.) {
proj_parm.p_halfpi = -HALFPI;
proj_parm.mode = S_POLE;
} else {
proj_parm.p_halfpi = HALFPI;
proj_parm.mode = N_POLE;
}
else {
if (fabs(par.phi0) < EPS)
proj_parm.mode = EQUIT;
else {
proj_parm.mode = OBLIQ;
proj_parm.sinph0 = sin(par.phi0);
proj_parm.cosph0 = cos(par.phi0);
}
}
par.es = 0.;
}
}} // namespace detail::airy
#endif // doxygen
/*!
\brief Airy projection
\ingroup projections
\tparam Geographic latlong point type
\tparam Cartesian xy point type
\tparam Parameters parameter type
\par Projection characteristics
- Miscellaneous
- Spheroid
- no inverse
\par Projection parameters
- no_cut: Do not cut at hemisphere limit (boolean)
- lat_b (degrees)
\par Example
\image html ex_airy.gif
*/
template <typename CalculationType, typename Parameters>
struct airy_spheroid : public detail::airy::base_airy_spheroid<CalculationType, Parameters>
{
inline airy_spheroid(const Parameters& par) : detail::airy::base_airy_spheroid<CalculationType, Parameters>(par)
{
detail::airy::setup_airy(this->m_par, this->m_proj_parm);
}
};
#ifndef DOXYGEN_NO_DETAIL
namespace detail
{
// Static projection
BOOST_GEOMETRY_PROJECTIONS_DETAIL_STATIC_PROJECTION(srs::par4::airy, airy_spheroid, airy_spheroid)
// Factory entry(s)
template <typename CalculationType, typename Parameters>
class airy_entry : public detail::factory_entry<CalculationType, Parameters>
{
public :
virtual base_v<CalculationType, Parameters>* create_new(const Parameters& par) const
{
return new base_v_f<airy_spheroid<CalculationType, Parameters>, CalculationType, Parameters>(par);
}
};
template <typename CalculationType, typename Parameters>
inline void airy_init(detail::base_factory<CalculationType, Parameters>& factory)
{
factory.add_to_factory("airy", new airy_entry<CalculationType, Parameters>);
}
} // namespace detail
#endif // doxygen
} // namespace projections
}} // namespace boost::geometry
#endif // BOOST_GEOMETRY_PROJECTIONS_AIRY_HPP

View File

@@ -0,0 +1,324 @@
#ifndef BOOST_GEOMETRY_PROJECTIONS_AITOFF_HPP
#define BOOST_GEOMETRY_PROJECTIONS_AITOFF_HPP
// Boost.Geometry - extensions-gis-projections (based on PROJ4)
// This file is automatically generated. DO NOT EDIT.
// Copyright (c) 2008-2015 Barend Gehrels, Amsterdam, the Netherlands.
// This file was modified by Oracle on 2017.
// Modifications copyright (c) 2017, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle.
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
// This file is converted from PROJ4, http://trac.osgeo.org/proj
// PROJ4 is originally written by Gerald Evenden (then of the USGS)
// PROJ4 is maintained by Frank Warmerdam
// PROJ4 is converted to Boost.Geometry by Barend Gehrels
// Last updated version of proj: 4.9.1
// Original copyright notice:
// Purpose: Implementation of the aitoff (Aitoff) and wintri (Winkel Tripel)
// projections.
// Author: Gerald Evenden
// Copyright (c) 1995, Gerald Evenden
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the "Software"),
// to deal in the Software without restriction, including without limitation
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
// and/or sell copies of the Software, and to permit persons to whom the
// Software is furnished to do so, subject to the following conditions:
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Software.
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.
#include <boost/core/ignore_unused.hpp>
#include <boost/geometry/util/math.hpp>
#include <boost/geometry/srs/projections/impl/base_static.hpp>
#include <boost/geometry/srs/projections/impl/base_dynamic.hpp>
#include <boost/geometry/srs/projections/impl/projects.hpp>
#include <boost/geometry/srs/projections/impl/factory_entry.hpp>
namespace boost { namespace geometry
{
namespace srs { namespace par4
{
struct aitoff {};
struct wintri {};
}} //namespace srs::par4
namespace projections
{
#ifndef DOXYGEN_NO_DETAIL
namespace detail { namespace aitoff
{
template <typename T>
struct par_aitoff
{
T cosphi1;
int mode;
};
// template class, using CRTP to implement forward/inverse
template <typename CalculationType, typename Parameters>
struct base_aitoff_spheroid : public base_t_fi<base_aitoff_spheroid<CalculationType, Parameters>,
CalculationType, Parameters>
{
typedef CalculationType geographic_type;
typedef CalculationType cartesian_type;
par_aitoff<CalculationType> m_proj_parm;
inline base_aitoff_spheroid(const Parameters& par)
: base_t_fi<base_aitoff_spheroid<CalculationType, Parameters>,
CalculationType, Parameters>(*this, par) {}
// FORWARD(s_forward) spheroid
// Project coordinates from geographic (lon, lat) to cartesian (x, y)
inline void fwd(geographic_type& lp_lon, geographic_type& lp_lat, cartesian_type& xy_x, cartesian_type& xy_y) const
{
CalculationType c, d;
if((d = acos(cos(lp_lat) * cos(c = 0.5 * lp_lon)))) {/* basic Aitoff */
xy_x = 2. * d * cos(lp_lat) * sin(c) * (xy_y = 1. / sin(d));
xy_y *= d * sin(lp_lat);
} else
xy_x = xy_y = 0.;
if (this->m_proj_parm.mode) { /* Winkel Tripel */
xy_x = (xy_x + lp_lon * this->m_proj_parm.cosphi1) * 0.5;
xy_y = (xy_y + lp_lat) * 0.5;
}
}
/***********************************************************************************
*
* Inverse functions added by Drazen Tutic and Lovro Gradiser based on paper:
*
* I.Özbug Biklirici and Cengizhan Ipbüker. A General Algorithm for the Inverse
* Transformation of Map Projections Using Jacobian Matrices. In Proceedings of the
* Third International Symposium Mathematical & Computational Applications,
* pages 175{182, Turkey, September 2002.
*
* Expected accuracy is defined by EPSILON = 1e-12. Should be appropriate for
* most applications of Aitoff and Winkel Tripel projections.
*
* Longitudes of 180W and 180E can be mixed in solution obtained.
*
* Inverse for Aitoff projection in poles is undefined, longitude value of 0 is assumed.
*
* Contact : dtutic@geof.hr
* Date: 2015-02-16
*
************************************************************************************/
// INVERSE(s_inverse) sphere
// Project coordinates from cartesian (x, y) to geographic (lon, lat)
inline void inv(cartesian_type& xy_x, cartesian_type& xy_y, geographic_type& lp_lon, geographic_type& lp_lat) const
{
static const CalculationType ONEPI = detail::ONEPI<CalculationType>();
static const CalculationType TWOPI = detail::TWOPI<CalculationType>();
static const CalculationType EPSILON = 1e-12;
int iter, MAXITER = 10, round = 0, MAXROUND = 20;
CalculationType D, C, f1, f2, f1p, f1l, f2p, f2l, dp, dl, sl, sp, cp, cl, x, y;
if ((fabs(xy_x) < EPSILON) && (fabs(xy_y) < EPSILON )) { lp_lat = 0.; lp_lon = 0.; return; }
/* intial values for Newton-Raphson method */
lp_lat = xy_y; lp_lon = xy_x;
do {
iter = 0;
do {
sl = sin(lp_lon * 0.5); cl = cos(lp_lon * 0.5);
sp = sin(lp_lat); cp = cos(lp_lat);
D = cp * cl;
C = 1. - D * D;
D = acos(D) / pow(C, 1.5);
f1 = 2. * D * C * cp * sl;
f2 = D * C * sp;
f1p = 2.* (sl * cl * sp * cp / C - D * sp * sl);
f1l = cp * cp * sl * sl / C + D * cp * cl * sp * sp;
f2p = sp * sp * cl / C + D * sl * sl * cp;
f2l = 0.5 * (sp * cp * sl / C - D * sp * cp * cp * sl * cl);
if (this->m_proj_parm.mode) { /* Winkel Tripel */
f1 = 0.5 * (f1 + lp_lon * this->m_proj_parm.cosphi1);
f2 = 0.5 * (f2 + lp_lat);
f1p *= 0.5;
f1l = 0.5 * (f1l + this->m_proj_parm.cosphi1);
f2p = 0.5 * (f2p + 1.);
f2l *= 0.5;
}
f1 -= xy_x; f2 -= xy_y;
dl = (f2 * f1p - f1 * f2p) / (dp = f1p * f2l - f2p * f1l);
dp = (f1 * f2l - f2 * f1l) / dp;
while (dl > ONEPI) dl -= ONEPI; /* set to interval [-ONEPI, ONEPI] */
while (dl < -ONEPI) dl += ONEPI; /* set to interval [-ONEPI, ONEPI] */
lp_lat -= dp; lp_lon -= dl;
} while ((fabs(dp) > EPSILON || fabs(dl) > EPSILON) && (iter++ < MAXITER));
if (lp_lat > TWOPI) lp_lat -= 2.*(lp_lat-TWOPI); /* correct if symmetrical solution for Aitoff */
if (lp_lat < -TWOPI) lp_lat -= 2.*(lp_lat+TWOPI); /* correct if symmetrical solution for Aitoff */
if ((fabs(fabs(lp_lat) - TWOPI) < EPSILON) && (!this->m_proj_parm.mode)) lp_lon = 0.; /* if pole in Aitoff, return longitude of 0 */
/* calculate x,y coordinates with solution obtained */
if((D = acos(cos(lp_lat) * cos(C = 0.5 * lp_lon)))) {/* Aitoff */
x = 2. * D * cos(lp_lat) * sin(C) * (y = 1. / sin(D));
y *= D * sin(lp_lat);
} else
x = y = 0.;
if (this->m_proj_parm.mode) { /* Winkel Tripel */
x = (x + lp_lon * this->m_proj_parm.cosphi1) * 0.5;
y = (y + lp_lat) * 0.5;
}
/* if too far from given values of x,y, repeat with better approximation of phi,lam */
} while (((fabs(xy_x-x) > EPSILON) || (fabs(xy_y-y) > EPSILON)) && (round++ < MAXROUND));
//if (iter == MAXITER && round == MAXROUND) fprintf(stderr, "Warning: Accuracy of 1e-12 not reached. Last increments: dlat=%e and dlon=%e\n", dp, dl);
}
static inline std::string get_name()
{
return "aitoff_spheroid";
}
};
template <typename Parameters, typename T>
inline void setup(Parameters& par, par_aitoff<T>& proj_parm)
{
boost::ignore_unused(proj_parm);
par.es = 0.;
}
// Aitoff
template <typename Parameters, typename T>
inline void setup_aitoff(Parameters& par, par_aitoff<T>& proj_parm)
{
proj_parm.mode = 0;
setup(par, proj_parm);
}
// Winkel Tripel
template <typename Parameters, typename T>
inline void setup_wintri(Parameters& par, par_aitoff<T>& proj_parm)
{
static const T TWO_D_PI = detail::TWO_D_PI<T>();
proj_parm.mode = 1;
if (pj_param(par.params, "tlat_1").i) {
if ((proj_parm.cosphi1 = cos(pj_param(par.params, "rlat_1").f)) == 0.)
BOOST_THROW_EXCEPTION( projection_exception(-22) );
} else /* 50d28' or phi1=acos(2/pi) */
proj_parm.cosphi1 = TWO_D_PI;
setup(par, proj_parm);
}
}} // namespace detail::aitoff
#endif // doxygen
/*!
\brief Aitoff projection
\ingroup projections
\tparam Geographic latlong point type
\tparam Cartesian xy point type
\tparam Parameters parameter type
\par Projection characteristics
- Miscellaneous
- Spheroid
\par Example
\image html ex_aitoff.gif
*/
template <typename CalculationType, typename Parameters>
struct aitoff_spheroid : public detail::aitoff::base_aitoff_spheroid<CalculationType, Parameters>
{
inline aitoff_spheroid(const Parameters& par) : detail::aitoff::base_aitoff_spheroid<CalculationType, Parameters>(par)
{
detail::aitoff::setup_aitoff(this->m_par, this->m_proj_parm);
}
};
/*!
\brief Winkel Tripel projection
\ingroup projections
\tparam Geographic latlong point type
\tparam Cartesian xy point type
\tparam Parameters parameter type
\par Projection characteristics
- Miscellaneous
- Spheroid
\par Projection parameters
- lat_1: Latitude of first standard parallel (degrees)
\par Example
\image html ex_wintri.gif
*/
template <typename CalculationType, typename Parameters>
struct wintri_spheroid : public detail::aitoff::base_aitoff_spheroid<CalculationType, Parameters>
{
inline wintri_spheroid(const Parameters& par) : detail::aitoff::base_aitoff_spheroid<CalculationType, Parameters>(par)
{
detail::aitoff::setup_wintri(this->m_par, this->m_proj_parm);
}
};
#ifndef DOXYGEN_NO_DETAIL
namespace detail
{
// Static projection
BOOST_GEOMETRY_PROJECTIONS_DETAIL_STATIC_PROJECTION(srs::par4::aitoff, aitoff_spheroid, aitoff_spheroid)
BOOST_GEOMETRY_PROJECTIONS_DETAIL_STATIC_PROJECTION(srs::par4::wintri, wintri_spheroid, wintri_spheroid)
// Factory entry(s)
template <typename CalculationType, typename Parameters>
class aitoff_entry : public detail::factory_entry<CalculationType, Parameters>
{
public :
virtual base_v<CalculationType, Parameters>* create_new(const Parameters& par) const
{
return new base_v_fi<aitoff_spheroid<CalculationType, Parameters>, CalculationType, Parameters>(par);
}
};
template <typename CalculationType, typename Parameters>
class wintri_entry : public detail::factory_entry<CalculationType, Parameters>
{
public :
virtual base_v<CalculationType, Parameters>* create_new(const Parameters& par) const
{
return new base_v_fi<wintri_spheroid<CalculationType, Parameters>, CalculationType, Parameters>(par);
}
};
template <typename CalculationType, typename Parameters>
inline void aitoff_init(detail::base_factory<CalculationType, Parameters>& factory)
{
factory.add_to_factory("aitoff", new aitoff_entry<CalculationType, Parameters>);
factory.add_to_factory("wintri", new wintri_entry<CalculationType, Parameters>);
}
} // namespace detail
#endif // doxygen
} // namespace projections
}} // namespace boost::geometry
#endif // BOOST_GEOMETRY_PROJECTIONS_AITOFF_HPP

View File

@@ -0,0 +1,168 @@
#ifndef BOOST_GEOMETRY_PROJECTIONS_AUGUST_HPP
#define BOOST_GEOMETRY_PROJECTIONS_AUGUST_HPP
// Boost.Geometry - extensions-gis-projections (based on PROJ4)
// This file is automatically generated. DO NOT EDIT.
// Copyright (c) 2008-2015 Barend Gehrels, Amsterdam, the Netherlands.
// This file was modified by Oracle on 2017.
// Modifications copyright (c) 2017, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle.
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
// This file is converted from PROJ4, http://trac.osgeo.org/proj
// PROJ4 is originally written by Gerald Evenden (then of the USGS)
// PROJ4 is maintained by Frank Warmerdam
// PROJ4 is converted to Boost.Geometry by Barend Gehrels
// Last updated version of proj: 4.9.1
// Original copyright notice:
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the "Software"),
// to deal in the Software without restriction, including without limitation
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
// and/or sell copies of the Software, and to permit persons to whom the
// Software is furnished to do so, subject to the following conditions:
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Software.
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.
#include <boost/geometry/srs/projections/impl/base_static.hpp>
#include <boost/geometry/srs/projections/impl/base_dynamic.hpp>
#include <boost/geometry/srs/projections/impl/projects.hpp>
#include <boost/geometry/srs/projections/impl/factory_entry.hpp>
namespace boost { namespace geometry
{
namespace srs { namespace par4
{
struct august {};
}} //namespace srs::par4
namespace projections
{
#ifndef DOXYGEN_NO_DETAIL
namespace detail { namespace august
{
//static const double M = 1.333333333333333;
// template class, using CRTP to implement forward/inverse
template <typename CalculationType, typename Parameters>
struct base_august_spheroid : public base_t_f<base_august_spheroid<CalculationType, Parameters>,
CalculationType, Parameters>
{
typedef CalculationType geographic_type;
typedef CalculationType cartesian_type;
inline base_august_spheroid(const Parameters& par)
: base_t_f<base_august_spheroid<CalculationType, Parameters>,
CalculationType, Parameters>(*this, par) {}
// FORWARD(s_forward) spheroid
// Project coordinates from geographic (lon, lat) to cartesian (x, y)
inline void fwd(geographic_type& lp_lon, geographic_type& lp_lat, cartesian_type& xy_x, cartesian_type& xy_y) const
{
static const CalculationType M = 1.333333333333333333333333333333333333;
CalculationType t, c1, c, x1, x12, y1, y12;
t = tan(.5 * lp_lat);
c1 = sqrt(1. - t * t);
c = 1. + c1 * cos(lp_lon *= .5);
x1 = sin(lp_lon) * c1 / c;
y1 = t / c;
xy_x = M * x1 * (3. + (x12 = x1 * x1) - 3. * (y12 = y1 * y1));
xy_y = M * y1 * (3. + 3. * x12 - y12);
}
static inline std::string get_name()
{
return "august_spheroid";
}
};
// August Epicycloidal
template <typename Parameters>
inline void setup_august(Parameters& par)
{
par.es = 0.;
}
}} // namespace detail::august
#endif // doxygen
/*!
\brief August Epicycloidal projection
\ingroup projections
\tparam Geographic latlong point type
\tparam Cartesian xy point type
\tparam Parameters parameter type
\par Projection characteristics
- Miscellaneous
- Spheroid
- no inverse
\par Example
\image html ex_august.gif
*/
template <typename CalculationType, typename Parameters>
struct august_spheroid : public detail::august::base_august_spheroid<CalculationType, Parameters>
{
inline august_spheroid(const Parameters& par) : detail::august::base_august_spheroid<CalculationType, Parameters>(par)
{
detail::august::setup_august(this->m_par);
}
};
#ifndef DOXYGEN_NO_DETAIL
namespace detail
{
// Static projection
BOOST_GEOMETRY_PROJECTIONS_DETAIL_STATIC_PROJECTION(srs::par4::august, august_spheroid, august_spheroid)
// Factory entry(s)
template <typename CalculationType, typename Parameters>
class august_entry : public detail::factory_entry<CalculationType, Parameters>
{
public :
virtual base_v<CalculationType, Parameters>* create_new(const Parameters& par) const
{
return new base_v_f<august_spheroid<CalculationType, Parameters>, CalculationType, Parameters>(par);
}
};
template <typename CalculationType, typename Parameters>
inline void august_init(detail::base_factory<CalculationType, Parameters>& factory)
{
factory.add_to_factory("august", new august_entry<CalculationType, Parameters>);
}
} // namespace detail
#endif // doxygen
} // namespace projections
}} // namespace boost::geometry
#endif // BOOST_GEOMETRY_PROJECTIONS_AUGUST_HPP

View File

@@ -0,0 +1,272 @@
#ifndef BOOST_GEOMETRY_PROJECTIONS_BACON_HPP
#define BOOST_GEOMETRY_PROJECTIONS_BACON_HPP
// Boost.Geometry - extensions-gis-projections (based on PROJ4)
// This file is automatically generated. DO NOT EDIT.
// Copyright (c) 2008-2015 Barend Gehrels, Amsterdam, the Netherlands.
// This file was modified by Oracle on 2017.
// Modifications copyright (c) 2017, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle.
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
// This file is converted from PROJ4, http://trac.osgeo.org/proj
// PROJ4 is originally written by Gerald Evenden (then of the USGS)
// PROJ4 is maintained by Frank Warmerdam
// PROJ4 is converted to Boost.Geometry by Barend Gehrels
// Last updated version of proj: 4.9.1
// Original copyright notice:
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the "Software"),
// to deal in the Software without restriction, including without limitation
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
// and/or sell copies of the Software, and to permit persons to whom the
// Software is furnished to do so, subject to the following conditions:
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Software.
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.
#include <boost/geometry/util/math.hpp>
#include <boost/geometry/srs/projections/impl/base_static.hpp>
#include <boost/geometry/srs/projections/impl/base_dynamic.hpp>
#include <boost/geometry/srs/projections/impl/projects.hpp>
#include <boost/geometry/srs/projections/impl/factory_entry.hpp>
namespace boost { namespace geometry
{
namespace srs { namespace par4
{
struct apian {};
struct ortel {};
struct bacon {};
}} //namespace srs::par4
namespace projections
{
#ifndef DOXYGEN_NO_DETAIL
namespace detail { namespace bacon
{
//static const double HLFPI2 = 2.46740110027233965467;
static const double EPS = 1e-10;
struct par_bacon
{
int bacn;
int ortl;
};
// template class, using CRTP to implement forward/inverse
template <typename CalculationType, typename Parameters>
struct base_bacon_spheroid : public base_t_f<base_bacon_spheroid<CalculationType, Parameters>,
CalculationType, Parameters>
{
typedef CalculationType geographic_type;
typedef CalculationType cartesian_type;
par_bacon m_proj_parm;
inline base_bacon_spheroid(const Parameters& par)
: base_t_f<base_bacon_spheroid<CalculationType, Parameters>,
CalculationType, Parameters>(*this, par) {}
// FORWARD(s_forward) spheroid
// Project coordinates from geographic (lon, lat) to cartesian (x, y)
inline void fwd(geographic_type& lp_lon, geographic_type& lp_lat, cartesian_type& xy_x, cartesian_type& xy_y) const
{
static const CalculationType HALFPI = detail::HALFPI<CalculationType>();
static const CalculationType HLFPI2 = detail::HALFPI_SQR<CalculationType>();
CalculationType ax, f;
xy_y = this->m_proj_parm.bacn ? HALFPI * sin(lp_lat) : lp_lat;
if ((ax = fabs(lp_lon)) >= EPS) {
if (this->m_proj_parm.ortl && ax >= HALFPI)
xy_x = sqrt(HLFPI2 - lp_lat * lp_lat + EPS) + ax - HALFPI;
else {
f = 0.5 * (HLFPI2 / ax + ax);
xy_x = ax - f + sqrt(f * f - xy_y * xy_y);
}
if (lp_lon < 0.) xy_x = - xy_x;
} else
xy_x = 0.;
}
static inline std::string get_name()
{
return "bacon_spheroid";
}
};
// Apian Globular I
template <typename Parameters>
inline void setup_apian(Parameters& par, par_bacon& proj_parm)
{
proj_parm.bacn = proj_parm.ortl = 0;
par.es = 0.;
}
// Ortelius Oval
template <typename Parameters>
inline void setup_ortel(Parameters& par, par_bacon& proj_parm)
{
proj_parm.bacn = 0;
proj_parm.ortl = 1;
par.es = 0.;
}
// Bacon Globular
template <typename Parameters>
inline void setup_bacon(Parameters& par, par_bacon& proj_parm)
{
proj_parm.bacn = 1;
proj_parm.ortl = 0;
par.es = 0.;
}
}} // namespace detail::bacon
#endif // doxygen
/*!
\brief Apian Globular I projection
\ingroup projections
\tparam Geographic latlong point type
\tparam Cartesian xy point type
\tparam Parameters parameter type
\par Projection characteristics
- Miscellaneous
- Spheroid
- no inverse
\par Example
\image html ex_apian.gif
*/
template <typename CalculationType, typename Parameters>
struct apian_spheroid : public detail::bacon::base_bacon_spheroid<CalculationType, Parameters>
{
inline apian_spheroid(const Parameters& par) : detail::bacon::base_bacon_spheroid<CalculationType, Parameters>(par)
{
detail::bacon::setup_apian(this->m_par, this->m_proj_parm);
}
};
/*!
\brief Ortelius Oval projection
\ingroup projections
\tparam Geographic latlong point type
\tparam Cartesian xy point type
\tparam Parameters parameter type
\par Projection characteristics
- Miscellaneous
- Spheroid
- no inverse
\par Example
\image html ex_ortel.gif
*/
template <typename CalculationType, typename Parameters>
struct ortel_spheroid : public detail::bacon::base_bacon_spheroid<CalculationType, Parameters>
{
inline ortel_spheroid(const Parameters& par) : detail::bacon::base_bacon_spheroid<CalculationType, Parameters>(par)
{
detail::bacon::setup_ortel(this->m_par, this->m_proj_parm);
}
};
/*!
\brief Bacon Globular projection
\ingroup projections
\tparam Geographic latlong point type
\tparam Cartesian xy point type
\tparam Parameters parameter type
\par Projection characteristics
- Miscellaneous
- Spheroid
- no inverse
\par Example
\image html ex_bacon.gif
*/
template <typename CalculationType, typename Parameters>
struct bacon_spheroid : public detail::bacon::base_bacon_spheroid<CalculationType, Parameters>
{
inline bacon_spheroid(const Parameters& par) : detail::bacon::base_bacon_spheroid<CalculationType, Parameters>(par)
{
detail::bacon::setup_bacon(this->m_par, this->m_proj_parm);
}
};
#ifndef DOXYGEN_NO_DETAIL
namespace detail
{
// Static projection
BOOST_GEOMETRY_PROJECTIONS_DETAIL_STATIC_PROJECTION(srs::par4::apian, apian_spheroid, apian_spheroid)
BOOST_GEOMETRY_PROJECTIONS_DETAIL_STATIC_PROJECTION(srs::par4::bacon, bacon_spheroid, bacon_spheroid)
BOOST_GEOMETRY_PROJECTIONS_DETAIL_STATIC_PROJECTION(srs::par4::ortel, ortel_spheroid, ortel_spheroid)
// Factory entry(s)
template <typename CalculationType, typename Parameters>
class apian_entry : public detail::factory_entry<CalculationType, Parameters>
{
public :
virtual base_v<CalculationType, Parameters>* create_new(const Parameters& par) const
{
return new base_v_f<apian_spheroid<CalculationType, Parameters>, CalculationType, Parameters>(par);
}
};
template <typename CalculationType, typename Parameters>
class ortel_entry : public detail::factory_entry<CalculationType, Parameters>
{
public :
virtual base_v<CalculationType, Parameters>* create_new(const Parameters& par) const
{
return new base_v_f<ortel_spheroid<CalculationType, Parameters>, CalculationType, Parameters>(par);
}
};
template <typename CalculationType, typename Parameters>
class bacon_entry : public detail::factory_entry<CalculationType, Parameters>
{
public :
virtual base_v<CalculationType, Parameters>* create_new(const Parameters& par) const
{
return new base_v_f<bacon_spheroid<CalculationType, Parameters>, CalculationType, Parameters>(par);
}
};
template <typename CalculationType, typename Parameters>
inline void bacon_init(detail::base_factory<CalculationType, Parameters>& factory)
{
factory.add_to_factory("apian", new apian_entry<CalculationType, Parameters>);
factory.add_to_factory("ortel", new ortel_entry<CalculationType, Parameters>);
factory.add_to_factory("bacon", new bacon_entry<CalculationType, Parameters>);
}
} // namespace detail
#endif // doxygen
} // namespace projections
}} // namespace boost::geometry
#endif // BOOST_GEOMETRY_PROJECTIONS_BACON_HPP

View File

@@ -0,0 +1,297 @@
#ifndef BOOST_GEOMETRY_PROJECTIONS_BIPC_HPP
#define BOOST_GEOMETRY_PROJECTIONS_BIPC_HPP
// Boost.Geometry - extensions-gis-projections (based on PROJ4)
// This file is automatically generated. DO NOT EDIT.
// Copyright (c) 2008-2015 Barend Gehrels, Amsterdam, the Netherlands.
// This file was modified by Oracle on 2017.
// Modifications copyright (c) 2017, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle.
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
// This file is converted from PROJ4, http://trac.osgeo.org/proj
// PROJ4 is originally written by Gerald Evenden (then of the USGS)
// PROJ4 is maintained by Frank Warmerdam
// PROJ4 is converted to Boost.Geometry by Barend Gehrels
// Last updated version of proj: 4.9.1
// Original copyright notice:
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the "Software"),
// to deal in the Software without restriction, including without limitation
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
// and/or sell copies of the Software, and to permit persons to whom the
// Software is furnished to do so, subject to the following conditions:
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Software.
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.
#include <boost/geometry/util/math.hpp>
#include <boost/math/special_functions/hypot.hpp>
#include <boost/geometry/srs/projections/impl/base_static.hpp>
#include <boost/geometry/srs/projections/impl/base_dynamic.hpp>
#include <boost/geometry/srs/projections/impl/projects.hpp>
#include <boost/geometry/srs/projections/impl/factory_entry.hpp>
namespace boost { namespace geometry
{
namespace srs { namespace par4
{
struct bipc {};
}} //namespace srs::par4
namespace projections
{
#ifndef DOXYGEN_NO_DETAIL
namespace detail { namespace bipc
{
static const double EPS = 1e-10;
static const double EPS10 = 1e-10;
static const double ONEEPS = 1.000000001;
static const int NITER = 10;
static const double lamB = -.34894976726250681539;
static const double n = .63055844881274687180;
static const double F = 1.89724742567461030582;
static const double Azab = .81650043674686363166;
static const double Azba = 1.82261843856185925133;
static const double T = 1.27246578267089012270;
static const double rhoc = 1.20709121521568721927;
static const double cAzc = .69691523038678375519;
static const double sAzc = .71715351331143607555;
static const double C45 = .70710678118654752469;
static const double S45 = .70710678118654752410;
static const double C20 = .93969262078590838411;
static const double S20 = -.34202014332566873287;
static const double R110 = 1.91986217719376253360;
static const double R104 = 1.81514242207410275904;
struct par_bipc
{
int noskew;
};
// template class, using CRTP to implement forward/inverse
template <typename CalculationType, typename Parameters>
struct base_bipc_spheroid : public base_t_fi<base_bipc_spheroid<CalculationType, Parameters>,
CalculationType, Parameters>
{
typedef CalculationType geographic_type;
typedef CalculationType cartesian_type;
par_bipc m_proj_parm;
inline base_bipc_spheroid(const Parameters& par)
: base_t_fi<base_bipc_spheroid<CalculationType, Parameters>,
CalculationType, Parameters>(*this, par) {}
// FORWARD(s_forward) spheroid
// Project coordinates from geographic (lon, lat) to cartesian (x, y)
inline void fwd(geographic_type& lp_lon, geographic_type& lp_lat, cartesian_type& xy_x, cartesian_type& xy_y) const
{
static const CalculationType HALFPI = detail::HALFPI<CalculationType>();
static const CalculationType ONEPI = detail::ONEPI<CalculationType>();
CalculationType cphi, sphi, tphi, t, al, Az, z, Av, cdlam, sdlam, r;
int tag;
cphi = cos(lp_lat);
sphi = sin(lp_lat);
cdlam = cos(sdlam = lamB - lp_lon);
sdlam = sin(sdlam);
if (fabs(fabs(lp_lat) - HALFPI) < EPS10) {
Az = lp_lat < 0. ? ONEPI : 0.;
tphi = HUGE_VAL;
} else {
tphi = sphi / cphi;
Az = atan2(sdlam , C45 * (tphi - cdlam));
}
if( (tag = (Az > Azba)) ) {
cdlam = cos(sdlam = lp_lon + R110);
sdlam = sin(sdlam);
z = S20 * sphi + C20 * cphi * cdlam;
if (fabs(z) > 1.) {
if (fabs(z) > ONEEPS)
BOOST_THROW_EXCEPTION( projection_exception(-20) );
else
z = z < 0. ? -1. : 1.;
} else
z = acos(z);
if (tphi != HUGE_VAL)
Az = atan2(sdlam, (C20 * tphi - S20 * cdlam));
Av = Azab;
xy_y = rhoc;
} else {
z = S45 * (sphi + cphi * cdlam);
if (fabs(z) > 1.) {
if (fabs(z) > ONEEPS)
BOOST_THROW_EXCEPTION( projection_exception(-20) );
else
z = z < 0. ? -1. : 1.;
} else
z = acos(z);
Av = Azba;
xy_y = -rhoc;
}
if (z < 0.) BOOST_THROW_EXCEPTION( projection_exception(-20) );
r = F * (t = pow(tan(.5 * z), n));
if ((al = .5 * (R104 - z)) < 0.)
BOOST_THROW_EXCEPTION( projection_exception(-20) );
al = (t + pow(al, n)) / T;
if (fabs(al) > 1.) {
if (fabs(al) > ONEEPS)
BOOST_THROW_EXCEPTION( projection_exception(-20) );
else
al = al < 0. ? -1. : 1.;
} else
al = acos(al);
if (fabs(t = n * (Av - Az)) < al)
r /= cos(al + (tag ? t : -t));
xy_x = r * sin(t);
xy_y += (tag ? -r : r) * cos(t);
if (this->m_proj_parm.noskew) {
t = xy_x;
xy_x = -xy_x * cAzc - xy_y * sAzc;
xy_y = -xy_y * cAzc + t * sAzc;
}
}
// INVERSE(s_inverse) spheroid
// Project coordinates from cartesian (x, y) to geographic (lon, lat)
inline void inv(cartesian_type& xy_x, cartesian_type& xy_y, geographic_type& lp_lon, geographic_type& lp_lat) const
{
CalculationType t, r, rp, rl, al, z, fAz, Az, s, c, Av;
int neg, i;
if (this->m_proj_parm.noskew) {
t = xy_x;
xy_x = -xy_x * cAzc + xy_y * sAzc;
xy_y = -xy_y * cAzc - t * sAzc;
}
if( (neg = (xy_x < 0.)) ) {
xy_y = rhoc - xy_y;
s = S20;
c = C20;
Av = Azab;
} else {
xy_y += rhoc;
s = S45;
c = C45;
Av = Azba;
}
rl = rp = r = boost::math::hypot(xy_x, xy_y);
fAz = fabs(Az = atan2(xy_x, xy_y));
for (i = NITER; i ; --i) {
z = 2. * atan(pow(r / F,1 / n));
al = acos((pow(tan(.5 * z), n) +
pow(tan(.5 * (R104 - z)), n)) / T);
if (fAz < al)
r = rp * cos(al + (neg ? Az : -Az));
if (fabs(rl - r) < EPS)
break;
rl = r;
}
if (! i)
BOOST_THROW_EXCEPTION( projection_exception(-20) );
Az = Av - Az / n;
lp_lat = asin(s * cos(z) + c * sin(z) * cos(Az));
lp_lon = atan2(sin(Az), c / tan(z) - s * cos(Az));
if (neg)
lp_lon -= R110;
else
lp_lon = lamB - lp_lon;
}
static inline std::string get_name()
{
return "bipc_spheroid";
}
};
// Bipolar conic of western hemisphere
template <typename Parameters>
inline void setup_bipc(Parameters& par, par_bipc& proj_parm)
{
proj_parm.noskew = pj_param(par.params, "bns").i;
par.es = 0.;
}
}} // namespace detail::bipc
#endif // doxygen
/*!
\brief Bipolar conic of western hemisphere projection
\ingroup projections
\tparam Geographic latlong point type
\tparam Cartesian xy point type
\tparam Parameters parameter type
\par Projection characteristics
- Conic
- Spheroid
\par Projection parameters
- ns (boolean)
\par Example
\image html ex_bipc.gif
*/
template <typename CalculationType, typename Parameters>
struct bipc_spheroid : public detail::bipc::base_bipc_spheroid<CalculationType, Parameters>
{
inline bipc_spheroid(const Parameters& par) : detail::bipc::base_bipc_spheroid<CalculationType, Parameters>(par)
{
detail::bipc::setup_bipc(this->m_par, this->m_proj_parm);
}
};
#ifndef DOXYGEN_NO_DETAIL
namespace detail
{
// Static projection
BOOST_GEOMETRY_PROJECTIONS_DETAIL_STATIC_PROJECTION(srs::par4::bipc, bipc_spheroid, bipc_spheroid)
// Factory entry(s)
template <typename CalculationType, typename Parameters>
class bipc_entry : public detail::factory_entry<CalculationType, Parameters>
{
public :
virtual base_v<CalculationType, Parameters>* create_new(const Parameters& par) const
{
return new base_v_fi<bipc_spheroid<CalculationType, Parameters>, CalculationType, Parameters>(par);
}
};
template <typename CalculationType, typename Parameters>
inline void bipc_init(detail::base_factory<CalculationType, Parameters>& factory)
{
factory.add_to_factory("bipc", new bipc_entry<CalculationType, Parameters>);
}
} // namespace detail
#endif // doxygen
} // namespace projections
}} // namespace boost::geometry
#endif // BOOST_GEOMETRY_PROJECTIONS_BIPC_HPP

View File

@@ -0,0 +1,185 @@
#ifndef BOOST_GEOMETRY_PROJECTIONS_BOGGS_HPP
#define BOOST_GEOMETRY_PROJECTIONS_BOGGS_HPP
// Boost.Geometry - extensions-gis-projections (based on PROJ4)
// This file is automatically generated. DO NOT EDIT.
// Copyright (c) 2008-2015 Barend Gehrels, Amsterdam, the Netherlands.
// This file was modified by Oracle on 2017.
// Modifications copyright (c) 2017, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle.
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
// This file is converted from PROJ4, http://trac.osgeo.org/proj
// PROJ4 is originally written by Gerald Evenden (then of the USGS)
// PROJ4 is maintained by Frank Warmerdam
// PROJ4 is converted to Boost.Geometry by Barend Gehrels
// Last updated version of proj: 4.9.1
// Original copyright notice:
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the "Software"),
// to deal in the Software without restriction, including without limitation
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
// and/or sell copies of the Software, and to permit persons to whom the
// Software is furnished to do so, subject to the following conditions:
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Software.
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.
#include <boost/geometry/util/math.hpp>
#include <boost/geometry/srs/projections/impl/base_static.hpp>
#include <boost/geometry/srs/projections/impl/base_dynamic.hpp>
#include <boost/geometry/srs/projections/impl/projects.hpp>
#include <boost/geometry/srs/projections/impl/factory_entry.hpp>
namespace boost { namespace geometry
{
namespace srs { namespace par4
{
struct boggs {};
}} //namespace srs::par4
namespace projections
{
#ifndef DOXYGEN_NO_DETAIL
namespace detail { namespace boggs
{
static const int NITER = 20;
static const double EPS = 1e-7;
static const double ONETOL = 1.000001;
static const double FXC = 2.00276;
static const double FXC2 = 1.11072;
static const double FYC = 0.49931;
static const double FYC2 = 1.41421356237309504880;
// template class, using CRTP to implement forward/inverse
template <typename CalculationType, typename Parameters>
struct base_boggs_spheroid : public base_t_f<base_boggs_spheroid<CalculationType, Parameters>,
CalculationType, Parameters>
{
typedef CalculationType geographic_type;
typedef CalculationType cartesian_type;
inline base_boggs_spheroid(const Parameters& par)
: base_t_f<base_boggs_spheroid<CalculationType, Parameters>,
CalculationType, Parameters>(*this, par) {}
// FORWARD(s_forward) spheroid
// Project coordinates from geographic (lon, lat) to cartesian (x, y)
inline void fwd(geographic_type& lp_lon, geographic_type& lp_lat, cartesian_type& xy_x, cartesian_type& xy_y) const
{
static const CalculationType HALFPI = detail::HALFPI<CalculationType>();
static const CalculationType ONEPI = detail::ONEPI<CalculationType>();
CalculationType theta, th1, c;
int i;
theta = lp_lat;
if (fabs(fabs(lp_lat) - HALFPI) < EPS)
xy_x = 0.;
else {
c = sin(theta) * ONEPI;
for (i = NITER; i; --i) {
theta -= th1 = (theta + sin(theta) - c) /
(1. + cos(theta));
if (fabs(th1) < EPS) break;
}
theta *= 0.5;
xy_x = FXC * lp_lon / (1. / cos(lp_lat) + FXC2 / cos(theta));
}
xy_y = FYC * (lp_lat + FYC2 * sin(theta));
}
static inline std::string get_name()
{
return "boggs_spheroid";
}
};
// Boggs Eumorphic
template <typename Parameters>
inline void setup_boggs(Parameters& par)
{
par.es = 0.;
}
}} // namespace detail::boggs
#endif // doxygen
/*!
\brief Boggs Eumorphic projection
\ingroup projections
\tparam Geographic latlong point type
\tparam Cartesian xy point type
\tparam Parameters parameter type
\par Projection characteristics
- Pseudocylindrical
- no inverse
- Spheroid
\par Example
\image html ex_boggs.gif
*/
template <typename CalculationType, typename Parameters>
struct boggs_spheroid : public detail::boggs::base_boggs_spheroid<CalculationType, Parameters>
{
inline boggs_spheroid(const Parameters& par) : detail::boggs::base_boggs_spheroid<CalculationType, Parameters>(par)
{
detail::boggs::setup_boggs(this->m_par);
}
};
#ifndef DOXYGEN_NO_DETAIL
namespace detail
{
// Static projection
BOOST_GEOMETRY_PROJECTIONS_DETAIL_STATIC_PROJECTION(srs::par4::boggs, boggs_spheroid, boggs_spheroid)
// Factory entry(s)
template <typename CalculationType, typename Parameters>
class boggs_entry : public detail::factory_entry<CalculationType, Parameters>
{
public :
virtual base_v<CalculationType, Parameters>* create_new(const Parameters& par) const
{
return new base_v_f<boggs_spheroid<CalculationType, Parameters>, CalculationType, Parameters>(par);
}
};
template <typename CalculationType, typename Parameters>
inline void boggs_init(detail::base_factory<CalculationType, Parameters>& factory)
{
factory.add_to_factory("boggs", new boggs_entry<CalculationType, Parameters>);
}
} // namespace detail
#endif // doxygen
} // namespace projections
}} // namespace boost::geometry
#endif // BOOST_GEOMETRY_PROJECTIONS_BOGGS_HPP

View File

@@ -0,0 +1,298 @@
#ifndef BOOST_GEOMETRY_PROJECTIONS_BONNE_HPP
#define BOOST_GEOMETRY_PROJECTIONS_BONNE_HPP
// Boost.Geometry - extensions-gis-projections (based on PROJ4)
// This file is automatically generated. DO NOT EDIT.
// Copyright (c) 2008-2015 Barend Gehrels, Amsterdam, the Netherlands.
// This file was modified by Oracle on 2017.
// Modifications copyright (c) 2017, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle.
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
// This file is converted from PROJ4, http://trac.osgeo.org/proj
// PROJ4 is originally written by Gerald Evenden (then of the USGS)
// PROJ4 is maintained by Frank Warmerdam
// PROJ4 is converted to Boost.Geometry by Barend Gehrels
// Last updated version of proj: 4.9.1
// Original copyright notice:
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the "Software"),
// to deal in the Software without restriction, including without limitation
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
// and/or sell copies of the Software, and to permit persons to whom the
// Software is furnished to do so, subject to the following conditions:
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Software.
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.
#include <boost/geometry/util/math.hpp>
#include <boost/math/special_functions/hypot.hpp>
#include <boost/geometry/srs/projections/impl/base_static.hpp>
#include <boost/geometry/srs/projections/impl/base_dynamic.hpp>
#include <boost/geometry/srs/projections/impl/projects.hpp>
#include <boost/geometry/srs/projections/impl/factory_entry.hpp>
#include <boost/geometry/srs/projections/impl/pj_mlfn.hpp>
namespace boost { namespace geometry
{
namespace srs { namespace par4
{
struct bonne {};
}} //namespace srs::par4
namespace projections
{
#ifndef DOXYGEN_NO_DETAIL
namespace detail { namespace bonne
{
static const double EPS10 = 1e-10;
template <typename T>
struct par_bonne
{
T phi1;
T cphi1;
T am1;
T m1;
T en[EN_SIZE];
};
// template class, using CRTP to implement forward/inverse
template <typename CalculationType, typename Parameters>
struct base_bonne_ellipsoid : public base_t_fi<base_bonne_ellipsoid<CalculationType, Parameters>,
CalculationType, Parameters>
{
typedef CalculationType geographic_type;
typedef CalculationType cartesian_type;
par_bonne<CalculationType> m_proj_parm;
inline base_bonne_ellipsoid(const Parameters& par)
: base_t_fi<base_bonne_ellipsoid<CalculationType, Parameters>,
CalculationType, Parameters>(*this, par) {}
// FORWARD(e_forward) ellipsoid
// Project coordinates from geographic (lon, lat) to cartesian (x, y)
inline void fwd(geographic_type& lp_lon, geographic_type& lp_lat, cartesian_type& xy_x, cartesian_type& xy_y) const
{
CalculationType rh, E, c;
rh = this->m_proj_parm.am1 + this->m_proj_parm.m1 - pj_mlfn(lp_lat, E = sin(lp_lat), c = cos(lp_lat), this->m_proj_parm.en);
E = c * lp_lon / (rh * sqrt(1. - this->m_par.es * E * E));
xy_x = rh * sin(E);
xy_y = this->m_proj_parm.am1 - rh * cos(E);
}
// INVERSE(e_inverse) ellipsoid
// Project coordinates from cartesian (x, y) to geographic (lon, lat)
inline void inv(cartesian_type& xy_x, cartesian_type& xy_y, geographic_type& lp_lon, geographic_type& lp_lat) const
{
static const CalculationType HALFPI = detail::HALFPI<CalculationType>();
CalculationType s, rh;
rh = boost::math::hypot(xy_x, xy_y = this->m_proj_parm.am1 - xy_y);
lp_lat = pj_inv_mlfn(this->m_proj_parm.am1 + this->m_proj_parm.m1 - rh, this->m_par.es, this->m_proj_parm.en);
if ((s = fabs(lp_lat)) < HALFPI) {
s = sin(lp_lat);
lp_lon = rh * atan2(xy_x, xy_y) *
sqrt(1. - this->m_par.es * s * s) / cos(lp_lat);
} else if (fabs(s - HALFPI) <= EPS10)
lp_lon = 0.;
else
BOOST_THROW_EXCEPTION( projection_exception(-20) );
}
static inline std::string get_name()
{
return "bonne_ellipsoid";
}
};
// template class, using CRTP to implement forward/inverse
template <typename CalculationType, typename Parameters>
struct base_bonne_spheroid : public base_t_fi<base_bonne_spheroid<CalculationType, Parameters>,
CalculationType, Parameters>
{
typedef CalculationType geographic_type;
typedef CalculationType cartesian_type;
par_bonne<CalculationType> m_proj_parm;
inline base_bonne_spheroid(const Parameters& par)
: base_t_fi<base_bonne_spheroid<CalculationType, Parameters>,
CalculationType, Parameters>(*this, par) {}
// FORWARD(s_forward) spheroid
// Project coordinates from geographic (lon, lat) to cartesian (x, y)
inline void fwd(geographic_type& lp_lon, geographic_type& lp_lat, cartesian_type& xy_x, cartesian_type& xy_y) const
{
CalculationType E, rh;
rh = this->m_proj_parm.cphi1 + this->m_proj_parm.phi1 - lp_lat;
if (fabs(rh) > EPS10) {
xy_x = rh * sin(E = lp_lon * cos(lp_lat) / rh);
xy_y = this->m_proj_parm.cphi1 - rh * cos(E);
} else
xy_x = xy_y = 0.;
}
// INVERSE(s_inverse) spheroid
// Project coordinates from cartesian (x, y) to geographic (lon, lat)
inline void inv(cartesian_type& xy_x, cartesian_type& xy_y, geographic_type& lp_lon, geographic_type& lp_lat) const
{
static const CalculationType HALFPI = detail::HALFPI<CalculationType>();
CalculationType rh;
rh = boost::math::hypot(xy_x, xy_y = this->m_proj_parm.cphi1 - xy_y);
lp_lat = this->m_proj_parm.cphi1 + this->m_proj_parm.phi1 - rh;
if (fabs(lp_lat) > HALFPI)
BOOST_THROW_EXCEPTION( projection_exception(-20) );
if (fabs(fabs(lp_lat) - HALFPI) <= EPS10)
lp_lon = 0.;
else
lp_lon = rh * atan2(xy_x, xy_y) / cos(lp_lat);
}
static inline std::string get_name()
{
return "bonne_spheroid";
}
};
// Bonne (Werner lat_1=90)
template <typename Parameters, typename T>
inline void setup_bonne(Parameters& par, par_bonne<T>& proj_parm)
{
static const T HALFPI = detail::HALFPI<T>();
T c;
proj_parm.phi1 = pj_param(par.params, "rlat_1").f;
if (fabs(proj_parm.phi1) < EPS10)
BOOST_THROW_EXCEPTION( projection_exception(-23) );
if (par.es) {
pj_enfn(par.es, proj_parm.en);
proj_parm.m1 = pj_mlfn(proj_parm.phi1, proj_parm.am1 = sin(proj_parm.phi1),
c = cos(proj_parm.phi1), proj_parm.en);
proj_parm.am1 = c / (sqrt(1. - par.es * proj_parm.am1 * proj_parm.am1) * proj_parm.am1);
} else {
if (fabs(proj_parm.phi1) + EPS10 >= HALFPI)
proj_parm.cphi1 = 0.;
else
proj_parm.cphi1 = 1. / tan(proj_parm.phi1);
}
}
}} // namespace detail::bonne
#endif // doxygen
/*!
\brief Bonne (Werner lat_1=90) projection
\ingroup projections
\tparam Geographic latlong point type
\tparam Cartesian xy point type
\tparam Parameters parameter type
\par Projection characteristics
- Conic
- Spheroid
- Ellipsoid
\par Projection parameters
- lat_1: Latitude of first standard parallel (degrees)
\par Example
\image html ex_bonne.gif
*/
template <typename CalculationType, typename Parameters>
struct bonne_ellipsoid : public detail::bonne::base_bonne_ellipsoid<CalculationType, Parameters>
{
inline bonne_ellipsoid(const Parameters& par) : detail::bonne::base_bonne_ellipsoid<CalculationType, Parameters>(par)
{
detail::bonne::setup_bonne(this->m_par, this->m_proj_parm);
}
};
/*!
\brief Bonne (Werner lat_1=90) projection
\ingroup projections
\tparam Geographic latlong point type
\tparam Cartesian xy point type
\tparam Parameters parameter type
\par Projection characteristics
- Conic
- Spheroid
- Ellipsoid
\par Projection parameters
- lat_1: Latitude of first standard parallel (degrees)
\par Example
\image html ex_bonne.gif
*/
template <typename CalculationType, typename Parameters>
struct bonne_spheroid : public detail::bonne::base_bonne_spheroid<CalculationType, Parameters>
{
inline bonne_spheroid(const Parameters& par) : detail::bonne::base_bonne_spheroid<CalculationType, Parameters>(par)
{
detail::bonne::setup_bonne(this->m_par, this->m_proj_parm);
}
};
#ifndef DOXYGEN_NO_DETAIL
namespace detail
{
// Static projection
BOOST_GEOMETRY_PROJECTIONS_DETAIL_STATIC_PROJECTION(srs::par4::bonne, bonne_spheroid, bonne_ellipsoid)
// Factory entry(s)
template <typename CalculationType, typename Parameters>
class bonne_entry : public detail::factory_entry<CalculationType, Parameters>
{
public :
virtual base_v<CalculationType, Parameters>* create_new(const Parameters& par) const
{
if (par.es)
return new base_v_fi<bonne_ellipsoid<CalculationType, Parameters>, CalculationType, Parameters>(par);
else
return new base_v_fi<bonne_spheroid<CalculationType, Parameters>, CalculationType, Parameters>(par);
}
};
template <typename CalculationType, typename Parameters>
inline void bonne_init(detail::base_factory<CalculationType, Parameters>& factory)
{
factory.add_to_factory("bonne", new bonne_entry<CalculationType, Parameters>);
}
} // namespace detail
#endif // doxygen
} // namespace projections
}} // namespace boost::geometry
#endif // BOOST_GEOMETRY_PROJECTIONS_BONNE_HPP

View File

@@ -0,0 +1,292 @@
#ifndef BOOST_GEOMETRY_PROJECTIONS_CASS_HPP
#define BOOST_GEOMETRY_PROJECTIONS_CASS_HPP
// Boost.Geometry - extensions-gis-projections (based on PROJ4)
// This file is automatically generated. DO NOT EDIT.
// Copyright (c) 2008-2015 Barend Gehrels, Amsterdam, the Netherlands.
// This file was modified by Oracle on 2017.
// Modifications copyright (c) 2017, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle.
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
// This file is converted from PROJ4, http://trac.osgeo.org/proj
// PROJ4 is originally written by Gerald Evenden (then of the USGS)
// PROJ4 is maintained by Frank Warmerdam
// PROJ4 is converted to Boost.Geometry by Barend Gehrels
// Last updated version of proj: 4.9.1
// Original copyright notice:
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the "Software"),
// to deal in the Software without restriction, including without limitation
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
// and/or sell copies of the Software, and to permit persons to whom the
// Software is furnished to do so, subject to the following conditions:
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Software.
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.
#include <boost/geometry/srs/projections/impl/base_static.hpp>
#include <boost/geometry/srs/projections/impl/base_dynamic.hpp>
#include <boost/geometry/srs/projections/impl/projects.hpp>
#include <boost/geometry/srs/projections/impl/factory_entry.hpp>
#include <boost/geometry/srs/projections/impl/pj_mlfn.hpp>
namespace boost { namespace geometry
{
namespace srs { namespace par4
{
struct cass {};
}} //namespace srs::par4
namespace projections
{
#ifndef DOXYGEN_NO_DETAIL
namespace detail { namespace cass
{
//static const double EPS10 = 1e-10;
//static const double C1 = .16666666666666666666;
//static const double C2 = .00833333333333333333;
//static const double C3 = .04166666666666666666;
//static const double C4 = .33333333333333333333;
//static const double C5 = .06666666666666666666;
template <typename T>
inline T C1() { return .16666666666666666666666666666666666666; }
template <typename T>
inline T C2() { return .00833333333333333333333333333333333333; }
template <typename T>
inline T C3() { return .04166666666666666666666666666666666666; }
template <typename T>
inline T C4() { return .33333333333333333333333333333333333333; }
template <typename T>
inline T C5() { return .06666666666666666666666666666666666666; }
template <typename T>
struct par_cass
{
T m0;
T en[EN_SIZE];
};
// template class, using CRTP to implement forward/inverse
template <typename CalculationType, typename Parameters>
struct base_cass_ellipsoid : public base_t_fi<base_cass_ellipsoid<CalculationType, Parameters>,
CalculationType, Parameters>
{
typedef CalculationType geographic_type;
typedef CalculationType cartesian_type;
par_cass<CalculationType> m_proj_parm;
inline base_cass_ellipsoid(const Parameters& par)
: base_t_fi<base_cass_ellipsoid<CalculationType, Parameters>,
CalculationType, Parameters>(*this, par) {}
// FORWARD(e_forward) ellipsoid
// Project coordinates from geographic (lon, lat) to cartesian (x, y)
inline void fwd(geographic_type& lp_lon, geographic_type& lp_lat, cartesian_type& xy_x, cartesian_type& xy_y) const
{
static const CalculationType C1 = cass::C1<CalculationType>();
static const CalculationType C2 = cass::C2<CalculationType>();
static const CalculationType C3 = cass::C3<CalculationType>();
CalculationType n = sin(lp_lat);
CalculationType c = cos(lp_lat);
xy_y = pj_mlfn(lp_lat, n, c, this->m_proj_parm.en);
n = 1./sqrt(1. - this->m_par.es * n * n);
CalculationType tn = tan(lp_lat); CalculationType t = tn * tn;
CalculationType a1 = lp_lon * c;
c *= this->m_par.es * c / (1 - this->m_par.es);
CalculationType a2 = a1 * a1;
xy_x = n * a1 * (1. - a2 * t *
(C1 - (8. - t + 8. * c) * a2 * C2));
xy_y -= this->m_proj_parm.m0 - n * tn * a2 *
(.5 + (5. - t + 6. * c) * a2 * C3);
}
// INVERSE(e_inverse) ellipsoid
// Project coordinates from cartesian (x, y) to geographic (lon, lat)
inline void inv(cartesian_type& xy_x, cartesian_type& xy_y, geographic_type& lp_lon, geographic_type& lp_lat) const
{
static const CalculationType C3 = cass::C3<CalculationType>();
static const CalculationType C4 = cass::C4<CalculationType>();
static const CalculationType C5 = cass::C5<CalculationType>();
CalculationType ph1;
ph1 = pj_inv_mlfn(this->m_proj_parm.m0 + xy_y, this->m_par.es, this->m_proj_parm.en);
CalculationType tn = tan(ph1); CalculationType t = tn * tn;
CalculationType n = sin(ph1);
CalculationType r = 1. / (1. - this->m_par.es * n * n);
n = sqrt(r);
r *= (1. - this->m_par.es) * n;
CalculationType dd = xy_x / n;
CalculationType d2 = dd * dd;
lp_lat = ph1 - (n * tn / r) * d2 *
(.5 - (1. + 3. * t) * d2 * C3);
lp_lon = dd * (1. + t * d2 *
(-C4 + (1. + 3. * t) * d2 * C5)) / cos(ph1);
}
static inline std::string get_name()
{
return "cass_ellipsoid";
}
};
// template class, using CRTP to implement forward/inverse
template <typename CalculationType, typename Parameters>
struct base_cass_spheroid : public base_t_fi<base_cass_spheroid<CalculationType, Parameters>,
CalculationType, Parameters>
{
typedef CalculationType geographic_type;
typedef CalculationType cartesian_type;
par_cass<CalculationType> m_proj_parm;
inline base_cass_spheroid(const Parameters& par)
: base_t_fi<base_cass_spheroid<CalculationType, Parameters>,
CalculationType, Parameters>(*this, par) {}
// FORWARD(s_forward) spheroid
// Project coordinates from geographic (lon, lat) to cartesian (x, y)
inline void fwd(geographic_type& lp_lon, geographic_type& lp_lat, cartesian_type& xy_x, cartesian_type& xy_y) const
{
xy_x = asin(cos(lp_lat) * sin(lp_lon));
xy_y = atan2(tan(lp_lat) , cos(lp_lon)) - this->m_par.phi0;
}
// INVERSE(s_inverse) spheroid
// Project coordinates from cartesian (x, y) to geographic (lon, lat)
inline void inv(cartesian_type& xy_x, cartesian_type& xy_y, geographic_type& lp_lon, geographic_type& lp_lat) const
{
CalculationType dd = xy_y + this->m_par.phi0;
lp_lat = asin(sin(dd) * cos(xy_x));
lp_lon = atan2(tan(xy_x), cos(dd));
}
static inline std::string get_name()
{
return "cass_spheroid";
}
};
// Cassini
template <typename Parameters, typename T>
inline void setup_cass(Parameters& par, par_cass<T>& proj_parm)
{
if (par.es) {
if (!pj_enfn(par.es, proj_parm.en))
BOOST_THROW_EXCEPTION( projection_exception(0) );
proj_parm.m0 = pj_mlfn(par.phi0, sin(par.phi0), cos(par.phi0), proj_parm.en);
} else {
}
}
}} // namespace detail::cass
#endif // doxygen
/*!
\brief Cassini projection
\ingroup projections
\tparam Geographic latlong point type
\tparam Cartesian xy point type
\tparam Parameters parameter type
\par Projection characteristics
- Cylindrical
- Spheroid
- Ellipsoid
\par Example
\image html ex_cass.gif
*/
template <typename CalculationType, typename Parameters>
struct cass_ellipsoid : public detail::cass::base_cass_ellipsoid<CalculationType, Parameters>
{
inline cass_ellipsoid(const Parameters& par) : detail::cass::base_cass_ellipsoid<CalculationType, Parameters>(par)
{
detail::cass::setup_cass(this->m_par, this->m_proj_parm);
}
};
/*!
\brief Cassini projection
\ingroup projections
\tparam Geographic latlong point type
\tparam Cartesian xy point type
\tparam Parameters parameter type
\par Projection characteristics
- Cylindrical
- Spheroid
- Ellipsoid
\par Example
\image html ex_cass.gif
*/
template <typename CalculationType, typename Parameters>
struct cass_spheroid : public detail::cass::base_cass_spheroid<CalculationType, Parameters>
{
inline cass_spheroid(const Parameters& par) : detail::cass::base_cass_spheroid<CalculationType, Parameters>(par)
{
detail::cass::setup_cass(this->m_par, this->m_proj_parm);
}
};
#ifndef DOXYGEN_NO_DETAIL
namespace detail
{
// Static projection
BOOST_GEOMETRY_PROJECTIONS_DETAIL_STATIC_PROJECTION(srs::par4::cass, cass_spheroid, cass_ellipsoid)
// Factory entry(s)
template <typename CalculationType, typename Parameters>
class cass_entry : public detail::factory_entry<CalculationType, Parameters>
{
public :
virtual base_v<CalculationType, Parameters>* create_new(const Parameters& par) const
{
if (par.es)
return new base_v_fi<cass_ellipsoid<CalculationType, Parameters>, CalculationType, Parameters>(par);
else
return new base_v_fi<cass_spheroid<CalculationType, Parameters>, CalculationType, Parameters>(par);
}
};
template <typename CalculationType, typename Parameters>
inline void cass_init(detail::base_factory<CalculationType, Parameters>& factory)
{
factory.add_to_factory("cass", new cass_entry<CalculationType, Parameters>);
}
} // namespace detail
#endif // doxygen
} // namespace projections
}} // namespace boost::geometry
#endif // BOOST_GEOMETRY_PROJECTIONS_CASS_HPP

View File

@@ -0,0 +1,171 @@
#ifndef BOOST_GEOMETRY_PROJECTIONS_CC_HPP
#define BOOST_GEOMETRY_PROJECTIONS_CC_HPP
// Boost.Geometry - extensions-gis-projections (based on PROJ4)
// This file is automatically generated. DO NOT EDIT.
// Copyright (c) 2008-2015 Barend Gehrels, Amsterdam, the Netherlands.
// This file was modified by Oracle on 2017, 2018.
// Modifications copyright (c) 2017-2018, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle.
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
// This file is converted from PROJ4, http://trac.osgeo.org/proj
// PROJ4 is originally written by Gerald Evenden (then of the USGS)
// PROJ4 is maintained by Frank Warmerdam
// PROJ4 is converted to Boost.Geometry by Barend Gehrels
// Last updated version of proj: 4.9.1
// Original copyright notice:
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the "Software"),
// to deal in the Software without restriction, including without limitation
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
// and/or sell copies of the Software, and to permit persons to whom the
// Software is furnished to do so, subject to the following conditions:
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Software.
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.
#include <boost/geometry/util/math.hpp>
#include <boost/geometry/srs/projections/impl/base_static.hpp>
#include <boost/geometry/srs/projections/impl/base_dynamic.hpp>
#include <boost/geometry/srs/projections/impl/projects.hpp>
#include <boost/geometry/srs/projections/impl/factory_entry.hpp>
namespace boost { namespace geometry
{
namespace srs { namespace par4
{
struct cc {};
}} //namespace srs::par4
namespace projections
{
#ifndef DOXYGEN_NO_DETAIL
namespace detail { namespace cc
{
static const double EPS10 = 1.e-10;
// template class, using CRTP to implement forward/inverse
template <typename CalculationType, typename Parameters>
struct base_cc_spheroid : public base_t_fi<base_cc_spheroid<CalculationType, Parameters>,
CalculationType, Parameters>
{
typedef CalculationType geographic_type;
typedef CalculationType cartesian_type;
inline base_cc_spheroid(const Parameters& par)
: base_t_fi<base_cc_spheroid<CalculationType, Parameters>,
CalculationType, Parameters>(*this, par) {}
// FORWARD(s_forward) spheroid
// Project coordinates from geographic (lon, lat) to cartesian (x, y)
inline void fwd(geographic_type& lp_lon, geographic_type& lp_lat, cartesian_type& xy_x, cartesian_type& xy_y) const
{
static const CalculationType HALFPI = detail::HALFPI<CalculationType>();
if (fabs(fabs(lp_lat) - HALFPI) <= EPS10)
BOOST_THROW_EXCEPTION( projection_exception(-20) );
xy_x = lp_lon;
xy_y = tan(lp_lat);
}
// INVERSE(s_inverse) spheroid
// Project coordinates from cartesian (x, y) to geographic (lon, lat)
inline void inv(cartesian_type& xy_x, cartesian_type& xy_y, geographic_type& lp_lon, geographic_type& lp_lat) const
{
lp_lat = atan(xy_y);
lp_lon = xy_x;
}
static inline std::string get_name()
{
return "cc_spheroid";
}
};
// Central Cylindrical
template <typename Parameters>
inline void setup_cc(Parameters& par)
{
par.es = 0.;
}
}} // namespace detail::cc
#endif // doxygen
/*!
\brief Central Cylindrical projection
\ingroup projections
\tparam Geographic latlong point type
\tparam Cartesian xy point type
\tparam Parameters parameter type
\par Projection characteristics
- Cylindrical
- Spheroid
\par Example
\image html ex_cc.gif
*/
template <typename CalculationType, typename Parameters>
struct cc_spheroid : public detail::cc::base_cc_spheroid<CalculationType, Parameters>
{
inline cc_spheroid(const Parameters& par) : detail::cc::base_cc_spheroid<CalculationType, Parameters>(par)
{
detail::cc::setup_cc(this->m_par);
}
};
#ifndef DOXYGEN_NO_DETAIL
namespace detail
{
// Static projection
BOOST_GEOMETRY_PROJECTIONS_DETAIL_STATIC_PROJECTION(srs::par4::cc, cc_spheroid, cc_spheroid)
// Factory entry(s)
template <typename CalculationType, typename Parameters>
class cc_entry : public detail::factory_entry<CalculationType, Parameters>
{
public :
virtual base_v<CalculationType, Parameters>* create_new(const Parameters& par) const
{
return new base_v_fi<cc_spheroid<CalculationType, Parameters>, CalculationType, Parameters>(par);
}
};
template <typename CalculationType, typename Parameters>
inline void cc_init(detail::base_factory<CalculationType, Parameters>& factory)
{
factory.add_to_factory("cc", new cc_entry<CalculationType, Parameters>);
}
} // namespace detail
#endif // doxygen
} // namespace projections
}} // namespace boost::geometry
#endif // BOOST_GEOMETRY_PROJECTIONS_CC_HPP

View File

@@ -0,0 +1,269 @@
#ifndef BOOST_GEOMETRY_PROJECTIONS_CEA_HPP
#define BOOST_GEOMETRY_PROJECTIONS_CEA_HPP
// Boost.Geometry - extensions-gis-projections (based on PROJ4)
// This file is automatically generated. DO NOT EDIT.
// Copyright (c) 2008-2015 Barend Gehrels, Amsterdam, the Netherlands.
// This file was modified by Oracle on 2017.
// Modifications copyright (c) 2017, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle.
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
// This file is converted from PROJ4, http://trac.osgeo.org/proj
// PROJ4 is originally written by Gerald Evenden (then of the USGS)
// PROJ4 is maintained by Frank Warmerdam
// PROJ4 is converted to Boost.Geometry by Barend Gehrels
// Last updated version of proj: 4.9.1
// Original copyright notice:
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the "Software"),
// to deal in the Software without restriction, including without limitation
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
// and/or sell copies of the Software, and to permit persons to whom the
// Software is furnished to do so, subject to the following conditions:
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Software.
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.
#include <boost/geometry/util/math.hpp>
#include <boost/geometry/srs/projections/impl/base_static.hpp>
#include <boost/geometry/srs/projections/impl/base_dynamic.hpp>
#include <boost/geometry/srs/projections/impl/projects.hpp>
#include <boost/geometry/srs/projections/impl/factory_entry.hpp>
#include <boost/geometry/srs/projections/impl/pj_auth.hpp>
#include <boost/geometry/srs/projections/impl/pj_qsfn.hpp>
namespace boost { namespace geometry
{
namespace srs { namespace par4
{
struct cea {};
}} //namespace srs::par4
namespace projections
{
#ifndef DOXYGEN_NO_DETAIL
namespace detail { namespace cea
{
static const double EPS = 1e-10;
template <typename T>
struct par_cea
{
T qp;
T apa[APA_SIZE];
};
// template class, using CRTP to implement forward/inverse
template <typename CalculationType, typename Parameters>
struct base_cea_ellipsoid : public base_t_fi<base_cea_ellipsoid<CalculationType, Parameters>,
CalculationType, Parameters>
{
typedef CalculationType geographic_type;
typedef CalculationType cartesian_type;
par_cea<CalculationType> m_proj_parm;
inline base_cea_ellipsoid(const Parameters& par)
: base_t_fi<base_cea_ellipsoid<CalculationType, Parameters>,
CalculationType, Parameters>(*this, par) {}
// FORWARD(e_forward) spheroid
// Project coordinates from geographic (lon, lat) to cartesian (x, y)
inline void fwd(geographic_type& lp_lon, geographic_type& lp_lat, cartesian_type& xy_x, cartesian_type& xy_y) const
{
xy_x = this->m_par.k0 * lp_lon;
xy_y = .5 * pj_qsfn(sin(lp_lat), this->m_par.e, this->m_par.one_es) / this->m_par.k0;
}
// INVERSE(e_inverse) spheroid
// Project coordinates from cartesian (x, y) to geographic (lon, lat)
inline void inv(cartesian_type& xy_x, cartesian_type& xy_y, geographic_type& lp_lon, geographic_type& lp_lat) const
{
lp_lat = pj_authlat(asin( 2. * xy_y * this->m_par.k0 / this->m_proj_parm.qp), this->m_proj_parm.apa);
lp_lon = xy_x / this->m_par.k0;
}
static inline std::string get_name()
{
return "cea_ellipsoid";
}
};
// template class, using CRTP to implement forward/inverse
template <typename CalculationType, typename Parameters>
struct base_cea_spheroid : public base_t_fi<base_cea_spheroid<CalculationType, Parameters>,
CalculationType, Parameters>
{
typedef CalculationType geographic_type;
typedef CalculationType cartesian_type;
par_cea<CalculationType> m_proj_parm;
inline base_cea_spheroid(const Parameters& par)
: base_t_fi<base_cea_spheroid<CalculationType, Parameters>,
CalculationType, Parameters>(*this, par) {}
// FORWARD(s_forward) spheroid
// Project coordinates from geographic (lon, lat) to cartesian (x, y)
inline void fwd(geographic_type& lp_lon, geographic_type& lp_lat, cartesian_type& xy_x, cartesian_type& xy_y) const
{
xy_x = this->m_par.k0 * lp_lon;
xy_y = sin(lp_lat) / this->m_par.k0;
}
// INVERSE(s_inverse) spheroid
// Project coordinates from cartesian (x, y) to geographic (lon, lat)
inline void inv(cartesian_type& xy_x, cartesian_type& xy_y, geographic_type& lp_lon, geographic_type& lp_lat) const
{
static const CalculationType HALFPI = detail::HALFPI<CalculationType>();
CalculationType t;
if ((t = fabs(xy_y *= this->m_par.k0)) - EPS <= 1.) {
if (t >= 1.)
lp_lat = xy_y < 0. ? -HALFPI : HALFPI;
else
lp_lat = asin(xy_y);
lp_lon = xy_x / this->m_par.k0;
} else
BOOST_THROW_EXCEPTION( projection_exception(-20) );
}
static inline std::string get_name()
{
return "cea_spheroid";
}
};
// Equal Area Cylindrical
template <typename Parameters, typename T>
inline void setup_cea(Parameters& par, par_cea<T>& proj_parm)
{
T t = 0;
if (pj_param(par.params, "tlat_ts").i &&
(par.k0 = cos(t = pj_param(par.params, "rlat_ts").f)) < 0.)
BOOST_THROW_EXCEPTION( projection_exception(-24) );
if (par.es) {
t = sin(t);
par.k0 /= sqrt(1. - par.es * t * t);
par.e = sqrt(par.es);
if (!pj_authset(par.es, proj_parm.apa))
BOOST_THROW_EXCEPTION( projection_exception(0) );
proj_parm.qp = pj_qsfn(1., par.e, par.one_es);
} else {
}
}
}} // namespace detail::cea
#endif // doxygen
/*!
\brief Equal Area Cylindrical projection
\ingroup projections
\tparam Geographic latlong point type
\tparam Cartesian xy point type
\tparam Parameters parameter type
\par Projection characteristics
- Cylindrical
- Spheroid
- Ellipsoid
\par Projection parameters
- lat_ts: Latitude of true scale (degrees)
\par Example
\image html ex_cea.gif
*/
template <typename CalculationType, typename Parameters>
struct cea_ellipsoid : public detail::cea::base_cea_ellipsoid<CalculationType, Parameters>
{
inline cea_ellipsoid(const Parameters& par) : detail::cea::base_cea_ellipsoid<CalculationType, Parameters>(par)
{
detail::cea::setup_cea(this->m_par, this->m_proj_parm);
}
};
/*!
\brief Equal Area Cylindrical projection
\ingroup projections
\tparam Geographic latlong point type
\tparam Cartesian xy point type
\tparam Parameters parameter type
\par Projection characteristics
- Cylindrical
- Spheroid
- Ellipsoid
\par Projection parameters
- lat_ts: Latitude of true scale (degrees)
\par Example
\image html ex_cea.gif
*/
template <typename CalculationType, typename Parameters>
struct cea_spheroid : public detail::cea::base_cea_spheroid<CalculationType, Parameters>
{
inline cea_spheroid(const Parameters& par) : detail::cea::base_cea_spheroid<CalculationType, Parameters>(par)
{
detail::cea::setup_cea(this->m_par, this->m_proj_parm);
}
};
#ifndef DOXYGEN_NO_DETAIL
namespace detail
{
// Static projection
BOOST_GEOMETRY_PROJECTIONS_DETAIL_STATIC_PROJECTION(srs::par4::cea, cea_spheroid, cea_ellipsoid)
// Factory entry(s)
template <typename CalculationType, typename Parameters>
class cea_entry : public detail::factory_entry<CalculationType, Parameters>
{
public :
virtual base_v<CalculationType, Parameters>* create_new(const Parameters& par) const
{
if (par.es)
return new base_v_fi<cea_ellipsoid<CalculationType, Parameters>, CalculationType, Parameters>(par);
else
return new base_v_fi<cea_spheroid<CalculationType, Parameters>, CalculationType, Parameters>(par);
}
};
template <typename CalculationType, typename Parameters>
inline void cea_init(detail::base_factory<CalculationType, Parameters>& factory)
{
factory.add_to_factory("cea", new cea_entry<CalculationType, Parameters>);
}
} // namespace detail
#endif // doxygen
} // namespace projections
}} // namespace boost::geometry
#endif // BOOST_GEOMETRY_PROJECTIONS_CEA_HPP

View File

@@ -0,0 +1,288 @@
#ifndef BOOST_GEOMETRY_PROJECTIONS_CHAMB_HPP
#define BOOST_GEOMETRY_PROJECTIONS_CHAMB_HPP
// Boost.Geometry - extensions-gis-projections (based on PROJ4)
// This file is automatically generated. DO NOT EDIT.
// Copyright (c) 2008-2015 Barend Gehrels, Amsterdam, the Netherlands.
// This file was modified by Oracle on 2017.
// Modifications copyright (c) 2017, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle.
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
// This file is converted from PROJ4, http://trac.osgeo.org/proj
// PROJ4 is originally written by Gerald Evenden (then of the USGS)
// PROJ4 is maintained by Frank Warmerdam
// PROJ4 is converted to Boost.Geometry by Barend Gehrels
// Last updated version of proj: 4.9.1
// Original copyright notice:
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the "Software"),
// to deal in the Software without restriction, including without limitation
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
// and/or sell copies of the Software, and to permit persons to whom the
// Software is furnished to do so, subject to the following conditions:
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Software.
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.
#include <boost/geometry/util/math.hpp>
#include <cstdio>
#include <boost/geometry/srs/projections/impl/base_static.hpp>
#include <boost/geometry/srs/projections/impl/base_dynamic.hpp>
#include <boost/geometry/srs/projections/impl/projects.hpp>
#include <boost/geometry/srs/projections/impl/factory_entry.hpp>
#include <boost/geometry/srs/projections/impl/aasincos.hpp>
namespace boost { namespace geometry
{
namespace srs { namespace par4
{
struct chamb {};
}} //namespace srs::par4
namespace projections
{
#ifndef DOXYGEN_NO_DETAIL
namespace detail { namespace chamb
{
//static const double THIRD = 0.333333333333333333;
static const double TOL = 1e-9;
// specific for 'chamb'
template <typename T>
struct VECT { T r, Az; };
template <typename T>
struct XY { T x, y; };
template <typename T>
struct par_chamb
{
struct { /* control point data */
T phi, lam;
T cosphi, sinphi;
VECT<T> v;
XY<T> p;
T Az;
} c[3];
XY<T> p;
T beta_0, beta_1, beta_2;
};
template <typename T>
inline VECT<T> /* distance and azimuth from point 1 to point 2 */
vect(T const& dphi, T const& c1, T const& s1, T const& c2, T const& s2, T const& dlam)
{
VECT<T> v;
T cdl, dp, dl;
cdl = cos(dlam);
if (fabs(dphi) > 1. || fabs(dlam) > 1.)
v.r = aacos(s1 * s2 + c1 * c2 * cdl);
else { /* more accurate for smaller distances */
dp = sin(.5 * dphi);
dl = sin(.5 * dlam);
v.r = 2. * aasin(sqrt(dp * dp + c1 * c2 * dl * dl));
}
if (fabs(v.r) > TOL)
v.Az = atan2(c2 * sin(dlam), c1 * s2 - s1 * c2 * cdl);
else
v.r = v.Az = 0.;
return v;
}
template <typename T>
inline T /* law of cosines */
lc(T const& b, T const& c, T const& a)
{
return aacos(.5 * (b * b + c * c - a * a) / (b * c));
}
// template class, using CRTP to implement forward/inverse
template <typename CalculationType, typename Parameters>
struct base_chamb_spheroid : public base_t_f<base_chamb_spheroid<CalculationType, Parameters>,
CalculationType, Parameters>
{
typedef CalculationType geographic_type;
typedef CalculationType cartesian_type;
par_chamb<CalculationType> m_proj_parm;
inline base_chamb_spheroid(const Parameters& par)
: base_t_f<base_chamb_spheroid<CalculationType, Parameters>,
CalculationType, Parameters>(*this, par) {}
// FORWARD(s_forward) spheroid
// Project coordinates from geographic (lon, lat) to cartesian (x, y)
inline void fwd(geographic_type& lp_lon, geographic_type& lp_lat, cartesian_type& xy_x, cartesian_type& xy_y) const
{
static const CalculationType THIRD = detail::THIRD<CalculationType>();
CalculationType sinphi, cosphi, a;
VECT<CalculationType> v[3];
int i, j;
sinphi = sin(lp_lat);
cosphi = cos(lp_lat);
for (i = 0; i < 3; ++i) { /* dist/azimiths from control */
v[i] = vect(lp_lat - this->m_proj_parm.c[i].phi, this->m_proj_parm.c[i].cosphi, this->m_proj_parm.c[i].sinphi,
cosphi, sinphi, lp_lon - this->m_proj_parm.c[i].lam);
if ( ! v[i].r)
break;
v[i].Az = adjlon(v[i].Az - this->m_proj_parm.c[i].v.Az);
}
if (i < 3) /* current point at control point */
{ xy_x = this->m_proj_parm.c[i].p.x; xy_y = this->m_proj_parm.c[i].p.y; }
else { /* point mean of intersepts */
{ xy_x = this->m_proj_parm.p.x; xy_y = this->m_proj_parm.p.y; }
for (i = 0; i < 3; ++i) {
j = i == 2 ? 0 : i + 1;
a = lc(this->m_proj_parm.c[i].v.r, v[i].r, v[j].r);
if (v[i].Az < 0.)
a = -a;
if (! i) { /* coord comp unique to each arc */
xy_x += v[i].r * cos(a);
xy_y -= v[i].r * sin(a);
} else if (i == 1) {
a = this->m_proj_parm.beta_1 - a;
xy_x -= v[i].r * cos(a);
xy_y -= v[i].r * sin(a);
} else {
a = this->m_proj_parm.beta_2 - a;
xy_x += v[i].r * cos(a);
xy_y += v[i].r * sin(a);
}
}
xy_x *= THIRD; /* mean of arc intercepts */
xy_y *= THIRD;
}
}
static inline std::string get_name()
{
return "chamb_spheroid";
}
};
// Chamberlin Trimetric
template <typename Parameters, typename T>
inline void setup_chamb(Parameters& par, par_chamb<T>& proj_parm)
{
static const T ONEPI = detail::ONEPI<T>();
int i, j;
char line[10];
for (i = 0; i < 3; ++i) { /* get control point locations */
(void)sprintf(line, "rlat_%d", i+1);
proj_parm.c[i].phi = pj_param(par.params, line).f;
(void)sprintf(line, "rlon_%d", i+1);
proj_parm.c[i].lam = pj_param(par.params, line).f;
proj_parm.c[i].lam = adjlon(proj_parm.c[i].lam - par.lam0);
proj_parm.c[i].cosphi = cos(proj_parm.c[i].phi);
proj_parm.c[i].sinphi = sin(proj_parm.c[i].phi);
}
for (i = 0; i < 3; ++i) { /* inter ctl pt. distances and azimuths */
j = i == 2 ? 0 : i + 1;
proj_parm.c[i].v = vect(proj_parm.c[j].phi - proj_parm.c[i].phi, proj_parm.c[i].cosphi, proj_parm.c[i].sinphi,
proj_parm.c[j].cosphi, proj_parm.c[j].sinphi, proj_parm.c[j].lam - proj_parm.c[i].lam);
if (! proj_parm.c[i].v.r)
BOOST_THROW_EXCEPTION( projection_exception(-25) );
/* co-linearity problem ignored for now */
}
proj_parm.beta_0 = lc(proj_parm.c[0].v.r, proj_parm.c[2].v.r, proj_parm.c[1].v.r);
proj_parm.beta_1 = lc(proj_parm.c[0].v.r, proj_parm.c[1].v.r, proj_parm.c[2].v.r);
proj_parm.beta_2 = ONEPI - proj_parm.beta_0;
proj_parm.p.y = 2. * (proj_parm.c[0].p.y = proj_parm.c[1].p.y = proj_parm.c[2].v.r * sin(proj_parm.beta_0));
proj_parm.c[2].p.y = 0.;
proj_parm.c[0].p.x = - (proj_parm.c[1].p.x = 0.5 * proj_parm.c[0].v.r);
proj_parm.p.x = proj_parm.c[2].p.x = proj_parm.c[0].p.x + proj_parm.c[2].v.r * cos(proj_parm.beta_0);
par.es = 0.;
}
}} // namespace detail::chamb
#endif // doxygen
/*!
\brief Chamberlin Trimetric projection
\ingroup projections
\tparam Geographic latlong point type
\tparam Cartesian xy point type
\tparam Parameters parameter type
\par Projection characteristics
- Miscellaneous
- Spheroid
- no inverse
\par Projection parameters
- lat_1: Latitude of control point 1 (degrees)
- lon_1: Longitude of control point 1 (degrees)
- lat_2: Latitude of control point 2 (degrees)
- lon_2: Longitude of control point 2 (degrees)
- lat_3: Latitude of control point 3 (degrees)
- lon_3: Longitude of control point 3 (degrees)
\par Example
\image html ex_chamb.gif
*/
template <typename CalculationType, typename Parameters>
struct chamb_spheroid : public detail::chamb::base_chamb_spheroid<CalculationType, Parameters>
{
inline chamb_spheroid(const Parameters& par) : detail::chamb::base_chamb_spheroid<CalculationType, Parameters>(par)
{
detail::chamb::setup_chamb(this->m_par, this->m_proj_parm);
}
};
#ifndef DOXYGEN_NO_DETAIL
namespace detail
{
// Static projection
BOOST_GEOMETRY_PROJECTIONS_DETAIL_STATIC_PROJECTION(srs::par4::chamb, chamb_spheroid, chamb_spheroid)
// Factory entry(s)
template <typename CalculationType, typename Parameters>
class chamb_entry : public detail::factory_entry<CalculationType, Parameters>
{
public :
virtual base_v<CalculationType, Parameters>* create_new(const Parameters& par) const
{
return new base_v_f<chamb_spheroid<CalculationType, Parameters>, CalculationType, Parameters>(par);
}
};
template <typename CalculationType, typename Parameters>
inline void chamb_init(detail::base_factory<CalculationType, Parameters>& factory)
{
factory.add_to_factory("chamb", new chamb_entry<CalculationType, Parameters>);
}
} // namespace detail
#endif // doxygen
} // namespace projections
}} // namespace boost::geometry
#endif // BOOST_GEOMETRY_PROJECTIONS_CHAMB_HPP

View File

@@ -0,0 +1,183 @@
#ifndef BOOST_GEOMETRY_PROJECTIONS_COLLG_HPP
#define BOOST_GEOMETRY_PROJECTIONS_COLLG_HPP
// Boost.Geometry - extensions-gis-projections (based on PROJ4)
// This file is automatically generated. DO NOT EDIT.
// Copyright (c) 2008-2015 Barend Gehrels, Amsterdam, the Netherlands.
// This file was modified by Oracle on 2017.
// Modifications copyright (c) 2017, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle.
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
// This file is converted from PROJ4, http://trac.osgeo.org/proj
// PROJ4 is originally written by Gerald Evenden (then of the USGS)
// PROJ4 is maintained by Frank Warmerdam
// PROJ4 is converted to Boost.Geometry by Barend Gehrels
// Last updated version of proj: 4.9.1
// Original copyright notice:
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the "Software"),
// to deal in the Software without restriction, including without limitation
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
// and/or sell copies of the Software, and to permit persons to whom the
// Software is furnished to do so, subject to the following conditions:
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Software.
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.
#include <boost/geometry/util/math.hpp>
#include <boost/geometry/srs/projections/impl/base_static.hpp>
#include <boost/geometry/srs/projections/impl/base_dynamic.hpp>
#include <boost/geometry/srs/projections/impl/projects.hpp>
#include <boost/geometry/srs/projections/impl/factory_entry.hpp>
namespace boost { namespace geometry
{
namespace srs { namespace par4
{
struct collg {};
}} //namespace srs::par4
namespace projections
{
#ifndef DOXYGEN_NO_DETAIL
namespace detail { namespace collg
{
static const double FXC = 1.12837916709551257390;
static const double FYC = 1.77245385090551602729;
static const double ONEEPS = 1.0000001;
// template class, using CRTP to implement forward/inverse
template <typename CalculationType, typename Parameters>
struct base_collg_spheroid : public base_t_fi<base_collg_spheroid<CalculationType, Parameters>,
CalculationType, Parameters>
{
typedef CalculationType geographic_type;
typedef CalculationType cartesian_type;
inline base_collg_spheroid(const Parameters& par)
: base_t_fi<base_collg_spheroid<CalculationType, Parameters>,
CalculationType, Parameters>(*this, par) {}
// FORWARD(s_forward) spheroid
// Project coordinates from geographic (lon, lat) to cartesian (x, y)
inline void fwd(geographic_type& lp_lon, geographic_type& lp_lat, cartesian_type& xy_x, cartesian_type& xy_y) const
{
if ((xy_y = 1. - sin(lp_lat)) <= 0.)
xy_y = 0.;
else
xy_y = sqrt(xy_y);
xy_x = FXC * lp_lon * xy_y;
xy_y = FYC * (1. - xy_y);
}
// INVERSE(s_inverse) spheroid
// Project coordinates from cartesian (x, y) to geographic (lon, lat)
inline void inv(cartesian_type& xy_x, cartesian_type& xy_y, geographic_type& lp_lon, geographic_type& lp_lat) const
{
lp_lat = xy_y / FYC - 1.;
if (fabs(lp_lat = 1. - lp_lat * lp_lat) < 1.)
lp_lat = asin(lp_lat);
else if (fabs(lp_lat) > ONEEPS)
BOOST_THROW_EXCEPTION( projection_exception(-20) );
else
lp_lat = lp_lat < 0. ? -geometry::math::half_pi<double>() : geometry::math::half_pi<double>();
if ((lp_lon = 1. - sin(lp_lat)) <= 0.)
lp_lon = 0.;
else
lp_lon = xy_x / (FXC * sqrt(lp_lon));
}
static inline std::string get_name()
{
return "collg_spheroid";
}
};
// Collignon
template <typename Parameters>
inline void setup_collg(Parameters& par)
{
par.es = 0.;
}
}} // namespace collg
#endif // doxygen
/*!
\brief Collignon projection
\ingroup projections
\tparam Geographic latlong point type
\tparam Cartesian xy point type
\tparam Parameters parameter type
\par Projection characteristics
- Pseudocylindrical
- Spheroid
\par Example
\image html ex_collg.gif
*/
template <typename CalculationType, typename Parameters>
struct collg_spheroid : public detail::collg::base_collg_spheroid<CalculationType, Parameters>
{
inline collg_spheroid(const Parameters& par) : detail::collg::base_collg_spheroid<CalculationType, Parameters>(par)
{
detail::collg::setup_collg(this->m_par);
}
};
#ifndef DOXYGEN_NO_DETAIL
namespace detail
{
// Static projection
BOOST_GEOMETRY_PROJECTIONS_DETAIL_STATIC_PROJECTION(srs::par4::collg, collg_spheroid, collg_spheroid)
// Factory entry(s)
template <typename CalculationType, typename Parameters>
class collg_entry : public detail::factory_entry<CalculationType, Parameters>
{
public :
virtual base_v<CalculationType, Parameters>* create_new(const Parameters& par) const
{
return new base_v_fi<collg_spheroid<CalculationType, Parameters>, CalculationType, Parameters>(par);
}
};
template <typename CalculationType, typename Parameters>
inline void collg_init(detail::base_factory<CalculationType, Parameters>& factory)
{
factory.add_to_factory("collg", new collg_entry<CalculationType, Parameters>);
}
} // namespace detail
#endif // doxygen
} // namespace projections
}} // namespace boost::geometry
#endif // BOOST_GEOMETRY_PROJECTIONS_COLLG_HPP

View File

@@ -0,0 +1,175 @@
#ifndef BOOST_GEOMETRY_PROJECTIONS_CRAST_HPP
#define BOOST_GEOMETRY_PROJECTIONS_CRAST_HPP
// Boost.Geometry - extensions-gis-projections (based on PROJ4)
// This file is automatically generated. DO NOT EDIT.
// Copyright (c) 2008-2015 Barend Gehrels, Amsterdam, the Netherlands.
// This file was modified by Oracle on 2017.
// Modifications copyright (c) 2017, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle.
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
// This file is converted from PROJ4, http://trac.osgeo.org/proj
// PROJ4 is originally written by Gerald Evenden (then of the USGS)
// PROJ4 is maintained by Frank Warmerdam
// PROJ4 is converted to Boost.Geometry by Barend Gehrels
// Last updated version of proj: 4.9.1
// Original copyright notice:
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the "Software"),
// to deal in the Software without restriction, including without limitation
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
// and/or sell copies of the Software, and to permit persons to whom the
// Software is furnished to do so, subject to the following conditions:
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Software.
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.
#include <boost/geometry/srs/projections/impl/base_static.hpp>
#include <boost/geometry/srs/projections/impl/base_dynamic.hpp>
#include <boost/geometry/srs/projections/impl/projects.hpp>
#include <boost/geometry/srs/projections/impl/factory_entry.hpp>
namespace boost { namespace geometry
{
namespace srs { namespace par4
{
struct crast {};
}} //namespace srs::par4
namespace projections
{
#ifndef DOXYGEN_NO_DETAIL
namespace detail { namespace crast
{
static const double XM = 0.97720502380583984317;
static const double RXM = 1.02332670794648848847;
static const double YM = 3.06998012383946546542;
static const double RYM = 0.32573500793527994772;
//static const double THIRD = 0.333333333333333333;
// template class, using CRTP to implement forward/inverse
template <typename CalculationType, typename Parameters>
struct base_crast_spheroid : public base_t_fi<base_crast_spheroid<CalculationType, Parameters>,
CalculationType, Parameters>
{
typedef CalculationType geographic_type;
typedef CalculationType cartesian_type;
inline base_crast_spheroid(const Parameters& par)
: base_t_fi<base_crast_spheroid<CalculationType, Parameters>,
CalculationType, Parameters>(*this, par) {}
// FORWARD(s_forward) spheroid
// Project coordinates from geographic (lon, lat) to cartesian (x, y)
inline void fwd(geographic_type& lp_lon, geographic_type& lp_lat, cartesian_type& xy_x, cartesian_type& xy_y) const
{
static const CalculationType THIRD = detail::THIRD<CalculationType>();
lp_lat *= THIRD;
xy_x = XM * lp_lon * (2. * cos(lp_lat + lp_lat) - 1.);
xy_y = YM * sin(lp_lat);
}
// INVERSE(s_inverse) spheroid
// Project coordinates from cartesian (x, y) to geographic (lon, lat)
inline void inv(cartesian_type& xy_x, cartesian_type& xy_y, geographic_type& lp_lon, geographic_type& lp_lat) const
{
static const CalculationType THIRD = detail::THIRD<CalculationType>();
lp_lat = 3. * asin(xy_y * RYM);
lp_lon = xy_x * RXM / (2. * cos((lp_lat + lp_lat) * THIRD) - 1);
}
static inline std::string get_name()
{
return "crast_spheroid";
}
};
// Craster Parabolic (Putnins P4)
template <typename Parameters>
inline void setup_crast(Parameters& par)
{
par.es = 0.;
}
}} // namespace detail::crast
#endif // doxygen
/*!
\brief Craster Parabolic (Putnins P4) projection
\ingroup projections
\tparam Geographic latlong point type
\tparam Cartesian xy point type
\tparam Parameters parameter type
\par Projection characteristics
- Pseudocylindrical
- Spheroid
\par Example
\image html ex_crast.gif
*/
template <typename CalculationType, typename Parameters>
struct crast_spheroid : public detail::crast::base_crast_spheroid<CalculationType, Parameters>
{
inline crast_spheroid(const Parameters& par) : detail::crast::base_crast_spheroid<CalculationType, Parameters>(par)
{
detail::crast::setup_crast(this->m_par);
}
};
#ifndef DOXYGEN_NO_DETAIL
namespace detail
{
// Static projection
BOOST_GEOMETRY_PROJECTIONS_DETAIL_STATIC_PROJECTION(srs::par4::crast, crast_spheroid, crast_spheroid)
// Factory entry(s)
template <typename CalculationType, typename Parameters>
class crast_entry : public detail::factory_entry<CalculationType, Parameters>
{
public :
virtual base_v<CalculationType, Parameters>* create_new(const Parameters& par) const
{
return new base_v_fi<crast_spheroid<CalculationType, Parameters>, CalculationType, Parameters>(par);
}
};
template <typename CalculationType, typename Parameters>
inline void crast_init(detail::base_factory<CalculationType, Parameters>& factory)
{
factory.add_to_factory("crast", new crast_entry<CalculationType, Parameters>);
}
} // namespace detail
#endif // doxygen
} // namespace projections
}} // namespace boost::geometry
#endif // BOOST_GEOMETRY_PROJECTIONS_CRAST_HPP

View File

@@ -0,0 +1,174 @@
#ifndef BOOST_GEOMETRY_PROJECTIONS_DENOY_HPP
#define BOOST_GEOMETRY_PROJECTIONS_DENOY_HPP
// Boost.Geometry - extensions-gis-projections (based on PROJ4)
// This file is automatically generated. DO NOT EDIT.
// Copyright (c) 2008-2015 Barend Gehrels, Amsterdam, the Netherlands.
// This file was modified by Oracle on 2017.
// Modifications copyright (c) 2017, Oracle and/or its affiliates.
// Contributed and/or modified by Adam Wulkiewicz, on behalf of Oracle.
// Use, modification and distribution is subject to the Boost Software License,
// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
// http://www.boost.org/LICENSE_1_0.txt)
// This file is converted from PROJ4, http://trac.osgeo.org/proj
// PROJ4 is originally written by Gerald Evenden (then of the USGS)
// PROJ4 is maintained by Frank Warmerdam
// PROJ4 is converted to Boost.Geometry by Barend Gehrels
// Last updated version of proj: 4.9.1
// Original copyright notice:
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the "Software"),
// to deal in the Software without restriction, including without limitation
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
// and/or sell copies of the Software, and to permit persons to whom the
// Software is furnished to do so, subject to the following conditions:
// The above copyright notice and this permission notice shall be included
// in all copies or substantial portions of the Software.
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.
#include <boost/geometry/srs/projections/impl/base_static.hpp>
#include <boost/geometry/srs/projections/impl/base_dynamic.hpp>
#include <boost/geometry/srs/projections/impl/projects.hpp>
#include <boost/geometry/srs/projections/impl/factory_entry.hpp>
namespace boost { namespace geometry
{
namespace srs { namespace par4
{
struct denoy {};
}} //namespace srs::par4
namespace projections
{
#ifndef DOXYGEN_NO_DETAIL
namespace detail { namespace denoy
{
static const double C0 = 0.95;
//static const double C1 = -.08333333333333333333;
//static const double C3 = .00166666666666666666;
static const double D1 = 0.9;
static const double D5 = 0.03;
template <typename T>
inline T C1() { return -.0833333333333333333333333333333; }
template <typename T>
inline T C3() { return .0016666666666666666666666666666; }
// template class, using CRTP to implement forward/inverse
template <typename CalculationType, typename Parameters>
struct base_denoy_spheroid : public base_t_f<base_denoy_spheroid<CalculationType, Parameters>,
CalculationType, Parameters>
{
typedef CalculationType geographic_type;
typedef CalculationType cartesian_type;
inline base_denoy_spheroid(const Parameters& par)
: base_t_f<base_denoy_spheroid<CalculationType, Parameters>,
CalculationType, Parameters>(*this, par) {}
// FORWARD(s_forward) spheroid
// Project coordinates from geographic (lon, lat) to cartesian (x, y)
inline void fwd(geographic_type& lp_lon, geographic_type& lp_lat, cartesian_type& xy_x, cartesian_type& xy_y) const
{
static const CalculationType C1 = denoy::C1<CalculationType>();
static const CalculationType C3 = denoy::C3<CalculationType>();
xy_y = lp_lat;
xy_x = lp_lon;
lp_lon = fabs(lp_lon);
xy_x *= cos((C0 + lp_lon * (C1 + lp_lon * lp_lon * C3)) *
(lp_lat * (D1 + D5 * lp_lat * lp_lat * lp_lat * lp_lat)));
}
static inline std::string get_name()
{
return "denoy_spheroid";
}
};
// Denoyer Semi-Elliptical
template <typename Parameters>
inline void setup_denoy(Parameters& par)
{
par.es = 0.;
}
}} // namespace detail::denoy
#endif // doxygen
/*!
\brief Denoyer Semi-Elliptical projection
\ingroup projections
\tparam Geographic latlong point type
\tparam Cartesian xy point type
\tparam Parameters parameter type
\par Projection characteristics
- Pseudocylindrical
- no inverse
- Spheroid
\par Example
\image html ex_denoy.gif
*/
template <typename CalculationType, typename Parameters>
struct denoy_spheroid : public detail::denoy::base_denoy_spheroid<CalculationType, Parameters>
{
inline denoy_spheroid(const Parameters& par) : detail::denoy::base_denoy_spheroid<CalculationType, Parameters>(par)
{
detail::denoy::setup_denoy(this->m_par);
}
};
#ifndef DOXYGEN_NO_DETAIL
namespace detail
{
// Static projection
BOOST_GEOMETRY_PROJECTIONS_DETAIL_STATIC_PROJECTION(srs::par4::denoy, denoy_spheroid, denoy_spheroid)
// Factory entry(s)
template <typename CalculationType, typename Parameters>
class denoy_entry : public detail::factory_entry<CalculationType, Parameters>
{
public :
virtual base_v<CalculationType, Parameters>* create_new(const Parameters& par) const
{
return new base_v_f<denoy_spheroid<CalculationType, Parameters>, CalculationType, Parameters>(par);
}
};
template <typename CalculationType, typename Parameters>
inline void denoy_init(detail::base_factory<CalculationType, Parameters>& factory)
{
factory.add_to_factory("denoy", new denoy_entry<CalculationType, Parameters>);
}
} // namespace detail
#endif // doxygen
} // namespace projections
}} // namespace boost::geometry
#endif // BOOST_GEOMETRY_PROJECTIONS_DENOY_HPP

Some files were not shown because too many files have changed in this diff Show More