[Qt-interest] QPainter background on QGLWidget
Sean Hignett
sean at intelligent-design.ca
Mon Dec 14 03:09:14 CET 2009
Hello all,
I am new to Qt, and working on some OpenGL sample code from the C++ Gui Programming book. The VowelCube example demonstrates the ability to use QPainter "behind" OpenGL rendering. It uses a radiant gradient background, and then paints an OpenGL cube over top (or so it is supposed to).
When I use the downloaded sample code with Qt 4.6 (vowelcode), everything works, but the actual OpenGL cube is not rendered. If I comment out the QPainter based background (drawBackground), the cube will render.
http://www.informit.com/articles/article.aspx?p=1405557&seqNum=2
(code and example shown here)
Again, this is code taken from the C++ Gui Programming book based on Qt 4.3. Has something changed since that version with respect to this functionality? Trying get this to work as depicted is making me bald :)
Working on Qt 4.6 on OSX, but tried on Ubuntu as well, same result.
Thanks,
Sean
More information about the Qt-interest-old
mailing list