# Module: ol/geom/Polygon

This documentation is for OpenLayers v10.9.0. The latest is v.

## ol/geom/Polygon

### Classes

Polygon

### Functions

#### circular(center, radius, n, sphereRadius){Polygon}

geom/Polygon.js, line 432

      import {circular} from 'ol/geom/Polygon';

  Create an approximation of a circle on the surface of a sphere.

  Name | Type | Description
  --- | --- | ---
  `center` | Coordinate | Center (`[lon, lat]` in degrees).
  `radius` | number | The great-circle distance from the center to the polygon vertices in meters.
  `n` | number | undefined | Optional number of vertices for the resulting polygon. Default is `32`.
  `sphereRadius` | number | undefined | Optional radius for the sphere (defaults to the Earth's mean radius using the WGS84 ellipsoid).

  ##### Returns:

  The "circular" polygon.

#### fromCircle(circle, sides, angle){Polygon}

geom/Polygon.js, line 484

      import {fromCircle} from 'ol/geom/Polygon';

  Create a regular polygon from a circle.

  Name | Type | Description
  --- | --- | ---
  `circle` | Circle | Circle geometry.
  `sides` | number | undefined | Number of sides of the polygon. Default is 32.
  `angle` | number | undefined | Start angle for the first vertex of the polygon in counter-clockwise radians. 0 means East. Default is 0.

  ##### Returns:

  Polygon geometry.

#### fromExtent(extent){Polygon}

geom/Polygon.js, line 452

      import {fromExtent} from 'ol/geom/Polygon';

  Create a polygon from an extent. The layout used is `XY`.

  Name | Type | Description
  --- | --- | ---
  `extent` | Extent | The extent.

  ##### Returns:

  The polygon.