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. Failed to create D3D11 swapchain: The application made a call that is invalid
Forum Updated to NodeBB v4.3 + New Features

Failed to create D3D11 swapchain: The application made a call that is invalid

Scheduled Pinned Locked Moved Unsolved QML and Qt Quick
8 Posts 2 Posters 1.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.
  • J Offline
    J Offline
    johndummy
    wrote on last edited by
    #1

    I'm trying to deploy a qt application on my windows server 2012 R2. I've developed app on my windows 10 and it worked fine on the developement machine but it doesn't show gui on my Windows server.

    The problem is related to loading directX dlls I suppose. Here is the screen shot of the debugView on my windows server.

    Capture.PNG

    ListDlls shows that on windows server, that app couldn't find
    C:\WINDOWS\SYSTEM32\d3d11.dll because its not even there!

    I've tried to copy the d3d11.dll from my development machine to server but app complains about missing api-ms-win-core-heap-l2-1-0.dll and the list goes if i copy individual dlls.

    What could be the possible solution ?

    1 Reply Last reply
    0
    • hskoglundH Offline
      hskoglundH Offline
      hskoglund
      wrote on last edited by
      #2

      Hi, maybe your Windows Server 2012 R2 is a barebones a.k.a. "core" version, then you need to install the "Desktop Experience" to get Direct11 working, more here

      J 1 Reply Last reply
      0
      • hskoglundH hskoglund

        Hi, maybe your Windows Server 2012 R2 is a barebones a.k.a. "core" version, then you need to install the "Desktop Experience" to get Direct11 working, more here

        J Offline
        J Offline
        johndummy
        wrote on last edited by johndummy
        #3

        @hskoglund Thanks for the reply. I installed the "Desktop Experience" on my server and now the C:\WINDOWS\SYSTEM32\d3d11.dll is available on my server but the same error message appears unfortunately.

        Capture.PNG

        1 Reply Last reply
        0
        • hskoglundH Offline
          hskoglundH Offline
          hskoglund
          wrote on last edited by
          #4

          Maybe rhe server needs a reboot also…

          J 1 Reply Last reply
          0
          • hskoglundH hskoglund

            Maybe rhe server needs a reboot also…

            J Offline
            J Offline
            johndummy
            wrote on last edited by
            #5

            @hskoglund Yes, I've rebooted the server after installation.
            Here the listdll output chunk which shows d3d11.dll is loaded now but the problem somehow persists.

            Capture.PNG

            1 Reply Last reply
            0
            • hskoglundH Offline
              hskoglundH Offline
              hskoglund
              wrote on last edited by
              #6

              Hmmm it could be tjhat Windows Server 2012 R2 is not supported by Qt 6’.5 :-(
              Ik that case: either upgrade the server or downgrade your app to Qt5.

              J 1 Reply Last reply
              0
              • hskoglundH hskoglund

                Hmmm it could be tjhat Windows Server 2012 R2 is not supported by Qt 6’.5 :-(
                Ik that case: either upgrade the server or downgrade your app to Qt5.

                J Offline
                J Offline
                johndummy
                wrote on last edited by
                #7

                @hskoglund I somehow find a lame solution. Here is what i did,

                Set QT_QUICK_BACKEND to software in my main(..)

                QQuickWindow::setSceneGraphBackend("software");
                

                set the following environment variable on my server i.e.

                QSG_RHI_PREFER_SOFTWARE_RENDERER=1
                

                It work for now atleast.

                1 Reply Last reply
                0
                • hskoglundH Offline
                  hskoglundH Offline
                  hskoglund
                  wrote on last edited by
                  #8

                  Any solution you can walk away from, is a good one :-)
                  P.S Hopefully this will help others having the same probllem.

                  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