Boost C++ Libraries

...one of the most highly regarded and expertly designed C++ library projects in the world. Herb Sutter and Andrei Alexandrescu, C++ Coding Standards

Click here to view the latest version of this page.
PrevUpHomeNext

model::polygon

The polygon contains an outer ring and zero or more inner rings.

Model of

Polygon Concept

Synopsis

template<typename Point, bool ClockWise, bool Closed, template< typename, typename > class PointList, template< typename, typename > class RingList, template< typename > class PointAlloc, template< typename > class RingAlloc>
class model::polygon
{
  // ...
};

Template parameter(s)

Parameter

Default

Description

typename Point

point type

bool ClockWise

true

true for clockwise direction, false for CounterClockWise direction

bool Closed

true

true for closed polygons (last point == first point), false open points

template< typename, typename > class PointList

std::vector

container type for points, for example std::vector, std::list, std::deque

template< typename, typename > class RingList

std::vector

container type for inner rings, for example std::vector, std::list, std::deque

template< typename > class PointAlloc

std::allocator

container-allocator-type, for the points

template< typename > class RingAlloc

std::allocator

container-allocator-type, for the rings

Member Function(s)

Function

Description

Parameters

Returns

ring_type const & outer()

inner_container_type const & inners()

ring_type & outer()

inner_container_type & inners()

void clear()

Utility method, clears outer and inner rings.

Header

Either

#include <boost/geometry/geometries/geometries.hpp>

Or

#include <boost/geometry/geometries/polygon.hpp>


PrevUpHomeNext