rtcIntersectNM(3)
β¨ rtcIntersectNM β¨
okay bestie, gather round, because we're about to talk about rtcIntersectNM from the Embree Ray Tracing Kernels 3 manual (section 3, iykyk) π
π NAME π
rtcIntersectNM β finds the closest hits for a stream of M ray packets of size N π
π¦ SYNOPSIS π¦
#include <embree3/rtcore.h>
void rtcIntersectNM(
RTCScene scene,
struct RTCIntersectContext* context,
struct RTCRayHitN* rayhit,
unsigned int N,
unsigned int M,
size_t byteStride
);
πΈ DESCRIPTION πΈ
so basically, rtcIntersectNM finds the closest hits for a stream of M ray packets (that's the rayhit argument) of size N, and it does it against the scene (the scene argument). iconic behaviour honestly π«Ά
the rays argument points to an array of ray and hit packets, and there's a specified byte stride (the byteStride argument) sitting between each ray/hit packet. and if you wanna know how to actually set up and trace rays in the first place? go read Section [rtcIntersect1], it's all there, no cap π
a ray inside a ray stream counts as inactive if itstnearvalue is larger than itstfarvalue. that's the vibe check, that's the rule π
okay and now the important constraints, because these are not optional:
- the packet size N must be larger than 0 β zero packets? not today bestie
- the stream size M can be an arbitrary positive integer, and yes that includes 0
- each ray must be aligned to 16 bytes β 16, exactly, don't play games with alignment π
π EXIT STATUS π
so for performance reasons this function does not do any error checks. like, none. so on failure it will not set any error flags. it's giving "I'm fast and I'm not sorry" π so you better have your inputs correct before you call it, fr fr.
π SEE ALSO π
- [rtcOccludedNM]
kisses, this was rtcIntersectNM(3) out of the Embree Ray Tracing Kernels 3 manual β go trace something pretty bestie π¦β¨ππ
π¦ where this page comes from
- epel 9: embree 3.13.5-4.el9 Β· Apache-2.0
- fedora 43: embree3 3.13.5-9.fc41 Β· Apache-2.0
- fedora 44: embree3 3.13.5-16.fc44 Β· Apache-2.0
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms