Skip to content

Class BoxSet

Namespace: Apogee.Core.Numerics
Assembly: Apogee.Core.dll

Axis-aligned boxes as separate arrays of centers and half extents (structure of arrays), so that a vector instruction tests eight (or four) of them against a plane at once. The arrays are padded to a multiple of with boxes of no size at the origin, which a kernel tests like any other; their results are meaningless and ignored (only the first matter).

public sealed class BoxSet

Inheritance

object ← BoxSet

Inherited Members

object.Equals(object?), object.Equals(object?, object?), object.GetHashCode(), object.GetType(), object.ReferenceEquals(object?, object?), object.ToString()

Constructors

BoxSet(int)

public BoxSet(int count)

Parameters

count int

Properties

Count

public int Count { get; }

Property Value

int

PaddedCount

public int PaddedCount { get; }

Property Value

int

ResultLength

The number of bytes a result needs: one bit per box.

public int ResultLength { get; }

Property Value

int

Methods

Get(int)

public (Vector3 Center, Vector3 Extents) Get(int index)

Parameters

index int

Returns

(Vector3 Center, Vector3 Extents)

Set(int, Vector3, Vector3)

public void Set(int index, Vector3 center, Vector3 extents)

Parameters

index int

center Vector3

extents Vector3