Original Post
I pulled this out of a necroed thread on the topic: // pnt is still in eye-space float2 ss = ( newPoint.xy / newPoint.z ) * float2( 0.75, 1.0 ); float2 tx = ss * 0.5 + 0.5; float depth = tex2D( depthMap, tx ); I'm doing exactly this above to sample my texture from a reconstructed position, but it only works if the FOV I've setup is 90 degrees. 90 degrees having the magical property that the far distance is the same as the sideways distance so a point in the corner of the screen is going to map to -1,-1 when one is divided by the other. However, if I set up say 60 degrees, then my far corners look like this (reflected for all corners): -71,-54,100 So now when I divide -71 by 100 in the top/left corner, my UV will be 0.71 and this isn't sampling the edge of my texture iyswim. What am I missing here? I've tried just scaling the divide but that didn't work either. Should z in this example range 0-1 and then get multiplied by [71][54] or does this stuff only work with a FOV of 90 or hopefully some other answer that's just not reaching my brain. Many thanks...