Search the Community
Showing results for tags 'rayhittest'.
Found 1 result
I am trying to use rayhittest() in a snippet to test for intersections from a primitive to an arbitrary location. (A camera, a light etc) I have an example that works in SOPs in my .hip using intersect, however I need something that works at render-time. I have tried adding a scope to self, however, I am not sure if my syntax is correct. I have something like; dist = rayhittest(origin, ray, 0.05, 'scope', 'self'); If I bind dist to a hard coded value, I can see that something is coming out of the snippet. Any pointers? Any easier ways to do shader based intersections? Hip file attached Cheers, Aaron. rayPigs.hipnc