QGLWidget problem
-
Hello guys,
I am developing an OpenGL application using Qt. Until yesterday I was subclassing
QOpenGLWidgetto create my custom widget but after adding It to the main application which is aQMainWindowwith a few buttons and threeQGraphicsViewit runs really slow. I have tried usingQGLWidgetand the application runs the same as without the OpenGL widget.The problem I have is that the widget that I've made subclassing
QGLWidgetdoes not resize properly (or at least the OpenGL rendering area doesn't).I will give you an example using hellogl2 example from Qt 5.5.
Using
QOpenGLWidgetI get:

Using
QGLWidgetI get:

I just changed the parent class from
QOpenGLWidgettoQGLWidgetthe rest of the code is the same. The same thing happens in my aplication.I have tried to find a solution but I could not. May someone tell me why is this happening and how to solve it?
Thank you,
Catalin