Namespace: extent

ol.extent

Methods

ol.extent.applyTransform(extent, transformFn, opt_extent){ol.Extent}

src/ol/extent.js, line 855

Apply a transform function to the extent.

Name Type Description
extent ol.Extent

Extent.

transformFn ol.TransformFunction

Transform function. Called with [minX, minY, maxX, maxY] extent coordinates.

extent ol.Extent

Destination extent.

Returns:
Extent.

ol.extent.boundingExtent(coordinates){ol.Extent}

src/ol/extent.js, line 41

Build an extent that includes all given coordinates.

Name Type Description
coordinates Array.<ol.Coordinate>

Coordinates.

Returns:
Bounding extent.

ol.extent.buffer(extent, value, opt_extent){ol.Extent}

src/ol/extent.js, line 76

Return extent increased by the provided value.

Name Type Description
extent ol.Extent

Extent.

value number

The amount by which the extent should be buffered.

extent ol.Extent

Extent.

Returns:
Extent.

ol.extent.containsCoordinate(extent, coordinate){boolean}

src/ol/extent.js, line 148

Check if the passed coordinate is contained or on the edge of the extent.

Name Type Description
extent ol.Extent

Extent.

coordinate ol.Coordinate

Coordinate.

Returns:
The coordinate is contained in the extent.

ol.extent.containsExtent(extent1, extent2){boolean}

src/ol/extent.js, line 165

Check if one extent contains another.

An extent is deemed contained if it lies completely within the other extent, including if they share one or more edges.

Name Type Description
extent1 ol.Extent

Extent 1.

extent2 ol.Extent

Extent 2.

Returns:
The second extent is contained by or on the edge of the first.

ol.extent.containsXY(extent, x, y){boolean}

src/ol/extent.js, line 180

Check if the passed coordinate is contained or on the edge of the extent.

Name Type Description
extent ol.Extent

Extent.

x number

X coordinate.

y number

Y coordinate.

Returns:
The x, y values are contained in the extent.

ol.extent.createEmpty(){ol.Extent}

src/ol/extent.js, line 222

Create an empty extent.

Returns:
Empty extent.

ol.extent.equals(extent1, extent2){boolean}

src/ol/extent.js, line 328

Determine if two extents are equivalent.

Name Type Description
extent1 ol.Extent

Extent 1.

extent2 ol.Extent

Extent 2.

Returns:
The two extents are equivalent.

ol.extent.extend(extent1, extent2){ol.Extent}

src/ol/extent.js, line 341

Modify an extent to include another extent.

Name Type Description
extent1 ol.Extent

The extent to be modified.

extent2 ol.Extent

The extent that will be included in the first.

Returns:
A reference to the first (extended) extent.

ol.extent.getBottomLeft(extent){ol.Coordinate}

src/ol/extent.js, line 487

Get the bottom left coordinate of an extent.

Name Type Description
extent ol.Extent

Extent.

Returns:
Bottom left coordinate.

ol.extent.getBottomRight(extent){ol.Coordinate}

src/ol/extent.js, line 498

Get the bottom right coordinate of an extent.

Name Type Description
extent ol.Extent

Extent.

Returns:
Bottom right coordinate.

ol.extent.getCenter(extent){ol.Coordinate}

src/ol/extent.js, line 509

Get the center coordinate of an extent.

Name Type Description
extent ol.Extent

Extent.

Returns:
Center.

ol.extent.getHeight(extent){number}

src/ol/extent.js, line 591

Get the height of an extent.

Name Type Description
extent ol.Extent

Extent.

Returns:
Height.

ol.extent.getIntersection(extent1, extent2, opt_extent){ol.Extent}

src/ol/extent.js, line 615

Get the intersection of two extents.

Name Type Description
extent1 ol.Extent

Extent 1.

extent2 ol.Extent

Extent 2.

extent ol.Extent

Optional extent to populate with intersection.

Returns:
Intersecting extent.

ol.extent.getSize(extent){ol.Size}

src/ol/extent.js, line 658

Get the size (width, height) of an extent.

Name Type Description
extent ol.Extent

The extent.

Returns:
The extent size.

ol.extent.getTopLeft(extent){ol.Coordinate}

src/ol/extent.js, line 669

Get the top left coordinate of an extent.

Name Type Description
extent ol.Extent

Extent.

Returns:
Top left coordinate.

ol.extent.getTopRight(extent){ol.Coordinate}

src/ol/extent.js, line 680

Get the top right coordinate of an extent.

Name Type Description
extent ol.Extent

Extent.

Returns:
Top right coordinate.

ol.extent.getWidth(extent){number}

src/ol/extent.js, line 691

Get the width of an extent.

Name Type Description
extent ol.Extent

Extent.

Returns:
Width.

ol.extent.intersects(extent1, extent2){boolean}

src/ol/extent.js, line 703

Determine if one extent intersects another.

Name Type Description
extent1 ol.Extent

Extent 1.

extent2 ol.Extent

Extent.

Returns:
The two extents intersect.

ol.extent.isEmpty(extent){boolean}

src/ol/extent.js, line 717

Determine if an extent is empty.

Name Type Description
extent ol.Extent

Extent.

Returns:
Is empty.