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. QOpenGLWidget not working unless in main window
Forum Updated to NodeBB v4.3 + New Features

QOpenGLWidget not working unless in main window

Scheduled Pinned Locked Moved Unsolved General and Desktop
4 Posts 2 Posters 952 Views 1 Watching
  • 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.
  • P Offline
    P Offline
    Piero
    wrote on last edited by
    #1

    Hello everybody,

    My QOpenGLWidget works perfectly in the main window of the application. What can be the reason why it doesn't work anymore when it is not in the main window?

    It seems like, when the containing window is not the main window, the QOpenGLWidget's off-screen buffer is not copied back on screen, in its widget area.

    Any clue?

    I'm working on Windows 7, Qt 5.5, on a Intel i7 machine equipped with NVidia Quadro K2100M graphics card.

    kshegunovK 1 Reply Last reply
    0
    • P Piero

      Hello everybody,

      My QOpenGLWidget works perfectly in the main window of the application. What can be the reason why it doesn't work anymore when it is not in the main window?

      It seems like, when the containing window is not the main window, the QOpenGLWidget's off-screen buffer is not copied back on screen, in its widget area.

      Any clue?

      I'm working on Windows 7, Qt 5.5, on a Intel i7 machine equipped with NVidia Quadro K2100M graphics card.

      kshegunovK Offline
      kshegunovK Offline
      kshegunov
      Moderators
      wrote on last edited by
      #2

      @Piero
      Hi,
      Can you try making the containing widget native and see if the problem persists.

      Kind regards.

      Read and abide by the Qt Code of Conduct

      P 1 Reply Last reply
      0
      • kshegunovK kshegunov

        @Piero
        Hi,
        Can you try making the containing widget native and see if the problem persists.

        Kind regards.

        P Offline
        P Offline
        Piero
        wrote on last edited by
        #3

        @kshegunov

        Hi,

        thank you for answering to my question.

        I think it is a good hint. But I tried to either 1) set all parents to native and 2) set all widgets in the window to native. And it didn't work in both cases.

        Actually, if it worked, I'm not sure how that would explain why it works when the QOpenGLWidget lies in the main window of the application, into and among other widgets that are mostly non native. And why it doesn't work when the same window is not the main window of the application.

        I guess there must be something to do with the other window, that actually has some graphics too.

        But it was worth trying, thank you.

        Piero

        kshegunovK 1 Reply Last reply
        0
        • P Piero

          @kshegunov

          Hi,

          thank you for answering to my question.

          I think it is a good hint. But I tried to either 1) set all parents to native and 2) set all widgets in the window to native. And it didn't work in both cases.

          Actually, if it worked, I'm not sure how that would explain why it works when the QOpenGLWidget lies in the main window of the application, into and among other widgets that are mostly non native. And why it doesn't work when the same window is not the main window of the application.

          I guess there must be something to do with the other window, that actually has some graphics too.

          But it was worth trying, thank you.

          Piero

          kshegunovK Offline
          kshegunovK Offline
          kshegunov
          Moderators
          wrote on last edited by
          #4

          @Piero
          Well, nothing else comes to mind. Could you attach a screenshot (you can use ![alt text](http://imageurl) to do that) of the described problem. Perhaps it will attract some better suggestions.

          Kind regards.

          Read and abide by the Qt Code of Conduct

          1 Reply Last reply
          0

          • Login

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