Distance To Nearest Surface Node not working, only returns 0. Need fix!
The mental pain is real.... I've been trying to get what I thought was a simple effect going in a material, but no matter what I do, nothing works. All I want to do is to use the distance-to-nearest-surface node in a water shader, but it only ever returns 0. I'm losing my mind as to why this isn't working.
My graph is literally just absolute world position -> distance to nearest surface -> divide by 100 -> lerp between red and blue -> base color output. I don't know what else I should be doing, as this is even what the documentation says should be working. Anyone know what I need to fix?
Goal: make some water that looks like this: http://i.imgur.com/SoW7H2n.gif
asked May 01 '17 at 01:49 AM in Rendering
Distance to nearest surfase is distance field function, so, to use it, make sure that "generate distance field" enabled in your project.
answered May 21 '17 at 04:10 AM
have you tried putting your engine scalability to "epic"? Distance to nearest surface only works on epic resolution.
answered Jul 25 '17 at 07:38 PM
Distance Fields are disabled for computers with Intel Graphics Cards because it causes them to hang, I had trouble with this as well but I looked at the official documentation and there it said what I just told you. If you have an Intel Graphics Card then the problem is likely your computer and not your code or the software itself.
answered Jun 08 '18 at 09:05 PM
shadows setting needs to be set minimum to high for me to see effect
answered Mar 27 '19 at 04:06 PM
Follow this question
Once you sign in you will be able to subscribe for any updates here