DistanceToNearestSurfacec Exclude Mesh from results without disabling Distance Fields for it?

Nonlin
Wed, 11 Jan 2023 21:25:13 +0000
Rendering

Essentially I want to use a material on a mesh that make use of DistanceToNearestSurface but in order for it to work the results of the DistanceToNearestSurface needs to exclude its self.

The issue there is, I want this mesh with this material to get the distance fields from other meshes with the same material but if I have to disable affects distance field on the mesh then I can’t do this.

How can I keep my cake and eat it too?

I though about maybe doing a conditional check where if the DistanceField result is of a certain distance, ignore that and then when it exceeds it use the result but this didn’t seem to work as i thought it would.

6 posts - 5 participants