Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. QML and Qt Quick
  4. Minimum required version of OpenGL to run Qt 5.12.0 QtQuick compiled apps
QtWS25 Last Chance

Minimum required version of OpenGL to run Qt 5.12.0 QtQuick compiled apps

Scheduled Pinned Locked Moved Solved QML and Qt Quick
12 Posts 2 Posters 2.4k 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.
  • fcarneyF fcarney

    Sorry, this is all QtQuick related.

    Okay, I have been developing on an Nvidia based system in Qt 5.12.0. Everything was working well. It is well supported and supports the latest OpenGL. However, I have been asked to do my development on a Windows 10 VM in Virtualbox. I have been having issues running the same apps in this VM. Using a default QtQuick generated app without setting any options I get a string of D3D errors:

    QOpenGLShaderProgram::uniformLocation(matrix): shader program is not linked
    QOpenGLShaderProgram::uniformLocation(textureScale): shader program is not linked
    QOpenGLShaderProgram::uniformLocation(color): shader program is not linked
    QOpenGLShaderProgram::uniformLocation(alphaMin): shader program is not linked
    QOpenGLShaderProgram::uniformLocation(alphaMax): shader program is not linked
    QOpenGLShaderProgram::uniformLocation(fontScale): shader program is not linked
    QOpenGLShaderProgram::uniformLocation(vecDelta): shader program is not linked
    

    If I run with this:

    QCoreApplication::setAttribute(Qt::AA_UseDesktopOpenGL);
    

    I get application crash:

    QML debugging is enabled. Only use this in a safe environment.
    15:34:40: The program has unexpectedly finished.
    15:34:40: The process was ended forcefully.
    

    So I did a bit of research and found that Virtualbox since Windows 8.1 has only officially supported OpenGL 1.1. I then found a tool called wglxinfo.exe and checked the version that my VM was reporting. It did return OpenGL 1.1.

    My question is this:
    What version of OpenGL is the minimum required to run Qt 5.12.0 compiled applications?

    Edit:
    Also, what version of D3D does QtQuick 5.12 support?

    fcarneyF Offline
    fcarneyF Offline
    fcarney
    wrote on last edited by
    #2

    I must be frustrated, because I didn't do a search:
    https://doc.qt.io/qt-5/windows-requirements.html

    C++ is a perfectly valid school of magic.

    1 Reply Last reply
    0
    • fcarneyF Offline
      fcarneyF Offline
      fcarney
      wrote on last edited by
      #3

      Now I am really confused. I installed Qt on a different VM with Windows 10 on it and I can run QtQuick apps just fine. So somehow I borked my other Qt install on my other VM.

      C++ is a perfectly valid school of magic.

      kshegunovK 1 Reply Last reply
      0
      • fcarneyF fcarney

        Now I am really confused. I installed Qt on a different VM with Windows 10 on it and I can run QtQuick apps just fine. So somehow I borked my other Qt install on my other VM.

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

        @fcarney said in Minimum required version of OpenGL to run Qt 5.12.0 QtQuick compiled apps:

        Now I am really confused. I installed Qt on a different VM with Windows 10 on it and I can run QtQuick apps just fine. So somehow I borked my other Qt install on my other VM.

        It always is the drivers and from my (limited) experience VMs are quite poor in that regard. See if the drivers are installed and virtualized correctly is my best advice.

        Read and abide by the Qt Code of Conduct

        1 Reply Last reply
        1
        • fcarneyF Offline
          fcarneyF Offline
          fcarney
          wrote on last edited by
          #5

          The VM with problems was originally a Nvidia machine. Then it got turned into a VM. I installed drivers for the VM, but it is not correcting itself. The other VM works fine (brand new install). I may have to reinstall Windows on this machine to fix this. I tried installing the DirectX drivers, but it did not correct the issue. The lesson here may be that you need to do a clean install of the OS on a VM.

          C++ is a perfectly valid school of magic.

          kshegunovK 1 Reply Last reply
          0
          • fcarneyF fcarney

            The VM with problems was originally a Nvidia machine. Then it got turned into a VM. I installed drivers for the VM, but it is not correcting itself. The other VM works fine (brand new install). I may have to reinstall Windows on this machine to fix this. I tried installing the DirectX drivers, but it did not correct the issue. The lesson here may be that you need to do a clean install of the OS on a VM.

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

            Honestly, I have no idea, but since it's a VM it should be easy enough to try and install a clean windows.

            Read and abide by the Qt Code of Conduct

            1 Reply Last reply
            1
            • fcarneyF Offline
              fcarneyF Offline
              fcarney
              wrote on last edited by
              #7

              Okay, I reset the Windows 10 OS. Now I can compile and run the Qt apps with no D3D errors and no OpenGL errors.
              I am getting a DLL error when creator starts though.

              Is there a way to tell Qt to fix its install without having to reinstall Qt again? I did do an update on creator to the latest, but it still gives this DLL error:

              CONCRT140.dll
              

              C++ is a perfectly valid school of magic.

              kshegunovK 1 Reply Last reply
              0
              • fcarneyF fcarney

                Okay, I reset the Windows 10 OS. Now I can compile and run the Qt apps with no D3D errors and no OpenGL errors.
                I am getting a DLL error when creator starts though.

                Is there a way to tell Qt to fix its install without having to reinstall Qt again? I did do an update on creator to the latest, but it still gives this DLL error:

                CONCRT140.dll
                
                kshegunovK Offline
                kshegunovK Offline
                kshegunov
                Moderators
                wrote on last edited by
                #8

                @fcarney said in Minimum required version of OpenGL to run Qt 5.12.0 QtQuick compiled apps:

                Is there a way to tell Qt to fix its install without having to reinstall Qt again? I did do an update on creator to the latest, but it still gives this DLL error

                No, this isn't a Qt error. You're missing the MSVC redistributable (or part of it). Download if from MS's site and install it. I think this should be the correct version.

                Read and abide by the Qt Code of Conduct

                1 Reply Last reply
                2
                • fcarneyF Offline
                  fcarneyF Offline
                  fcarney
                  wrote on last edited by
                  #9

                  Yeah, I just found that, Thank you!

                  C++ is a perfectly valid school of magic.

                  1 Reply Last reply
                  1
                  • fcarneyF Offline
                    fcarneyF Offline
                    fcarney
                    wrote on last edited by
                    #10

                    Somehow this has regressed and doing a reset of Windows 10 is fixing this issue anymore. I am going to try reinstalling Qt to see is this is the solution. This is very frustrating.

                    C++ is a perfectly valid school of magic.

                    1 Reply Last reply
                    0
                    • fcarneyF Offline
                      fcarneyF Offline
                      fcarney
                      wrote on last edited by
                      #11
                      • Setup brand new install of Win10 on VM (VirtualBox)
                      • Installed Qt 5.12.1 from web
                      • Created test QtQuick app
                      • Gives Angle and OpenGL errors when doing default detect opengl
                      • Segfaults/dies when running with this option: QCoreApplication::setAttribute(Qt::AA_UseDesktopOpenGL);
                      • Will run app with this option on: QCoreApplication::setAttribute(Qt::AA_UseSoftwareOpenGL);

                      I also tried running the application on VMWare and I get the same failures. Even though VMWare has a more advanced representation of OpenGL and D3D than VirtualBox.

                      So for a workaround I will be using:
                      QCoreApplication::setAttribute(Qt::AA_UseSoftwareOpenGL);

                      Supposedly slower, but rather have running than not. May setup command line to select this mode when testing in VM and not on a real machine.

                      C++ is a perfectly valid school of magic.

                      1 Reply Last reply
                      1
                      • fcarneyF Offline
                        fcarneyF Offline
                        fcarney
                        wrote on last edited by fcarney
                        #12

                        Alternatively, if you want to simulate hardware opengl with the option Qt::AA_UseDesktopOpenGL then use the drivers from here:
                        mesa drivers

                        Edit:
                        Dang it! Installing those drivers does allow running the app, BUT it causes permission errors with user accounts and prevents running anything with admin privileges. So I do NOT recommend them.

                        Edit:
                        Okay, this issue was caused by the VirtualBox implementation problems with D3D. Turning off 3D acceleration fixes the permissions issues.

                        C++ is a perfectly valid school of magic.

                        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