animatrix_
Hi,
I don't think xyzdist would return all of them. I haven't tested this but I suspect it returns the polygon whose normal is pointing towards the origin point.
In any case if you want to detect all overlapping polygons, you could use xyzdist first to find the nearest prim and then fire a ray in that direction using the intersect_all VEX function to find all intersected prims along that direction:
https://www.sidefx.com/docs/houdini/vex/functions/intersect_all.html [www.sidefx.com]
intersect_all sounds like a good idea, but I tried this on a point inside of a tetrahedral and intersect_all doesn't seem to be aware that it's within the prim unfortunately, which *does* work when using xyzdist.
An idea for grabbing all prims is to use within a render time shader and accumulate samples, but looping over all prims is going to be too expensive.
A constraint for my requirement is that the points that define the prim don't necessarily overlap, just end up generating a prim that can be found in the same sample point.