summaryrefslogtreecommitdiff
path: root/boost/geometry/srs/projections/proj/hatano.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'boost/geometry/srs/projections/proj/hatano.hpp')
-rw-r--r--boost/geometry/srs/projections/proj/hatano.hpp33
1 files changed, 10 insertions, 23 deletions
diff --git a/boost/geometry/srs/projections/proj/hatano.hpp b/boost/geometry/srs/projections/proj/hatano.hpp
index 8392a2a3ca..f3ae7d07dc 100644
--- a/boost/geometry/srs/projections/proj/hatano.hpp
+++ b/boost/geometry/srs/projections/proj/hatano.hpp
@@ -50,12 +50,6 @@
namespace boost { namespace geometry
{
-namespace srs { namespace par4
-{
- struct hatano {}; // Hatano Asymmetrical Equal Area
-
-}} //namespace srs::par4
-
namespace projections
{
#ifndef DOXYGEN_NO_DETAIL
@@ -87,7 +81,7 @@ namespace projections
// FORWARD(s_forward) spheroid
// Project coordinates from geographic (lon, lat) to cartesian (x, y)
- inline void fwd(T& lp_lon, T& lp_lat, T& xy_x, T& xy_y) const
+ inline void fwd(T const& lp_lon, T lp_lat, T& xy_x, T& xy_y) const
{
T th1, c;
int i;
@@ -103,7 +97,7 @@ namespace projections
// INVERSE(s_inverse) spheroid
// Project coordinates from cartesian (x, y) to geographic (lon, lat)
- inline void inv(T& xy_x, T& xy_y, T& lp_lon, T& lp_lat) const
+ inline void inv(T const& xy_x, T const& xy_y, T& lp_lon, T& lp_lat) const
{
static T const half_pi = detail::half_pi<T>();
@@ -166,7 +160,9 @@ namespace projections
template <typename T, typename Parameters>
struct hatano_spheroid : public detail::hatano::base_hatano_spheroid<T, Parameters>
{
- inline hatano_spheroid(const Parameters& par) : detail::hatano::base_hatano_spheroid<T, Parameters>(par)
+ template <typename Params>
+ inline hatano_spheroid(Params const& , Parameters const& par)
+ : detail::hatano::base_hatano_spheroid<T, Parameters>(par)
{
detail::hatano::setup_hatano(this->m_par);
}
@@ -177,23 +173,14 @@ namespace projections
{
// Static projection
- BOOST_GEOMETRY_PROJECTIONS_DETAIL_STATIC_PROJECTION(srs::par4::hatano, hatano_spheroid, hatano_spheroid)
+ BOOST_GEOMETRY_PROJECTIONS_DETAIL_STATIC_PROJECTION(srs::spar::proj_hatano, hatano_spheroid, hatano_spheroid)
// Factory entry(s)
- template <typename T, typename Parameters>
- class hatano_entry : public detail::factory_entry<T, Parameters>
- {
- public :
- virtual base_v<T, Parameters>* create_new(const Parameters& par) const
- {
- return new base_v_fi<hatano_spheroid<T, Parameters>, T, Parameters>(par);
- }
- };
-
- template <typename T, typename Parameters>
- inline void hatano_init(detail::base_factory<T, Parameters>& factory)
+ BOOST_GEOMETRY_PROJECTIONS_DETAIL_FACTORY_ENTRY_FI(hatano_entry, hatano_spheroid)
+
+ BOOST_GEOMETRY_PROJECTIONS_DETAIL_FACTORY_INIT_BEGIN(hatano_init)
{
- factory.add_to_factory("hatano", new hatano_entry<T, Parameters>);
+ BOOST_GEOMETRY_PROJECTIONS_DETAIL_FACTORY_INIT_ENTRY(hatano, hatano_entry)
}
} // namespace detail