BoundingSphere represents a spherical bounding volume defined by a center point and a radius. This bounding volume is useful for point lights.

Constructor

new()

Creates a new BoundingSphere object

Variables

read onlyradius:Float

Methods

containsPoint(position:Vector3D):Bool

@inheritDoc

fromExtremes(minX:Float, minY:Float, minZ:Float, maxX:Float, maxY:Float, maxZ:Float):Void

@inheritDoc

fromSphere(center:Vector3D, radius:Float):Void

@inheritDoc

isInFrustum(planes:Vector<Plane3D>, numPlanes:Int):Bool

todo: pass planes? @inheritDoc

nullify():Void

@inheritDoc

Inherited Variables

Defined by BoundingVolumeBase

read onlyaabbPoints:Vector<Float>

read onlymax:Vector3D

read onlymin:Vector3D

Inherited Methods

Defined by BoundingVolumeBase

disposeRenderable():Void

Disposes of the bounds renderable object. Used to clear memory after a bounds rendeable is no longer required.

fromGeometry(geometry:Geometry):Void

Updates the bounds to fit a Geometry object.

Parameters:

geometry

The Geometry object to be bounded.

fromVertices(vertices:Vector<Float>):Void

Updates the bounds to fit a list of vertices

Parameters:

vertices

A Vector.<Number> of vertex data to be bounded.

overlaps(bounds:BoundingVolumeBase):Bool

Tests if the bounds overlap other bounds, treating both bounds as AABBs.