Details
-
Bug
-
Resolution: Cannot Reproduce
-
P2: Important
-
None
-
5.4.1
-
None
-
Mac OS X 10.9.5
iMac mid 2011 (Intel Core i5 2.5 Ghz, 16GB RAM)
AMD Radeon HD 6750M 512MB (Supports OpenGL 4.1)
Description
To reproduce (see included OpenGLWidgetTest.zip)
- Create a QOpenGLWidget as a child for another QWidget.
- Set its QSurfaceFormat to use OpenGL version 3.3 Core Profile.
- Set everything up to draw a triangle.
- Now no triangle shows up, and calling glGetError() first in paintGL() returns GL_INVALID_OPERATION.
The included stack trace is generated using the Apple OpenGL profiler and points out that the error is generated by a glViewport call, called indirectly by QOpenGLContext::makeCurrent()
Using a QWindow with manually setting the surface type to be an OpenGL surface does enable proper rendering using OpenGL 3.3 Core Profile.
(The included QWindow example is from http://github.com/advancingu/Qt5OpenGL, adapted to work with OpenGL 3.3 Core on Mac).
However I suppose QOpenGLWidget should work fine and using QWindow is not an option as our actual application that we're trying to build involves a far more complex UI than a simple OpenGL window.
Attachments
Issue Links
- resulted in
-
QTBUG-46016 Application with QOpenGLWidget on heap crashes on exit
-
- Closed
-