Jump to content
  • Advertisement
Sign in to follow this  
CoiN

Win32 Controls Question

This topic is 4802 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 making a fairly simple game using GDI and I've got a small problem which I can't seem to figure out (I'm not really that experienced with Win32). I'm drawing all my graphics at the moment through my own function (called from inside the message loop) and I've set up a pretty simple backbuffer/flipping system. The thing is I'd like to be able to use windows controls on the screen at the same time, but when I create a button it gets written over by the Clear() and Flip(). Is there anyway to stop this? A way I can redraw the buttons when I want too (i.e. After I have flipped the other graphics to the window)? I know this question probably seems pretty stupid but I have looked around and can't seem to find anything. Thanks, Jon Lowe

Share this post


Link to post
Share on other sites
Advertisement
Try setting the WS_CLIPCHILDREN style on the main window when you create it; that should help.

Share this post


Link to post
Share on other sites
Hi

After recent experience with the GDI, using a backbuffer and flipping will become very slow. I rather opted for a combination of ExcludeClipRect(), SelectRgn(), RectVisible() (Not sure if these are the completely correct spelling of the functions). You can look at Catch 22 Flicker Free Drawing

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!