shadmar Posted May 25, 2013 Share Posted May 25, 2013 If eligble for a fix. I can't sem to fetch depth. texture0 - color --> ok texture1 - all black, but should have been depth. texture2 - blur --> ok. HP Omen - 16GB - i7 - Nvidia GTX 1060 6GB Link to comment Share on other sites More sharing options...
Josh Posted June 21, 2013 Share Posted June 21, 2013 Just because you write the depth info to the screen doesn't mean it will be visible. Depth is stored in a nonlinear equation and that accuracy will be lost when it's converted from a floating point to an 8-bit value. My job is to make tools you love, with the features you want, and performance you can't live without. Link to comment Share on other sites More sharing options...
shadmar Posted June 22, 2013 Author Share Posted June 22, 2013 How can I then sample this depth for for a DOF effect using this AddPostEffect() ? I sampled it using this vec4 depth = texture2D(texture1,ex_texcoords0); HP Omen - 16GB - i7 - Nvidia GTX 1060 6GB Link to comment Share on other sites More sharing options...
Admin Posted June 25, 2013 Share Posted June 25, 2013 Check the LE2 code to see how to convert a non-linear depth value to a linear depth...there's a function called DepthToZPosition(), or something like that. Link to comment Share on other sites More sharing options...
Recommended Posts