Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Threaded QOpenGLWidget direct rendering
Qt 6.11 is out! See what's new in the release blog

Threaded QOpenGLWidget direct rendering

Scheduled Pinned Locked Moved Unsolved General and Desktop
1 Posts 1 Posters 1.0k Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • S Offline
    S Offline
    snow45
    wrote on last edited by
    #1

    I'm in the process of upgrading from Qt 4.8 to Qt 5.9. What I want to do is do all of my opengl rendering in a separate thread like I could in Qt 4.8 with QGLWidget. I used to be able to call QGLWidget::makeCurrent in a separate thread and have it render straight to the screen. Is there a way to do that in Qt 5 without having to move the QOpenGLContext from the main thread to the worker thread like in the Threaded QOpenGLWidget example.

    My reason for this is there are a few functions in the GUI thread that can lock the GUI thread for a couple of seconds so that my opengl rendering doesn't run. I want my opengl thread to render to the screen no matter if the GUI thread is locked. I know the first thought is to move those GUI functions into a worker thread, but is there any way to do this so that rendering directly like it did in Qt 4?

    1 Reply Last reply
    1

    • Login

    • Login or register to search.
    • First post
      Last post
    0
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Get Qt Extensions
    • Unsolved