# [name]

Represents a boundary box in 3d space.

## Constructor

### [name]( [page:Vector3 min], [page:Vector3 max] )

min -- Lower (x, y, z) boundary of the box.
max -- Upper (x, y, z) boundary of the box.
Creates a box bounded by min and max.

## Properties

### [property:Vector3 min]

Lower (x, y, z) boundary of this box.

### [property:Vector3 max]

Upper (x, y, z) boundary of this box.

## Methods

### [method:Box3 set]( [page:Vector3 min], [page:Vector3 max] ) [page:Box3 this]

min -- Lower (x, y, z) boundary of the box.
max -- Upper (x, y, z) boundary of the box.
Sets the lower and upper (x, y, z) boundaries of this box.

### [method:Box3 applyMatrix4]( [page:Matrix4 matrix] ) [page:Box3 this]

matrix -- The [page:Matrix4] to apply
Transforms this Box3 with the supplied matrix.

### [method:Vector3 clampPoint]( [page:Vector3 point], [page:Vector3 optionalTarget] ) [page:Box3 this]

point -- Position to clamp.
optionalTarget -- If specified, the clamped result will be copied here.
Clamps *point* within the bounds of this box.

### [method:Boolean intersectsBox]( [page:Box3 box] ) [page:Box3 this]

box -- Box to check for intersection against.
Determines whether or not this box intersects *box*.

### [method:Box3 setFromPoints]( [page:Array points] ) [page:Box3 this]

points -- Set of points that the resulting box will envelop.
Sets the upper and lower bounds of this box to include all of the points in *points*.

### [method:Box3 setFromObject]( [page:Object3D object] ) [page:Box3 this]

object -- [page:Object3D] to compute the bounding box for.
Computes the world-axis-aligned bounding box of an object (including its children), accounting for both the object's, and childrens', world transforms

### [method:Vector3 size]( [page:Vector3 optionalTarget] ) [page:Box3 this]

optionalTarget -- If specified, the result will be copied here.
Returns the width, height, and depth of this box.

### [method:Box3 union]( [page:Box3 box] ) [page:Box3 this]

box -- Box that will be unioned with this box.
Unions this box with *box* setting the upper bound of this box to the greater of the two boxes' upper bounds and the lower bound of this box to the lesser of the two boxes' lower bounds.

### [method:Vector3 getParameter]( [page:Vector3 point], [page:Vector3 optionalTarget] ) [page:Box3 this]

point -- Point to parametrize. optionalTarget -- If specified, the result will be copied here.
Returns point as a proportion of this box's width and height.

### [method:Box3 intersect]( [page:Box3 box] ) [page:Box3 this]

box -- Box to intersect with.
Returns the intersection of this and *box*, setting the upper bound of this box to the lesser of the two boxes' upper bounds and the lower bound of this box to the greater of the two boxes' lower bounds.

### [method:Boolean containsBox]( [page:Box3 box] ) [page:Box3 this]

box -- Box to test for inclusion.
Returns true if this box includes the entirety of *box*. If this and *box* overlap exactly, this function also returns true.

### [method:Boolean containsPoint]( [page:Vector3 point] ) [page:Box3 this]

point -- [page:Vector3] to check for inclusion.
Returns true if the specified point lies within the boundaries of this box.

### [method:Box3 translate]( [page:Vector3 offset] ) [page:Box3 this]

offset -- Direction and distance of offset.
Adds *offset* to both the upper and lower bounds of this box, effectively moving this box *offset* units in 3D space.

### [method:Boolean isEmpty]() [page:Box3 this]

Returns true if this box includes zero points within its bounds. Note that a box with equal lower and upper bounds still includes one point, the one both bounds share.

### [method:Box3 clone]() [page:Box3 this]

Returns a copy of this box.

### [method:Boolean equals]( [page:Box3 box] ) [page:Box3 this]

box -- Box to compare.
Returns true if this box and *box* share the same lower and upper bounds.

### [method:Box3 expandByPoint]( [page:Vector3 point] ) [page:Box3 this]

point -- Point that should be included in the box.
Expands the boundaries of this box to include *point*.

### [method:Box3 expandByScalar]( [page:float scalar] ) [page:Box3 this]

scalar -- Distance to expand.
Expands each dimension of the box by *scalar*. If negative, the dimensions of the box
will be contracted.

### [method:Box3 expandByVector]( [page:Vector3 vector] ) [page:Box3 this]

vector -- Amount to expand this box in each dimension.
Expands this box equilaterally by *vector*. The width of this box will be expanded by the x component of *vector* in both directions. The height of this box will be expanded by the y component of *vector* in both directions. The depth of this box will be expanded by the z component of *vector* in both directions.

### [method:Box3 copy]( [page:Box3 box] ) [page:Box3 this]

box -- Box to copy.
Copies the values of *box* to this box.

### [method:Box3 makeEmpty]() [page:Box3 this]

Makes this box empty.

### [method:Vector3 center]( [page:Vector3 optionalTarget] ) [page:Box3 this]

optionalTarget -- If specified, the result will be copied here.
Returns the center point of this box.

### [method:Sphere getBoundingSphere]( [page:Sphere optionalTarget] ) [page:Box3 this]

optionalTarget -- [page:Sphere] to optionally set the result to.
Gets a sphere that bounds the box.

### [method:Float distanceToPoint]( [page:Vector3 point] ) [page:Box3 this]

point -- Point to measure distance to.
Returns the distance from any edge of this box to the specified point. If the point lies inside of this box, the distance will be 0.

### [method:Box3 setFromCenterAndSize]( [page:Vector3 center], [page:Vector3 size] ) [page:Box3 this]

center -- Desired center position of the box.
size -- Desired x, y and z dimensions of the box.
Centers this box on *center* and sets this box's width, height and depth to the values specified in *size*.

## Source

[link:https://github.com/mrdoob/three.js/blob/master/src/[path].js src/[path].js]