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. Stereo buffering crash

Stereo buffering crash

Scheduled Pinned Locked Moved General and Desktop
openglmacmac os xstereo buffersqt 5.5
4 Posts 3 Posters 2.1k 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.
  • A Offline
    A Offline
    angelag
    wrote on last edited by angelag
    #1

    I'm currently trying to port a Qt 4.8.2 application to Qt 5.5 on MacOSX 10.10.4.
    Everything compiles just fine but when I start the application it crashes upon the creation of a new QGLWidget. The crash report is unfortunately not very helpful to me and I currently don't know how to fix this:

    <pre><code>
    Thread 0 Crashed:: Dispatch queue: com.apple.main-thread
    0 libobjc.A.dylib 0x00007fff8a1010dd objc_msgSend + 29
    1 libqcocoa.dylib 0x000000010f1b8073 QCocoaIntegration::createPlatformOpenGLContext(QOpenGLContext*) const + 83
    2 org.qt-project.QtGui 0x0000000108df979b QOpenGLContext::create() + 59
    3 org.qt-project.QtOpenGL 0x000000010866aeaf QGLContext::chooseContext(QGLContext const*) + 383
    4 org.qt-project.QtOpenGL 0x000000010866ab09 QGLContext::create(QGLContext const*) + 57
    5 org.qt-project.QtOpenGL 0x000000010866bac1 QGLWidget::setContext(QGLContext*, QGLContext const*, bool) + 209
    6 org.qt-project.QtOpenGL 0x000000010866ddcc QGLWidgetPrivate::initContext(QGLContext*, QGLWidget const*) + 236
    7 org.qt-project.QtOpenGL 0x000000010866b2d8 QGLWidget::QGLWidget(QWidget*, QGLWidget const*,
    </code></pre>

    I never experienced this problem when running the application with Qt 4.8.2 on the same machine. I also ported it to Qt 5.5 for Windows already and it worked flawlessly.

    Thanks a lot for your help!

    Edit:

    The culprit seems to be QGLFormat::setStereo(true) (see below). However, I'm dependent on stereo buffering and simply removing this line is no solution for me! Why does Qt 5.5 crash when using stereo buffering and is there a fix for that?

    1 Reply Last reply
    0
    • Paul H.P Offline
      Paul H.P Offline
      Paul H.
      wrote on last edited by
      #2

      I see that a couple of the error messages reference QOpenGLContext and others QGLContext. I don't know enough to say if that is a problem or not, but it caught my eye. I know that QGLWidget, QGLContext, etc. are declared obsolete now and it is recommended to use QOpenGLWidget, QOpenGLContext, etc. now.
      Paul

      A 1 Reply Last reply
      0
      • Paul H.P Paul H.

        I see that a couple of the error messages reference QOpenGLContext and others QGLContext. I don't know enough to say if that is a problem or not, but it caught my eye. I know that QGLWidget, QGLContext, etc. are declared obsolete now and it is recommended to use QOpenGLWidget, QOpenGLContext, etc. now.
        Paul

        A Offline
        A Offline
        angelag
        wrote on last edited by angelag
        #3

        @Paul-H.

        Thanks a lot for your response, Paul!
        I wasn't aware that QGLWidget and QGLContext are deprecated. However, since this will be a bigger change and QGLWidget should still work I want to fix this before moving to QOpenGLWidget. Again, this application already works perfectly fine on Windows with Qt 5.5 and MacOS with Qt 4.8.2.

        I might have found the culprit:
        Removing this line

        QGLFormat::setStereo(true)

        seems to fix the issue. However, I am dependent on stereo buffering and therefore this is no solution.
        Is this a bug in Qt 5.5?

        1 Reply Last reply
        0
        • SGaistS Offline
          SGaistS Offline
          SGaist
          Lifetime Qt Champion
          wrote on last edited by
          #4

          Hi and welcome to devnet,

          If you can reproduce that with a minimal compilable example then it likely is

          Interested in AI ? www.idiap.ch
          Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/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