Uploaded image for project: 'Qt for Python'
  1. Qt for Python
  2. PYSIDE-2460

QOpenGLContext is not valid when aboutToBeDestroyed is run

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: P4: Low P4: Low
    • Some future version
    • 6.5.2
    • PySide
    • None
    • Windows
    • 98e0600c5 (dev), 08dd6dce6 (6.6), b027e03fe (6.5), eec936657 (dev), bd180bc53 (dev), 9e48ec981 (6.6), 1f3fac613 (6.6)

      I am using PySide6 to write an OpenGL application.

      I need to run code when the QOpenGLWidget is being destroyed but while the QOpenGLContext is still valid.

      The docs say that this is the purpose of QOpenGLContext.aboutToBeDestroyed however when the connected slot is run the QOpenGLContext is no longer valid.

       

      I will attach a sample a minimal example.

       

        1. aboutToBeDestroyed2.py
          2 kB
          J C
        2. pyside2460.py
          2 kB
          Friedemann Kleint
        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

            kleint Friedemann Kleint
            gentlegiantjgc J C
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: