Question

hi I'm using MFC SDI application for my mid term project. but every time i draw scene (with GDI) and "invalidate()" it flicking occur.

I use DWM for double buffering and removing flicking but it rarely occur. i think problem is in the vertical syncing.what can I do for enabling virtual syncing

Was it helpful?

Solution

Try overriding OnEraseBkgnd and simply return TRUE and do nothing else. This will prevent the background being "erased" each time you draw. Returning TRUE says "I've erased it`, even if you've done no such thing.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top