Jump to content
  • Advertisement
Sign in to follow this  
Funkyjive

Near clipping plane without distorted fov

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

I am having a little trouble solving a camera problem and unsure as how to fix it. My game is a "Portal" like game where the player can walk through the portals to another point. The portals I represent as a quad that gets passed to the stencil buffer so on and so fourth. Well the problem arises when I try to walk through them. Right when I get close the wall (which also has the portal on it) it goes past the near clipping plane thus does not get rendered anymore. I have tried to fix the problem be adjusting my near clipping plane in glFrustum() to something rediculusly small like .1 which would solve the problem however this distorts the FOV. Any ideas on how to combat this problem?

Share this post


Link to post
Share on other sites
Advertisement
You're definitely going to run into problems as you make the near plane closer and closer. There are several articles out on the web describing the "danger" of using small-valued near-clipping-planes.

You might want to think of an alternative.

Perhaps detect the player's approach and switch to a transition scene. When the player is close enough, he's going to "transport" anyway. Force the eye direction to the portal, and render the portal texture larger and larger as if he's getting closer and closer, until "poof," he's through to another location.

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.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!