That is probably because you do this in constructor:
You should not explicitly call to initializeGL() or paintGL(); initializeGL is called automatically, and paintGL is called when widget is redrawed, to redraw your widget manually use updateGL(), but not in constructor. You can use QTimer for automatic redrawing. Please, look in documentation and Qt sample projects to see how it is done.





Reply With Quote
Bookmarks