Jump to content
  • Advertisement
Sign in to follow this  
soconne

using FarClip but not have geometry clipped

This topic is 4655 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 there any way, after calling gluPerspective with some given FarClip value, NOT to have a piece of geometry clipped by that value? Basically, lets say your FarClip value is 1000, and you draw something at 2000. How can you prevent it from being clipped. I've already tried disabling depth testing, but that does not work.

Share this post


Link to post
Share on other sites
Advertisement
When you set the far plane, you set it so that 1.0 in the Z buffer corresponds to your far plane. Anything greater than 1.0 might be culled before it even gets to the depth test (although it's not clear that this behavior is standards conforming).

What I would try would be to re-specify the transformation matrix using 3000 as your far plane, and turning off depth write and depth test. Of course, that means it'll draw in front of anything that's closer than that, too.

Share this post


Link to post
Share on other sites
Guest Anonymous Poster
Having a far clip but not far clipping sounds contradictory. Do you mean somehow not having a far clip? If so, there is something that may help - pushing the far clip plane to infinity.

Check out:
http://developer.nvidia.com/object/robust_shadow_volumes.html
Look at the PDF called: "Practical and Robust Shadow Volumes"
and check out the section:
OUR ALGORITHM / Approach / Far Plane at Infinity

It shows how to compose the matrix for that very effect.

There are many sources for this info. This is just one of them.

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!