Boost logo

Boost Users :

Subject: Re: [Boost-users] can not compile nearest neighbors in d dimensions
From: Georgios Samaras (georgesamarasdit_at_[hidden])
Date: 2014-04-16 10:45:44

I am talking about the 2 dimensions.

#include <boost/geometry.hpp>
#include <boost/geometry/geometries/point.hpp>
#include <boost/geometry/index/rtree.hpp>

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

template <int CompileTimeDimension>
void do_something()
    typedef bg::model::point<float, CompileTimeDimension,
bg::cs::cartesian> point;
    bgi::rtree<point, bgi::linear<8> > rt;

int main()
    int M;
    M = 100;
    if ( M == 100 )
        else if ( M == 10000 )
        std::cerr << "invalid dimension!";
    return 0;

and here is the first lines of the errors
In file included from
                 from ../boost/geometry/strategies/strategies.hpp:33,
                 from ../boost/geometry/geometry.hpp:35,
                 from ../boost/geometry.hpp:17,
                 from bla.cpp:66:
../boost/geometry/geometries/point.hpp: In static member function ‘static

I am attaching the errors.

Boost-users list run by williamkempf at, kalb at, bjorn.karlsson at, gregod at, wekempf at