Subject: [geometry] polygon linestring intersection issue
From: sergei benkovich (sergei1503_at_[hidden])
Date: 2016-06-23 09:53:33
i'm trying to use bg::intersection to find the intersection between a line
segment and a polygon.
in some cases it works, but in others it doesn't.
there should be an intersection between these two geometries but i get
nothing in the result.
anyone knows of any issues regarding this type of intersections?
this is the test code i ran:
boost::geometry::read_wkt("POLYGON((1012 1621, 1013 1621, 1013 1622,
1012 1622, 1012 1621))", testPol);
typedef bg::model::d2::point_xy<double, boost::geometry::cs::cartesian>
typedef bg::model::linestring<point_t> linestring_t;
bg::append(ls, point_t(1011.4, 1621.64));
bg::append(ls, point_t(1013.6, 1623.68));
bg::intersection(testPol, ls, res);
Geometry list run by mateusz at loskot.net