Jump to content
  • Advertisement
Sign in to follow this  
magneeto

OpenGL flickering viewports

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

hi, i'm writing an opengl program where i have two viewports in that same window. one is bigger than the other. in the bigger viewport i have a rotating sphere. the problem is that the smaller viewport flickers all the time. but if i don't rotate the object then there is no flickering. both the viewports show the same object. how do i get rid of this problem? magneeto

Share this post


Link to post
Share on other sites
Advertisement
We will probably need more data about what exactly you are doing (perhaps some source code) in order to be much help here. A couple thoughts though:

1. Are you using double buffering? If not, try switching to a double buffered pixel format and see if that helps. In general this should reduce flickering.

2. Are you clearing when you don't need too? A static scene won't flicker if you are just drawing the same thing over and over, but clears with a single buffered window can cause flickering.

3. Viewports do not clip glClear. This means that clearing one viewport will clear the other. Use a quad to clear the area, or use glScissor.

Share this post


Link to post
Share on other sites
i am using double buffering and i am not clearing too much also. the source is really long and i don't know which part to attach. i'll try to give some more information about what i'm doing.

i have a textured mapped earth (actually multiple texture mapping--there is a rotating cloud aroud it). the earth is rotating in both the viewports. and when i stop this rotation (disabling it in the idle function) there is no flickering. as soon as i start the rotation one of the viewports start flickering. is this because of the texture mapping ?

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!