Quote Originally Posted by sanjayshelke View Post
This forces me to implement paintEvent().Because if i reimpleent paintGL() it is not called at all.
The thing is paintGL() is called from the paintEvent after the context has been set up correctly. You must have done something wrong. Check if it works when the widget is outside QGraphicsScene.

And the thing is that code is working on windows.
Windows has a different architecture than other platforms.

I still suggest you implement the pyramid without QGLWidget. It should be possible using just the pixel buffer (or something else, I'm not a GL expert).