#12189 closed Bugs (fixed)

R-tree spacial predicates for ring, polygon, multipolygon fail to compile

Reported by: mike.vasiljevs@… Owned by: Barend Gehrels
Milestone: Boost 1.62.0 Component: geometry
Version: Boost 1.59.0 Severity: Problem
Keywords: Cc:


It is possible to compile an *intersects* query ( on R-tree of *box*es using a *ring*, *polygon*, *multipolygon* predicates in boost 1.58.0, but not in later versions.

Test compilation with this example:

#include <vector> #include <boost/geometry.hpp> #include <boost/geometry/geometries/point_xy.hpp> #include <boost/geometry/geometries/box.hpp> #include <boost/geometry/geometries/polygon.hpp> #include <boost/geometry/index/rtree.hpp>

void testSpacialIndexing() {

namespace bg = boost::geometry; namespace bgm = boost::geometry::model; namespace bgi = boost::geometry::index;

typedef bgm::d2::point_xy<double> P; typedef bgm::box<P> B;

P qpt; B qbox; bgm::ring<P> qring; bgm::polygon<P> qpoly; bgm::multi_polygon<bgm::polygon<P>> qmpoly; bgm::segment<P> qseg; bgm::linestring<P> qls;

spacial indexing example typedef std::pair<B, int> Value_t; bgi::rtree<Value_t, bgi::quadratic<8>> rtree1;

std::vector<Value_t> found;

works for all versions rtree1.query(bgi::intersects(qpt), back_inserter(found)); rtree1.query(bgi::intersects(qbox), back_inserter(found)); rtree1.query(bgi::intersects(qseg), back_inserter(found)); rtree1.query(bgi::intersects(qls), back_inserter(found));

does not work for 1.59 to 1.61 beta rtree1.query(bgi::intersects(qring), back_inserter(found)); rtree1.query(bgi::intersects(qpoly), back_inserter(found)); rtree1.query(bgi::intersects(qmpoly), back_inserter(found));


Test works with release 1.58 Test does not work with releases 1.59, 1.60, 1.61.0b1

Attachments (1)

boost_issue_12189.cpp (1.4 KB) - added by mike.vasiljevs@… 17 months ago.
example as cpp file

Download all attachments as: .zip

Change History (2)

Changed 17 months ago by mike.vasiljevs@…

Attachment: boost_issue_12189.cpp added

example as cpp file

comment:1 Changed 15 months ago by awulkiew

Milestone: To Be DeterminedBoost 1.62.0
Resolution: fixed
Status: newclosed

Modify Ticket

Change Properties
Set your email in Preferences
as closed The owner will remain Barend Gehrels.
The resolution will be deleted.

Add Comment

E-mail address and name can be saved in the Preferences.

Note: See TracTickets for help on using tickets.