#9556 closed Bugs (invalid)
within fails on simple case
Reported by: | Robert Ramey | Owned by: | Barend Gehrels |
---|---|---|---|
Milestone: | To Be Determined | Component: | geometry |
Version: | Boost 1.55.0 | Severity: | Problem |
Keywords: | Cc: |
Description
the attached case illustrates to me that with fails on a simple case.
// simple test of boost geometry function within bool test1(){ typedef boost::geometry::model::d2::point_xy<float> point; typedef boost::geometry::model::ring<point, false, false> ring; ring r; r.push_back(point(-2054781.4f, 1327536.6f)); r.push_back(point(-2042300.1f, 1275254.1f)); r.push_back(point(-2142418.5f, 1333733.5f)); r.push_back(point(-2122850.5f, 1553784.4f)); //r.push_back(point(-2054781.4f, 1327536.6f)); point pt(-2238243.8f, 1523654.5f); bool result = boost::geometry::within(pt, r); // result should be false - but returns true if(result != false) return false; point pt2(-210000.8f, 1350000.5f); result = boost::geometry::within(pt2, r); // result should be true - but returns false if(result != true) return false; // if we made here - fine return true; }
Note:
See TracTickets
for help on using tickets.
OK - looks ike I'm at fault here.
With this change - test passes