Jump to content
  • Advertisement
Sign in to follow this  

FBO and depthmap

This topic is 4522 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

Is it correct or even needed to use these function when setting up a depthmap in a FBO?
glTexParameterf(texture_target, GL_TEXTURE_COMPARE_MODE_ARB, GL_COMPARE_R_TO_TEXTURE_ARB);
glTexParameterf(texture_target, GL_TEXTURE_COMPARE_FUNC_ARB, GL_LEQUAL);

As of now I have tried both ways and neither makes a difference? Thanks

Share this post


Link to post
Share on other sites
Advertisement
Those two lines is used when shadowing (when you already have the depth-texture) and tells the hardware to do the computations for you.

When you are "setting up" a depthmap, it shouldn't make any difference.
Go to http://oss.sgi.com/projects/ogl-sample/registry/ and read about the extensions if you arn't sure how they work...

Btw.. what are you trying to do? :) Reading a tutorial on shadowmapping might help. ^_^

Good luck!

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.

Participate in the game development conversation and more when you create an account on GameDev.net!

Sign me up!