]>
git.proxmox.com Git - ceph.git/blob - ceph/src/boost/libs/geometry/doc/src/examples/core/point_type.cpp
1 // Boost.Geometry (aka GGL, Generic Geometry Library)
4 // Copyright (c) 2011-2012 Barend Gehrels, Amsterdam, the Netherlands.
6 // Use, modification and distribution is subject to the Boost Software License,
7 // Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
8 // http://www.boost.org/LICENSE_1_0.txt)
11 //` Examine the point type of a multi_polygon
16 #include <boost/geometry.hpp>
17 #include <boost/geometry/geometries/polygon.hpp>
18 #include <boost/geometry/geometries/point_xy.hpp>
19 #include <boost/geometry/geometries/multi_polygon.hpp>
23 typedef boost::geometry::model::d2::point_xy
<double> point_type
;
24 typedef boost::geometry::model::polygon
<point_type
> polygon_type
;
25 typedef boost::geometry::model::multi_polygon
<polygon_type
> mp_type
;
27 typedef boost::geometry::point_type
<mp_type
>::type ptype
;
29 std::cout
<< "point type: " << typeid(ptype
).name() << std::endl
;
41 point type: class boost::geometry::model::d2::point_xy<double,struct boost::geometry::cs::cartesian>