Color legend method
One triangle as the walks test it: a corner, and the two edges from it.
A struct of public fields, 36 bytes, sent to the GPU byte for byte: GpuTriangle in RayTraversal.fxh declares the same three fields. MeshBlas.Triangles holds them in the tree’s order; the CPU walks test them, and the GPU copy sends them as they are. The BVH page shows it in context.
Names are colored by what they are: a method; values and fields keep the plain color.
Fields
Edge1 →
Vector3 · The second corner less the first. The triangle test, Möller–Trumbore, starts from the two edges, so they are worked out once, when the BLAS is built or refitted, rather than for every ray.
Edge2 →
Vector3 · The third corner less the first.
V0 →
Vector3 · The first corner, in the mesh’s space.
Methods
GpuTriangle() →
GpuTriangle(in Vector3 v0, in Vector3 v1, in Vector3 v2) · The triangle of three corners: V0 is v0, and the edges run from it to v1 and v2.
| Parameter | Type | Description |
|---|---|---|
v0 |
Vector3 |
The first corner. |
v1 |
Vector3 |
The second corner. |
v2 |
Vector3 |
The third corner. |