skip to content
==> README.md <==
1# @ajax/pathtrace-intersect
2
3The nearest hit of a ray in (EPS, tmax) against a scene's quads, spheres and triangles, with the triangle
4mesh skipped unless its bounding sphere is hit: `pt_intersect<suffix>(sc, &layout, o, d, tmax, &id)`
5returns t and the hit id (0 none, 1 + i quad i, `PT_ID_SPH` + i, `PT_ID_TRI` + i). A template header
6(`pathtrace/t_intersect.h`) over the float contract of `@ajax/pathtrace-math`. Freestanding.
7
8**Ported from** `crates/pathtrace-core/src/lib.rs` (`intersect`), operation for operation. **Tested**
9through 4000 camera samples and four rendered tiles per float type against the Rust.