Advertisement Jump to content
Sign in to follow this  
Unreal

OpenGL Problem with clipping planes

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

Hello!!! I was implementing texture projection for a spot light. but an other projected texture also appears. this is mathematic logical. And i try to clip the place behind the spotlight at the second pass( the pass i draw the scene using the projected texture). I use OpenGL clip planes well.. it works!!! but i get some artifacts. like z-fighting while camera moves. any idea what is going on? this is a part of my code: http://rafb.net/paste/results/4CQSKq94.html thanks in advance

Share this post


Link to post
Share on other sites
Advertisement
often with gl clipplanes than geometry gets callulated differently (goes down a different path) thus the same vertex might be rendered at (1.00001,0,0) with clipplanes off but 0.99999,0,0 with clipplanes on (hence the zfighting)
use polygonoffset

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!