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. Quick3D fails with software render backend
QtWS25 Last Chance

Quick3D fails with software render backend

Scheduled Pinned Locked Moved Unsolved QML and Qt Quick
4 Posts 2 Posters 785 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
    alic
    wrote on last edited by
    #1

    When I run my Qt project inside a docker container with the environment variable Qt_quick_backend=software (possibly related to https://bugreports.qt.io/browse/QTBUG-102634), the application runs but does not display any QtQuick 3D object. If I remove the Qt_quick_backend environment variable, the application gives a OpenGL segmentation fault error. When the application runs outside the docker container, i.e., locally, it works.

    I'm using Qt 6.2.3, C++, my OS is Ubuntu and the docker container is run with the following options: "xhost +local:", "--net host", "-e DISPLAY", "-e QT_QUICK_BACKEND=software", "-v /tmp/.X11-unix:/tmp/.X11-unix"

    This is the OpenGL segmentation fault output:

    qt.scenegraph.general: Using QRhi with backend OpenGL
      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
    I20230212 20:19:57.865648 23643 workerthread.cpp:202] runLoop Time: 0
    I20230212 20:19:57.865960 23643 workerthread.cpp:80] run: Loop running
    qt.scenegraph.general: Using sg animation driver
    qt.scenegraph.general: Animation Driver: using vsync: 16.67 ms
    qt.rhi.general: Created OpenGL context QSurfaceFormat(version 4.1, options QFlags<QSurfaceFormat::FormatOption>(DeprecatedFunctions), depthBufferSize 24, redBufferSize 8, greenBufferSize 8, blueBufferSize 8, alphaBufferSize 0, stencilBufferSize 8, samples -1, swapBehavior QSurfaceFormat::DoubleBuffer, swapInterval 1, colorSpace QColorSpace(), profile  QSurfaceFormat::CompatibilityProfile)
    qt.rhi.general: OpenGL VENDOR: VMware, Inc. RENDERER: SVGA3D; build: RELEASE;  LLVM; VERSION: 4.1 (Compatibility Profile) Mesa 21.2.6
    qt.scenegraph.general: MSAA sample count for the swapchain is 1. Alpha channel requested = no.
    qt.scenegraph.general: rhi texture atlas dimensions: 2048x2048
    Segmentation fault (core dumped)
    

    I'm expecting my Qt Project to display correctly the QtQuick 3D Object (e.g. View3D QML Type) inside a docker container.

    sierdzioS 1 Reply Last reply
    0
    • A alic

      When I run my Qt project inside a docker container with the environment variable Qt_quick_backend=software (possibly related to https://bugreports.qt.io/browse/QTBUG-102634), the application runs but does not display any QtQuick 3D object. If I remove the Qt_quick_backend environment variable, the application gives a OpenGL segmentation fault error. When the application runs outside the docker container, i.e., locally, it works.

      I'm using Qt 6.2.3, C++, my OS is Ubuntu and the docker container is run with the following options: "xhost +local:", "--net host", "-e DISPLAY", "-e QT_QUICK_BACKEND=software", "-v /tmp/.X11-unix:/tmp/.X11-unix"

      This is the OpenGL segmentation fault output:

      qt.scenegraph.general: Using QRhi with backend OpenGL
        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
      I20230212 20:19:57.865648 23643 workerthread.cpp:202] runLoop Time: 0
      I20230212 20:19:57.865960 23643 workerthread.cpp:80] run: Loop running
      qt.scenegraph.general: Using sg animation driver
      qt.scenegraph.general: Animation Driver: using vsync: 16.67 ms
      qt.rhi.general: Created OpenGL context QSurfaceFormat(version 4.1, options QFlags<QSurfaceFormat::FormatOption>(DeprecatedFunctions), depthBufferSize 24, redBufferSize 8, greenBufferSize 8, blueBufferSize 8, alphaBufferSize 0, stencilBufferSize 8, samples -1, swapBehavior QSurfaceFormat::DoubleBuffer, swapInterval 1, colorSpace QColorSpace(), profile  QSurfaceFormat::CompatibilityProfile)
      qt.rhi.general: OpenGL VENDOR: VMware, Inc. RENDERER: SVGA3D; build: RELEASE;  LLVM; VERSION: 4.1 (Compatibility Profile) Mesa 21.2.6
      qt.scenegraph.general: MSAA sample count for the swapchain is 1. Alpha channel requested = no.
      qt.scenegraph.general: rhi texture atlas dimensions: 2048x2048
      Segmentation fault (core dumped)
      

      I'm expecting my Qt Project to display correctly the QtQuick 3D Object (e.g. View3D QML Type) inside a docker container.

      sierdzioS Offline
      sierdzioS Offline
      sierdzio
      Moderators
      wrote on last edited by
      #2

      QtQuick 3D does not support software backend: https://doc.qt.io/qt-6/qtquick3d-requirements.html

      (Z(:^

      A 1 Reply Last reply
      0
      • sierdzioS sierdzio

        QtQuick 3D does not support software backend: https://doc.qt.io/qt-6/qtquick3d-requirements.html

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

        @sierdzio That's why I'm using OpenGL backend but It gives me a segmentation fault issue. Any idea of what can cause the problem?

        sierdzioS 1 Reply Last reply
        0
        • A alic

          @sierdzio That's why I'm using OpenGL backend but It gives me a segmentation fault issue. Any idea of what can cause the problem?

          sierdzioS Offline
          sierdzioS Offline
          sierdzio
          Moderators
          wrote on last edited by
          #4

          @alic Docker containers are headless, they don't have displays so also have no need for OpenGL drivers.
          You'll probably need to install MESA OpenGL drivers, then launch your app with -platform=offscreen.

          (Z(:^

          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