Type for a node in the bounding volume hierarchy

Constructor

inlinenew(box:BBox, i0:Int, i1:Int)

Construct from a bounding box and a range

Parameters:

box

bounding box

i0

starting face index (inclusive)

i1

ending face index (exclusive)

Variables

bbox:BBox

Bounding box of this node

begin:Int

starting index of the range of faces contained by the node in the BVH face list (inclusive)

end:Int

ending index of the range of faces contained by the node in the BVH face list (exclusive)

left:BVHNode

Pointer to left child or null

right:BVHNode

Pointer to right child or null

Methods

inlineisLeaf():Bool

Check whether the node is a leaf (has neither left nor right child)