Hello when i re-size my GLUT window it blinks its very annoying. I have Ubuntu and installed fresh ATI drivers with Open GL 4.1. Also on start if I just move window my triangle disappear.
PICTURE:
On start it looks: http://dl.dropbox.com/u/15084870/Screenshot-3.png
When i move it: http://dl.dropbox.com/u/15084870/Screenshot-4.png
When i’m re-sizing (you can see thie pice shows what’s under the GLUT window and it blinks): http://dl.dropbox.com/u/15084870/Screenshot-5.png
Thanks a lot.
PS. Transparency on Linux doesn’t work? I try to set alpha to Triangle but it doesn’t work the same in Qt.
mobeen
July 6, 2011, 3:34am
#2
Could u show us ur resize/relevant code please? We donot have magic eyes that could extract the code from the image
Oh sorry here is the Code : http://dl.dropbox.com/u/15084870/Triangle.cpp
It’s a Triangle sample form CodeBible OpenGl
mobeen
July 6, 2011, 3:53am
#4
Hi,
For the main problem, could u try adding glFinish() after glutSwapBuffers call and see if this helps. For transparency to work, you need to enable blending
glEnable(GL_BLEND);
glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);
Ok when i add glFinish it doesn’t change anything the same. And Alpha works thanks
mobeen
July 6, 2011, 4:54am
#6
Could u put glFinish before glutSwapBuffers call and see if it helps.
mobeen
July 6, 2011, 5:06am
#8
The code that u have given works fine on my machine.
You run this on Linux? Maybe something is bad configured i will try if anyone has this problem and solve it please write
Thanks a lot!
mobeen
July 6, 2011, 5:34am
#10
nope I am on windows 7, one thing you can do is add this line at the start of the render function and see if it gives an assertion.
//include <cassert> at the top ofcourse
assert(glGetError() == GL_NO_ERROR);
XD it blocks my computer i cant move even window
mobeen
July 6, 2011, 5:47am
#12
DO u get any assertion? check the console output.
_arts
July 6, 2011, 6:42am
#13
You might have a driver bug.
Also your resize function should have projection and modelview initialization.
Your render function might also lack some view statement.
OK thanks guys i think is’s a bug in driver.