Hi,
   Boost Geometry 1.78, linux
   Â
   I was getting bad results with my calculations so I decided to narrow
   down the implementation up to the point I got the following problematic
   code:
   Â
   typedef boost::geometry::model::point <double, 2,
   boost::geometry::cs::cartesian> Vector2d;
   Â
   int main (){
   Â
   Â Â Â Â Â Â Â  multi_polygon <polygon <Vector2d> > mp;
   Â
   Â Â Â Â Â Â Â  /*{
   Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â  polygon <Vector2d> poly;
   Â
   Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â  poly.outer().push_back( {0, 0} );
   Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â  poly.outer().push_back( {0, 4} );
   Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â  poly.outer().push_back( {4, 4} );
   Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â  poly.outer().push_back( {4, 0} );
   Â
   Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â  correct( poly );
   Â
   Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â  mp.push_back(poly);
   Â Â Â Â Â Â Â  }*/
   Â Â Â Â Â Â Â  {
   Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â  polygon <Vector2d> poly;
   Â
   Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â  poly.outer().push_back( {10, -1} );
   Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â  poly.outer().push_back( {14, -1} );
   Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â  poly.outer().push_back( {10, -2} );
   Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â  poly.outer().push_back( {14, -2}Â  );
   Â
   Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â  correct( poly );
   Â
   Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â  mp.push_back(poly);
   Â Â Â Â Â Â Â  }
   Â
   Â
   Â Â Â Â Â Â Â  boost::geometry::strategy::buffer::join_miter
   join_strategy;
   Â Â Â Â Â Â Â  boost::geometry::strategy::buffer::end_flat
   end_strategy;
   Â Â Â Â Â Â Â  boost::geometry::strategy::buffer::side_straight
   side_strategy;
   Â Â Â Â Â Â Â  boost::geometry::strategy::buffer::point_square
   point_strategy;
   Â
   Â Â Â Â Â Â Â  boost::geometry::strategy::buffer::distance_symmetric
   <double> distance_strategy( 2 );
   Â Â Â Â Â Â Â  boost::geometry::model::multi_polygon <polygon
   <Vector2d> > result;
   Â
   Â Â Â Â Â Â Â  boost::geometry::buffer( mp, result, distance_strategy,
   side_strategy, join_strategy, end_strategy, point_strategy );
   Â
   Â Â Â Â Â Â Â  cout << dsv( result ) << endl;
   Â
   Â Â Â Â Â Â Â  return 0;
   Â
   }
   Â
   and the result I get is:
   ((((13.7169, -3.13232), (13.5149, -3.94029), (12, -3.56155), (10.4851,
   -3.94029), (10.2831, -3.13232), (9.51493, -2.94029), (0.0749244,
   0.221833), (10, 1), (14, 1), (23.9251, 0.221833), (14.4851, -2.94029),
   (13.7169, -3.13232))))
   Â
   Notice the two points:
   (0.0749244, 0.221833) and (23.9251, 0.221833)
   Â
   I have multiple complex (concave) shapes which behave worse than that
   simple rectangle. But it is a starting point here.
   Â
   Did I do something wrong?
   I need to get my job done, any alternative or helping code massaging ?
   Â
   Thanks
   --Â
   MKL
   Â