Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-98061

Vulkan Wayland compositor support

XMLWordPrintable

    • Icon: Suggestion Suggestion
    • Resolution: Unresolved
    • Icon: P3: Somewhat important P3: Somewhat important
    • None
    • 6.2.1
    • Wayland Compositor
    • None
    • Linux/Wayland

      Running a Qt application on wayland works under non-qt compositors (tested with Weston and Gnome), with these environment variables :

      QSG_RHI_BACKEND=vulkan
      QT_QPA_PLATFORM=wayland-egl

       

      It also works with a QtWayland compositor, if the compositor has been run with these environment variables :

      QSG_RHI_BACKEND=opengl
      QT_QPA_PLATFORM=eglfs

       

      But whenever I try to get a vulkan-only system, by starting the compositor with :

      QSG_RHI_BACKEND=vulkan
      QT_QPA_PLATFORM=vkkhrdisplay

       

      Any vulkan application simply crashes (see logs below).

       

      To sum up, the only compatible possibilities are :

      Compositor

      QSG_RHI_BACKEND=opengl
      QT_QPA_PLATFORM=eglfs

      Application

      QSG_RHI_BACKEND=vulkan
      QT_QPA_PLATFORM=wayland-egl

       

      Or

       

      Compositor

      QSG_RHI_BACKEND=vulkan
      QT_QPA_PLATFORM=vkkhrdisplay

      Application

      QSG_RHI_BACKEND=opengl
      QT_QPA_PLATFORM=wayland-egl

       

      While my goal is to achieve :

      Compositor

      QSG_RHI_BACKEND=vulkan
      QT_QPA_PLATFORM=vkkhrdisplay

      Application

      QSG_RHI_BACKEND=vulkan
      QT_QPA_PLATFORM=wayland-egl

       

       

       

       

      LOGS (QSG_INFO=1)

      qt.scenegraph.general: Using QRhi with backend Vulkan
      Graphics API debug/validation layers: 0
      QRhi profiling and debug markers: 0
      Shader/pipeline cache collection: 0
      qt.scenegraph.general: threaded render loop
      qt.scenegraph.general: Using sg animation driver
      qt.scenegraph.general: Animation Driver: using vsync: 16.67 ms
      qt.scenegraph.general: Using sg animation driver
      qt.scenegraph.general: Animation Driver: using vsync: 16.67 ms
      qt.scenegraph.general: Requesting Vulkan API 1.2 Instance-level version was reported as 1.2.194
      qt.rhi.general: Physical device 0: 'AMD RADV RENOIR' 21.2.4 (api 1.2.182 vendor 0x1002 device 0x1636 type 1)
      qt.rhi.general: using this physical device
      qt.rhi.general: queue family 0: flags=0xf count=1
      qt.rhi.general: queue family 1: flags=0xe count=4
      No graphics (or no graphics+present) queue family found
      Failed to create RHI (backend 1)
      Failed to create QRhi on the render thread; scenegraph is not functional
      Failed to initialize graphics backend for Vulkan.

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

            qt.team.graphics.and.multimedia Qt Graphics Team
            autiarth Arthur Autin
            Votes:
            2 Vote for this issue
            Watchers:
            7 Start watching this issue

              Created:
              Updated:

                There are no open Gerrit changes