|
Boost Users : |
Subject: [Boost-users] [geometry] intersects bug?
From: Akira Takahashi (faithandbrave_at_[hidden])
Date: 2011-07-26 21:17:05
Hi,
I try boost::geometry::intersects algorithm(1 arg version) in Boost 1.47.0.
Follow program result is "false". but, I hope result is "true".
Is this Boost.Geometry bug?
#include <iostream>
#include <boost/assign/list_of.hpp>
#include <boost/geometry/geometry.hpp>
namespace bg = boost::geometry;
int main()
{
typedef bg::model::d2::point_xy<double> point;
const bg::model::linestring<point> line = boost::assign::list_of<point>
// (0, 0) // result become "true" when comment-in
(0, 4)
(4, 4)
(2, 2)
(2, 5)
;
const bool result = bg::intersects(line);
std::cout << std::boolalpha << result << std::endl;
}
Regards,
>>========================
Akira Takahashi
mailto:faithandbrave_at_[hidden]
blog: http://d.hatena.ne.jp/faith_and_brave/
Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net