Jump to content
  • Advertisement

Archived

This topic is now archived and is closed to further replies.

knight

Problem in Displaying Graphics

This topic is 5964 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 new in OpenGL. I tried drawing a Square and a triangle, with the triangle in front of the square with a distance of 0.01f in the z axis. The problem is that when i rotated the view to the back, the triangle is still in front of the square, which shouldn''t be the case. The grahics generated seems to integrate each other producing some weird lines on the triangle too. Can anyone tell me what is wrong? I just want the triangle to appear sticking on to the square...

Share this post


Link to post
Share on other sites
Advertisement
Make the two shapes farther apart, or use a higher-res depth buffer or make the near and far planes closer together.

Share this post


Link to post
Share on other sites

  • 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!