Hi, I’m currently starting to write a radar imaging program using optix prime. The basic breakdown is that I make a set of rays that shoot to the center of every facet of a triangle mesh and read the far-field response using information about the angle of intersection between the ray origin and the triangle plane. So far, it’s been working fine.
The issue is that I would like to support refraction/reflection by making new rays at the point of intersection. I can make this new second set of rays (would just be a matter of cross referencing the triangle ID of the hits with the ray origin, which all initial rays share), but then we have a bunch of different origins for this second set of rays, and I can’t see any easy way to find the angle of incidence for this second set of rays without knowing what their common origin is.
My question boils down to: Is there any way to return some information about the ray that caused the hit within the hit data structure? As far as I can tell (I may well have missed something) the only information I get back is t (the distance), triId (the ID of the triangle), u and v (barycentric coordinates; i.e., where on the triangle it hit). Or is Optix prime not going to work for my purposes? The simple API is extremely attractive since I only need simple static imaging, and I’d prefer to use prime, but if it’s not possible I’ll have to give it up.
EDIT: Oh, and my hit buffer has like 250k hits, even though 249750 of them are misses. What’s up with that? Does it just make a “hit” for every ray-facet pair?