CGAL::General_polygon_2<ArrTraits>

Definition

The class General_polygon_2<ArrTraits> models the concept GeneralPolygon_2. It represents a simple general-polygon. It is parameterized with the type ArrTraits that models the concept ArrangementDirectionalXMonotoneTraits. The latter is a refinment of the concept ArrangementXMonotoneTraits_2. In addition to the requirements of the concept ArrangementXMonotoneTraits_2, a model of the concept ArrangementDirectionalXMonotoneTraits must support the following functions:

This class supports a few convenient operations in addition to the requirements that the concept GeneralPolygon_2 lists.

#include <CGAL/General_polygon_2.h>

Types

General_polygon_2<ArrTraits>::Size
number of edges size type.

Creation

Operations

Size polygon.size () returns the number of edges of polygon.

Modifiers

void polygon.clear () clears polygon.

void polygon.reverse_orientation () reverses the orientation of the polygon.
Precondition: is_simple().

Predicates

bool polygon.is_empty () returns true if polygon is empty, and false otherwise.

Orientation polygon.orientation () returns the orientation of polygon.
Precondition: is_simple().

Is Model for the Concepts

GeneralPolygon_2