B.Math.Frustum()

Represents a frustum.

To create the object use B.Math.makeFrustum().

PROPERTIES:

{B.Math.Plane} left

Left plane.

Right plane.

{B.Math.Plane} top

Top plane.

{B.Math.Plane} bottom

Bottom plane.

{B.Math.Plane} near

Near plane.

{B.Math.Plane} far

Far plane.

METHODS:

clone()

Clones this frustum to a new frustum.

RETURNS:

copy(frustum)

Copies a given frustum into this frustum.

PARAMETERS:

{B.Math.Frustum} frustum

RETURNS:

set(left, right, top, bottom, near, far)

Sets this frustum from planes.

PARAMETERS:

{B.Math.Plane} left

{B.Math.Plane} right

{B.Math.Plane} top

{B.Math.Plane} bottom

{B.Math.Plane} near

{B.Math.Plane} far

RETURNS:

fromArray(array, offset)

Sets this frustum from a part of array.

PARAMETERS:

{Array.<number>} array

{number} [offset] = 0

RETURNS:

{number}

new offset

toArray(array, offset)

Sets this frustum to a part of array.

PARAMETERS:

{Array.<number>} array

{number} [offset] = 0

RETURNS:

{number}

new offset

fromMatrix(matrix)

Sets this frustum from a view-projection matrix.

PARAMETERS:

{B.Math.Matrix4} matrix

RETURNS:

cornerPoints(result)

Returns corner points of this frustum.

PARAMETERS:

{Array.<B.Math.Vector3>} [result]

omit if you want to return newly created array

RETURNS:

{Array.<B.Math.Vector3>}

THROWS:

{Error}

if frustum has invalid set of planes

contain(object)

Check if this frustum contains an object.

PARAMETERS:

RETURNS:

{boolean}

THROWS:

{Error}

if the object argument has unsupported type

equal(frustum)

Checks for strict equality of this frustum and another frustum.

PARAMETERS:

{B.Math.Frustum} frustum

RETURNS:

{boolean}

PROPERTIES:

METHODS: