[Boost-bugs] [Boost C++ Libraries] #12725: boost::geometry::distance compile errors with 3D segment primitives

Subject: [Boost-bugs] [Boost C++ Libraries] #12725: boost::geometry::distance compile errors with 3D segment primitives
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2017-01-05 00:33:45


#12725: boost::geometry::distance compile errors with 3D segment primitives
----------------------------------------+---------------------------
 Reporter: Arturo Blas <arturoblas@…> | Owner: barendgehrels
     Type: Bugs | Status: new
Milestone: To Be Determined | Component: geometry
  Version: Boost 1.61.0 | Severity: Problem
 Keywords: rtree, geometry, distance |
----------------------------------------+---------------------------
 When trying to calculate the nearest segment from another segment in a
 3-dimensional space using the boost::geometry::index::nearest query on a
 boost:: boost::geometry::index::rtree but I get the following compilation
 error on VS2010:


 {{{
> error C2664: 'boost::mpl::assertion_failed' : cannot convert parameter
> 1 from 'boost::mpl::failed ************(__cdecl
>
 boost::geometry::nyi::not_implemented_error<Term1,Term2,Term3>::THIS_OPERATION_IS_NOT_OR_NOT_YET_IMPLEMENTED::*
> ***********)(boost::mpl::assert_::types<T1,T2,T3>)' to
 'boost::mpl::assert<false>::type'
 }}}

 I have managed to narrow down the same issue to using just the
 `boost::geometry::distance` function:

 {{{
     typedef boost::geometry::model::point <float, 3,
 boost::geometry::cs::cartesian> point;
     typedef boost::geometry::model::segment <point> segment;

     point pa = point(x1, y1, z1);
     point pc = point(x2, y2, z2);
     point pb = point(x3, y3, z3);

     float dist = boost::geometry::distance(segment(pa, pb), segment(pa,
 pc));
 }}}


 According to the documentation of the version of Boost I'm using (1.60)
 this should be supported, however it works just fine when using two
 dimensions.

 [http://www.boost.org/doc/libs/1_60_0/libs/geometry/doc/html/geometry/reference/algorithms/distance/distance_2.html#geometry.reference.algorithms.distance.distance_2.supported_geometries]

 I could not find anything in the docs either about how to extend the
 functionality or whether it's possible at all and could not find any
 relevant changes regarding this issue since this version.

 Is this a bug or something in the roadmap that hasn't yet been addressed?


 [http://stackoverflow.com/questions/41453792/boostgeometrydistance-
 compile-errors-with-3d-primitives]

-- 
Ticket URL: <https://svn.boost.org/trac/boost/ticket/12725>
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:20 UTC