![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
point_typeBoost , Chapter 1. Geometry , Core Metafunctions
|
Параметр |
Описание |
---|---|
Или
#include <boost/geometry.hpp>
Или
#include <boost/geometry/core/point_type.hpp>
Время компиляции
Изучите тип точки мульти-полигона
#include <iostream> #include <typeinfo> #include <boost/geometry.hpp> #include <boost/geometry/geometries/polygon.hpp> #include <boost/geometry/geometries/point_xy.hpp> #include <boost/geometry/geometries/multi_polygon.hpp> int main() { typedef boost::geometry::model::d2::point_xy<double> point_type; typedef boost::geometry::model::polygon<point_type> polygon_type; typedef boost::geometry::model::multi_polygon<polygon_type> mp_type; typedef boost::geometry::point_type<mp_type>::type ptype; std::cout << "point type: " << typeid(ptype).name() << std::endl; return 0; }
Выход (в MSVC):
point type: class boost::geometry::model::d2::point_xy<double,struct boost::geometry::cs::cartesian>
Статья point_type раздела Chapter 1. Geometry Core Metafunctions может быть полезна для разработчиков на c++ и boost.
Материалы статей собраны из открытых источников, владелец сайта не претендует на авторство. Там где авторство установить не удалось, материал подаётся без имени автора. В случае если Вы считаете, что Ваши права нарушены, пожалуйста, свяжитесь с владельцем сайта.
:: Главная :: Core Metafunctions ::
реклама |