box2d — The type representing a 2-dimensional bounding box.


box2d is a spatial data type used to represent the two-dimensional bounding box enclosing a geometry or collection of geometries. For example, the ST_Extent aggregate function returns a box2d object.

The representation contains the values xmin, ymin, xmax, ymax. These are the minimum and maximum values of the X and Y extents.

box2d objects have a text representation which looks like BOX(1 2,5 6).

Casting Behavior

This table lists the automatic and explicit casts allowed for this data type:

Cast ToBehavior

See Also

Section 15.7, “PostGIS Box Functions”