[Boost-bugs] [Boost C++ Libraries] #10983: box-box distance doesn't seem to work with spherical coordinate systems

Subject: [Boost-bugs] [Boost C++ Libraries] #10983: box-box distance doesn't seem to work with spherical coordinate systems
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2015-01-29 23:29:45


#10983: box-box distance doesn't seem to work with spherical coordinate systems
-----------------------+------------------------------
 Reporter: mdrinto@… | Type: Bugs
   Status: new | Milestone: To Be Determined
Component: None | Version: Boost 1.57.0
 Severity: Problem | Keywords:
-----------------------+------------------------------
 The "geometry distance matrix" indicates that all geometry-to-geometry
 distances have been implemented in 1.57. But the box-to-box distance
 doesn't seem to work with spherical geometries, at least with gcc 4.4.7.

 One of the errors seems to be a "not yet implemented" error, so perhaps it
 hasn't been done yet. It does have some tricky business that a cartesian
 box wouldn't have, but it's a straightforward exercise in trying different
 cases.

 I'm certainly delighted with boost::geometry's functionality as is, but it
 would be great if this worked. And many apologies if the mistake is mine.

 See example below for problem.


 ----


 {{{
 #include <boost/geometry/geometry.hpp>

 typedef
 boost::geometry::model::point<double,2,boost::geometry::cs::cartesian>
 cartesian_point;
 typedef
 boost::geometry::model::point<double,2,boost::geometry::cs::spherical_equatorial<boost::geometry::degree>
> spherical_point;

 int main()
 {

   // Works...
   boost::geometry::model::box<cartesian_point> c_box1, c_box2;
   boost::geometry::distance(c_box1,c_box2);

   // Doesn't work!
   boost::geometry::model::box<spherical_point> s_box1, s_box2;
   boost::geometry::distance(s_box1,s_box2);

   return 0;
 }
 }}}

-- 
Ticket URL: <https://svn.boost.org/trac/boost/ticket/10983>
Boost C++ Libraries <http://www.boost.org/>
Boost provides free peer-reviewed portable C++ source libraries.

This archive was generated by hypermail 2.1.7 : 2017-02-16 18:50:17 UTC