Package | away3d.bounds |
Class | public class BoundingVolumeBase |
Inheritance | BoundingVolumeBase Object |
Subclasses | AxisAlignedBoundingBox, BoundingSphere, NullBounds |
Property | Defined By | ||
---|---|---|---|
aabbPoints : Vector.<Number> [read-only]
Returns a vector of values representing the concatenated cartesian triplet of the 8 axial extremities of the bounding volume. | BoundingVolumeBase | ||
boundingRenderable : WireframePrimitiveBase [read-only]
Returns the bounding renderable object for the bounding volume, in cases where the showBounds
property of the entity is set to true. | BoundingVolumeBase | ||
max : Vector3D [read-only]
The maximum extreme of the bounds
| BoundingVolumeBase | ||
min : Vector3D [read-only]
The minimum extreme of the bounds
| BoundingVolumeBase |
Property | Defined By | ||
---|---|---|---|
_aabbPoints : Vector.<Number> | BoundingVolumeBase | ||
_aabbPointsDirty : Boolean = true | BoundingVolumeBase | ||
_boundingRenderable : WireframePrimitiveBase | BoundingVolumeBase | ||
_max : Vector3D | BoundingVolumeBase | ||
_min : Vector3D | BoundingVolumeBase |
Method | Defined By | ||
---|---|---|---|
Creates a new BoundingVolumeBase object
| BoundingVolumeBase | ||
classifyToPlane(plane:Plane3D):int | BoundingVolumeBase | ||
Clones the current BoundingVolume object
| BoundingVolumeBase | ||
containsPoint(position:Vector3D):Boolean
Method for calculating whether the given position is contained within the bounding volume. | BoundingVolumeBase | ||
disposeRenderable():void
Disposes of the bounds renderable object. | BoundingVolumeBase | ||
fromExtremes(minX:Number, minY:Number, minZ:Number, maxX:Number, maxY:Number, maxZ:Number):void
Sets the bounds to the given extrema. | BoundingVolumeBase | ||
fromGeometry(geometry:Geometry):void
Updates the bounds to fit a Geometry object. | BoundingVolumeBase | ||
fromSphere(center:Vector3D, radius:Number):void
Sets the bound to fit a given sphere. | BoundingVolumeBase | ||
fromVertices(vertices:Vector.<Number>):void
Updates the bounds to fit a list of vertices
| BoundingVolumeBase | ||
isInFrustum(mvpMatrix:Matrix3D):Boolean
Tests if the bounds are in the camera frustum. | BoundingVolumeBase | ||
nullify():void
Sets the bounds to zero size. | BoundingVolumeBase | ||
rayIntersection(position:Vector3D, direction:Vector3D, targetNormal:Vector3D):Number
Method for calculating whether an intersection of the given ray occurs with the bounding volume. | BoundingVolumeBase |
Method | Defined By | ||
---|---|---|---|
BoundingVolumeBase | |||
updateAABBPoints():void | BoundingVolumeBase | ||
updateBoundingRenderable():void | BoundingVolumeBase |
_aabbPoints | property |
protected var _aabbPoints:Vector.<Number>
_aabbPointsDirty | property |
protected var _aabbPointsDirty:Boolean = true
_boundingRenderable | property |
protected var _boundingRenderable:WireframePrimitiveBase
_max | property |
protected var _max:Vector3D
_min | property |
protected var _min:Vector3D
aabbPoints | property |
aabbPoints:Vector.<Number>
[read-only] Returns a vector of values representing the concatenated cartesian triplet of the 8 axial extremities of the bounding volume.
public function get aabbPoints():Vector.<Number>
boundingRenderable | property |
boundingRenderable:WireframePrimitiveBase
[read-only] Returns the bounding renderable object for the bounding volume, in cases where the showBounds property of the entity is set to true.
public function get boundingRenderable():WireframePrimitiveBase
See also
max | property |
max:Vector3D
[read-only] The maximum extreme of the bounds
public function get max():Vector3D
min | property |
min:Vector3D
[read-only] The minimum extreme of the bounds
public function get min():Vector3D
BoundingVolumeBase | () | Constructor |
public function BoundingVolumeBase()
Creates a new BoundingVolumeBase
object
classifyToPlane | () | method |
clone | () | method |
public function clone():BoundingVolumeBase
Clones the current BoundingVolume object
ReturnsBoundingVolumeBase — An exact duplicate of this object
|
containsPoint | () | method |
public function containsPoint(position:Vector3D):Boolean
Method for calculating whether the given position is contained within the bounding volume.
Parameters
position:Vector3D — The position in local coordinates to be checked.
|
Boolean — A Boolean value representing the detection of a contained position.
|
createBoundingRenderable | () | method |
disposeRenderable | () | method |
public function disposeRenderable():void
Disposes of the bounds renderable object. Used to clear memory after a bounds rendeable is no longer required.
fromExtremes | () | method |
public function fromExtremes(minX:Number, minY:Number, minZ:Number, maxX:Number, maxY:Number, maxZ:Number):void
Sets the bounds to the given extrema.
Parameters
minX:Number — The minimum x value of the bounds
| |
minY:Number — The minimum y value of the bounds
| |
minZ:Number — The minimum z value of the bounds
| |
maxX:Number — The maximum x value of the bounds
| |
maxY:Number — The maximum y value of the bounds
| |
maxZ:Number — The maximum z value of the bounds
|
fromGeometry | () | method |
public function fromGeometry(geometry:Geometry):void
Updates the bounds to fit a Geometry object.
Parameters
geometry:Geometry — The Geometry object to be bounded.
|
fromSphere | () | method |
public function fromSphere(center:Vector3D, radius:Number):void
Sets the bound to fit a given sphere.
Parameters
center:Vector3D — The center of the sphere to be bounded
| |
radius:Number — The radius of the sphere to be bounded
|
fromVertices | () | method |
public function fromVertices(vertices:Vector.<Number>):void
Updates the bounds to fit a list of vertices
Parameters
vertices:Vector.<Number> — A Vector.<Number> of vertex data to be bounded.
|
isInFrustum | () | method |
public function isInFrustum(mvpMatrix:Matrix3D):Boolean
Tests if the bounds are in the camera frustum.
Parameters
mvpMatrix:Matrix3D — The model view projection matrix for the object to which this bounding box belongs.
|
Boolean — True if the bounding box is at least partially inside the frustum
|
nullify | () | method |
public function nullify():void
Sets the bounds to zero size.
rayIntersection | () | method |
public function rayIntersection(position:Vector3D, direction:Vector3D, targetNormal:Vector3D):Number
Method for calculating whether an intersection of the given ray occurs with the bounding volume.
Parameters
position:Vector3D — The starting position of the casting ray in local coordinates.
| |
direction:Vector3D — A unit vector representing the direction of the casting ray in local coordinates.
| |
targetNormal:Vector3D — The vector to store the bounds' normal at the point of collision
|
Number — A Boolean value representing the detection of an intersection.
|
updateAABBPoints | () | method |
protected function updateAABBPoints():void
updateBoundingRenderable | () | method |
protected function updateBoundingRenderable():void