Table of Contents

Struct b3MeshNode

Namespace
Box3D.Native
Assembly
Box3D.NET.Native.dll

A node in the mesh bounding volume hierarchy. Mirror of b3MeshNode.

public struct b3MeshNode

Inherited Members

Remarks

The middle word is a union of an internal-node and a leaf-node layout, both packed as bit fields. Read it through Box3D.Native.b3MeshNode.Axis, Box3D.Native.b3MeshNode.ChildOffset, Box3D.Native.b3MeshNode.IsLeaf and Box3D.Native.b3MeshNode.TriangleCount rather than directly.

Fields

data

The packed union of the internal-node and leaf-node bit fields.

lowerBound

The lower bound of the node bounding box.

triangleOffset

The index of the first triangle for a leaf node.

upperBound

The upper bound of the node bounding box.

Properties

Axis

Gets the split axis of an internal node: zero, one or two.

ChildOffset

Gets the offset of the second child, valid when Box3D.Native.b3MeshNode.IsLeaf is false.

IsLeaf

Gets a value indicating whether this node is a leaf.

TriangleCount

Gets the number of triangles, valid when Box3D.Native.b3MeshNode.IsLeaf is true.