#include namespace QCS { template struct Point2D { Point2D() {} Point2D(T const& x, T const& y) : m_x(x), m_y(y) {} T m_x, m_y; void SetX(T const& x) { m_x = x; } void SetY(T const& y) { m_y = y; } }; } // namespace QCS namespace boost { namespace geometry { namespace traits { template struct tag > { typedef point_tag type; }; template struct dimension > : boost::mpl::int_<2> {}; template struct coordinate_type > { typedef P type; }; template struct coordinate_system > { typedef cs::cartesian type; }; template struct access, 0> { static inline P get(QCS::Point2D

const& p) { return p.m_x; } static inline void set(QCS::Point2D

& p, P const& value) { p.SetX(value); } }; template struct access, 1> { static inline P get(QCS::Point2D

const& p) { return p.m_y; } static inline void set(QCS::Point2D

& p, P const& value) { p.SetY(value); } }; }}} // namespace boost::geometry::traits int main() { QCS::Point2D pt(0, 0); typedef boost::geometry::tag< QCS::Point2D >::type tag_type; boost::geometry::intersects(pt, pt); }