Jump to content
  • Advertisement
Sign in to follow this  

writing depth value in shader

This topic is 3800 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hi, i'm having a problem with writing a depth value (i think that is the problem anyway :( ) I'm using Nvidia 7950 GX2 card. Basically, i'm trying to copy depth buffer 1 to depth buffer 2. I know that you need something like below when reading depth texture in nvidia 6/7 series. depth = dot(tex2D(depthSourceSampler, texCoord).arg, float3(0.996093809371817670572857294849, 0.0038909914428586627756752238080039, 1.5199185323666651467481343000015e-5)); However, after copying this depth value to destination depth buffer, it looks like everything that is using the dst. depth buffer is getting wrong depth testing. (drawing over previously rendered scenes) Am i missing something? In other nvidia cards (such as 8800 series), i could just use tex2D to read depth texture and write that value without problem. Thanks in advance

Share this post

Link to post
Share on other sites
Sign in to follow this  

  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!