Is there a way to show the objects behind the surface, with the scene depth being more of an overlay?
Also I need it to measure the depth from the surface to the object, rather than from the camera. Is there a way to use scene depth in this way, or a different solution?
Keep in mind that you need to use Translucent Materials. Else you wouldn’t be able to see Depth behind the Slime.
A mixture of Translucent and Subsurface Scattering should do the trick.
I set up this translucent material with default lit shading, but subsurface indeed ads a little more gradients to the surface since it is “emiting” the same color content. One thing that gave me some troubles was the triangles of the uneven blobby objects (eg the rock) the tris always were appeared in front of, while they should have been culled. Translucent projection does not support the proper sorting for the triangles, so you have to take care of those by using the depth culling technique described in Tom Looman’s article . It will require to render the content in the custom depth channel as well to have a proper depth information available for the culling.
Wonderfully helpful thanks guys! Konflict that slime shader is brilliant, exactly the kind of thing we’re going for. Did you ever use it in a final project? Thanks for the info you’ve given me a great starting point, really appreciated.