Right here is the state of affairs:
- I’ve a shader made in shader graph that’s utilized to a mesh that makes use of the scene depth and renders with some transparency the much less deep it’s (suppose water-like impact)
- Then I’ve a customized render function that passes after every part and makes use of the scene depth to have an effect on the scene from a sure distance of the digital camera (suppose fog-like impact)
I can consider an answer however I do not know methods to execute it: re-write the depth map after the mesh shader has handed in order that when the second shader passes it sees the mesh as very shut.
I feel this pic can illustrate higher what I imply:

Is there a approach to do that, possibly with a distinct thought than my very own? as I’ve been making an attempt to do that however been unsuccessful to date. sigh