Qt and OpenGL Mechanics



  • Hello all,
    I am interested in using Qt to develop a hardware accelerated program (not a game). I read somewhere that the Qt integration of OpenGL uses an off screen buffer to render to, and then uses a getPixels call to copy the image to memory for displaying. There is the obvious performance penalty there with that call. Is this true or will Qt go into full hardware acceleration mode if setup properly (including hardware accelerated menus, etc) such that it avoids copying pixels back and forth between CPU memory and GPU?

    Thanks!


  • Moderators

    If you use QML, it is rendered directly using OpenGL. If you use QtWidgets, the painting is done via CPU. It is possible to use QOpenGLWidget to force GL rendering of widgets, too. I don't know if it uses offscreen buffer in that case.


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.