PDA

View Full Version : background color intially doesn't take



graphicsmaniac
04-27-2012, 05:08 PM
Hi,

I'm new to this forum and have a problem I think is pretty basic. I'm using .NEt c# and a opengl wrapper on Windows 7. I use the glClear(GR.GL_COLOR_BUFFER_BIT | GR.GL_DEPTH_BUFFER_BIT) to clear the background. I then set the background color, the screen flickers with the right background color but then reverts to a white background. If I click on the screen the background changes to the right color. This is driving me mad trying to figure it out! Does anybody have a clue as to why its happening?

Brad

tonyo_au
04-28-2012, 12:44 AM
I don't use .NET but with MFC you can see this sort of problem with a window doing an erase background event after your draw. In MFC it pays to override the default erase background enet with a nop function