Jump to content
  • Advertisement
Sign in to follow this  
ggp83

OpenGL How to draw over a child window with opengl context?

This topic is 4214 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've programmed a splitter control which contains four child windows. These child windows has four opengl contexts. The problem I have is that when dragging the dividers(to resize the child windows), the dividers are not drawn correctly, instead they just flicker. Is there a simple way to fix this? The only way I can think of is somehow render the child windows before I draw the dividers, but I have no idea of how to that. Since I want this splitter control to be as portable as possible, I won't know if the control actually has any OpenGL child windows at all. Or is there some other way? I'm doing this in C and WINAPI. Thanks for any input :)

Share this post


Link to post
Share on other sites
Advertisement
Guest Anonymous Poster
Not sure but try handling WM_ERASEBKGND, just return 1 from it. Might help with the flickering. I do this as do most other tutorials I see otherwise window gets drawn twice per frame basically.

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!