Quantcast
Channel: Questions in topic: "hlsl"
Viewing all articles
Browse latest Browse all 206

How do I get the depth texture from a hlsl shader? (HDRP)

$
0
0
I'm trying to simply sample the camera's depth texture from an hlsl shader. Supposedly all you need to do is declare a sampler2d "_CameraDepthTexture" but this has not worked for me. I've tried sampling with tex2D and tex2Dlod but the output is a solid grey . I've tried sampling with UV and screen position. Anyone know what I'm doing wrong? Thanks.

Viewing all articles
Browse latest Browse all 206

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>