Undesired OpenGL front buffer clearing

BlitzPlus Forums/BlitzPlus Programming/Undesired OpenGL front buffer clearing

JoshK(Posted 2005) [#1]
When another window is dragged over an OpenGL viewport, It erases the underlying pixels:


I tried adding the CS_SAVEBITS style to the window, which had no effect:
style=GetClassLong(hwnd,GCL_STYLE)+CS_SAVEBITS
SetClassLong hwnd,GCL_STYLE,style

Here is a demo which demonstrates the problem. I need to either set the window so it "saves" the underlying pixels, or I need to detect the repaint event and flip the buffer:
http://www.leadwerks.com/post/glprob.zip

The title bar displays the hwnd to the window, so you should be able to tweak the window as the program runs.


Kuron(Posted 2005) [#2]
I would try asking this on the forums at the OpenGL.org site and even the GameDev.net site. Many smart folks on those forums ;c)


JoshK(Posted 2005) [#3]
Okay, I got it working.

The lack of a "brushless" class in BlitzPlus is going to hurt things.

God, this is hard to implement on more than one window. A BlitzPlus "Window Paint" message would be REALLY helpful.