#Depth shader not captured in render texture

1 messages · Page 1 of 1 (latest)

tardy lark
#

I tried many settings on the camera, the render texture, the rendering pipeline but nothing seems to make the shader show up on the render texture the camera outputs. How do I fix this?

#

this is how the shader works

#

The effect doesnt work on anything other than Eye UnityChanThink

alpine moon
# tardy lark this is how the shader works

Raw Screen Position -> A only gives you the depth to fragment position for perspective projections. For orthographic that's always 1.

To work in both projections, you can instead use Position node (View space) -> Split B -> Absolute -> (into B of Subtract)

tardy lark
#

Oh true my camera is orthographic, I forgot about that

#

Perfect, that solved 👍