Package | com.derschmale.wick3d.core.bsp |
Class | public class BspNode |
Subclasses | BspTree |
Property | Defined by | ||
---|---|---|---|
negativeChild : BspNode
This node's child node on the negative side of the partition plane.
| BspNode | ||
partitionPlane : Plane
The partition plane used to divide this node.
| BspNode | ||
positiveChild : BspNode
This node's child node on the positive side of the partition plane.
| BspNode |
Method | Defined by | ||
---|---|---|---|
Creates a new BspNode object.
| BspNode | ||
addTriangle(triangle:Triangle3D):void
Adds a triangle to the node.
| BspNode | ||
addTriangles(triangles:Array):void
Adds an array of triangles to the node.
| BspNode | ||
build():void
Builds the BSP tree from this node on.
| BspNode | ||
Return the leaf (most specific) node containing an object's origin point.
| BspNode | ||
Traverses the bsp-node with this node as a starting point and draws the triangles contained within.
| BspNode |
negativeChild | property |
negativeChild:BspNode
[read-write]This node's child node on the negative side of the partition plane.
Implementation public function get negativeChild():BspNode
public function set negativeChild(value:BspNode):void
partitionPlane | property |
partitionPlane:Plane
[read-write]The partition plane used to divide this node. This will be null if the node is a leaf.
Implementation public function get partitionPlane():Plane
public function set partitionPlane(value:Plane):void
See also
positiveChild | property |
positiveChild:BspNode
[read-write]This node's child node on the positive side of the partition plane.
Implementation public function get positiveChild():BspNode
public function set positiveChild(value:BspNode):void
BspNode | () | constructor |
public function BspNode(parent:BspNode = null)
Creates a new BspNode object.
Parametersparent:BspNode (default = null ) — The parent BspNode which contains the current node.
|
addTriangle | () | method |
public function addTriangle(triangle:Triangle3D):void
Adds a triangle to the node.
Parameterstriangle:Triangle3D — The triangle to add.
|
See also
addTriangles | () | method |
public function addTriangles(triangles:Array):void
Adds an array of triangles to the node.
Parameterstriangles:Array — The triangles to add.
|
See also
build | () | method |
public function build():void
Builds the BSP tree from this node on. It creates new child nodes if necessary, and invokes the function on the new children.
childNodeContaining | () | method |
public function childNodeContaining(object:SpatialObject3D):BspNode
Return the leaf (most specific) node containing an object's origin point.
Parametersobject:SpatialObject3D — The SpatialObject3D of which the position needs to be checked.
|
BspNode |
See also
render | () | method |
public function render(camera:Camera3D, graphics:Graphics):void
Traverses the bsp-node with this node as a starting point and draws the triangles contained within.
Parameterscamera:Camera3D — The camera used to determine on which side of the dividing plane it is, defining the order in which the BSP tree is traversed.
|
|
graphics:Graphics — The target Graphics object to draw to.
|
See also