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

Quick3d demo fails when running on adreno-based android device

    XMLWordPrintable

Details

    • Bug
    • Resolution: Incomplete
    • P3: Somewhat important
    • None
    • 6.2
    • Quick: 3D
    • None
    • Asus Zenfone 6
      Android 11 arm64
      Adreno (TM) 640
      driverVersion 512.494.0
      Vulkan apiVersion 1.1.128
    • Android

    Description

      Demo location https://git.qt.io/public-demos/qtquick3d/-/tree/master/BenchmarkDemoQt6

      1) Apply patch so build succeeds

      diff --git a/BenchmarkDemoQt6/BenchmarkDemoQt6.pro b/BenchmarkDemoQt6/BenchmarkDemoQt6.pro
      index 5815786..1b1ac4b 100644
      --- a/BenchmarkDemoQt6/BenchmarkDemoQt6.pro
      +++ b/BenchmarkDemoQt6/BenchmarkDemoQt6.pro
      @@ -27,7 +27,7 @@ OTHER_FILES += \
           BenchmarkUI/testscripts/*.* \
           README.md
       
      -android: QMAKE_LFLAGS += --for-linker=--long-plt
      +#android: QMAKE_LFLAGS += --for-linker=--long-plt
       
       # Additional import path used to resolve QML modules in Qt Creator's code model
       !android: QML_IMPORT_PATH = BenchmarkUI
      @@ -59,4 +59,4 @@ DISTFILES += \
           android/gradlew.bat \
           android/res/values/libs.xml
       
      -ANDROID_PACKAGE_SOURCE_DIR = $$PWD/android
      +#ANDROID_PACKAGE_SOURCE_DIR = $$PWD/android
      diff --git a/BenchmarkDemoQt6/main.cpp b/BenchmarkDemoQt6/main.cpp
      index 772f6ed..34e6fd1 100644
      --- a/BenchmarkDemoQt6/main.cpp
      +++ b/BenchmarkDemoQt6/main.cpp
      @@ -14,7 +14,9 @@ int main(int argc, char *argv[])
       //    qputenv("QT_VULKAN_LIB", "/vendor/lib64/hw/vulkan.tegra.so"); // Pixel C
       //    qputenv("QT_VULKAN_LIB", "/vendor/lib/hw/vulkan.msmnile.so"); // Snapdragon
       //    qputenv("QT_VULKAN_LIB", "/vendor/lib64/hw/vulkan.msmnile.so"); // Snapdragon
      -//    qputenv("QSG_RHI_BACKEND", "vulkan");
      +//    qputenv("QT_VULKAN_LIB", "/vendor/lib/hw/vulkan.adreno.so"); // Asus
      +    qputenv("QT_VULKAN_LIB", "/vendor/lib64/hw/vulkan.adreno.so"); // Asus
      +    qputenv("QSG_RHI_BACKEND", "vulkan");
           QGuiApplication app(argc, argv);
       
           QSurfaceFormat::setDefaultFormat(QQuick3D::idealSurfaceFormat(4));
      
      

      2) Build BenchmarkDemoQt6.pro with Android qmake against Qt 6.2.
      Requires quick3d, qtquickcontrols2, quicktimeline.
      qmake && make && make apk
      Install to device either via Creator or importing the android-build folder via Android Studio.

      3) Build RemoteController.pro with desktop Qt qmake, which will connect via IP to the android device to tell it what to run. Any run config works.

      4) Observe white screen on android and the following error messages in the Android Studio's logcat output.

      I/QtCore: Start
      I/Qt: qt started
      I/AdrenoGLES-0: QUALCOMM build                   : 7854b52, I85c7417cbb
          Build Date                       : 07/28/20
          OpenGL ES Shader Compiler Version: EV031.32.00.00
          Local Branch                     : mybranchead0e16f-b038-f194-85d0-1458d0b52ae8
          Remote Branch                    : quic/gfx-adreno.lnx.1.0.r99-rel
          Remote Branch                    : NONE
          Reconstruct Branch               : NOTHING
          Build Config                     : S P 10.0.5 AArch64
          Driver Path                      : /vendor/lib64/egl/libGLESv2_adreno.so
      I/AdrenoGLES-0: PFP: 0x016ee190, ME: 0x00000000
      W/Qt A11Y: Could not (yet) activate platform accessibility.
      W/libBenchmarkDemoQt6_arm64-v8a.so: QFont::setPointSizeF: Point size <= 0 (0.000000), must be greater than 0
      I/TetheringManager: registerTetheringEventCallback:org.qtproject.example.BenchmarkDemoQt6
      W/qtMainLoopThrea: type=1400 audit(0.0:48002): avc: denied { ioctl } for path="socket:[1529818]" dev="sockfs" ino=1529818 ioctlcmd=0x8927 scontext=u:r:untrusted_app_29:s0:c37,c257,c512,c768 tcontext=u:r:untrusted_app_29:s0:c37,c257,c512,c768 tclass=tcp_socket permissive=0 app=org.qtproject.example.BenchmarkDemoQt6
      W/libBenchmarkDemoQt6_arm64-v8a.so: qrc:/BenchmarkUI/MeshSpawner.qml:0: Error: Cannot assign to non-existent property "textureSize"
      D/vulkan: searching for layers in '/data/app/~~2-QeiSUcpjHVxkEFLhfjxw==/org.qtproject.example.BenchmarkDemoQt6--w7EdA_0xNIcByX8Ak1CHA==/lib/arm64'
          searching for layers in '/data/app/~~2-QeiSUcpjHVxkEFLhfjxw==/org.qtproject.example.BenchmarkDemoQt6--w7EdA_0xNIcByX8Ak1CHA==/base.apk!/lib/arm64-v8a'
      I/AdrenoVK-0: ===== BEGIN DUMP OF OVERRIDDEN SETTINGS =====
          ===== END DUMP OF OVERRIDDEN SETTINGS =====
      I/AdrenoVK-0: QUALCOMM build          : 7854b52, I85c7417cbb
          Build Date              : 07/28/20
          Shader Compiler Version : EV031.32.00.00
          Local Branch            : mybranchead0e16f-b038-f194-85d0-1458d0b52ae8
          Remote Branch           : quic/gfx-adreno.lnx.1.0.r99-rel
          Remote Branch           : NONE
          Reconstruct Branch      : NOTHING
          Build Config            : S P 10.0.5 AArch64
          Driver Path             : /vendor/lib64/hw/vulkan.adreno.so
      W/System: A resource failed to call close. 
      D/qml: : Demo Mode
      W/libBenchmarkDemoQt6_arm64-v8a.so: qrc:/Model100k.qml:228:9: Unable to assign [undefined] to QQuick3DInstancing*
          qrc:/Model100k.qml:257:13: Unable to assign [undefined] to QQuick3DInstancing*
          qrc:/Model100k.qml:272:13: Unable to assign [undefined] to QQuick3DInstancing*
          qrc:/Model100k.qml:287:13: Unable to assign [undefined] to QQuick3DInstancing*
          qrc:/Model100k.qml:302:13: Unable to assign [undefined] to QQuick3DInstancing*
      W/libBenchmarkDemoQt6_arm64-v8a.so: QQmlComponent: Component is not ready
      W/libBenchmarkDemoQt6_arm64-v8a.so: qrc:/Model10k.qml:55:9: Unable to assign [undefined] to QQuick3DInstancing*
          qrc:/Model10k.qml:76:13: Unable to assign [undefined] to QQuick3DInstancing*
          qrc:/Model10k.qml:92:13: Unable to assign [undefined] to QQuick3DInstancing*
          qrc:/Model10k.qml:108:13: Unable to assign [undefined] to QQuick3DInstancing*
          qrc:/Model10k.qml:124:13: Unable to assign [undefined] to QQuick3DInstancing*
      W/QSSG.warning: : Failed to load image: :/../lightprobe/DemoModeIBL_small.hdr
      I/AdrenoVK-0: Failed to link shaders.
          Info log: Error: Bind group info mismatches the shader source for symbol qt_lightProbe
      W/libBenchmarkDemoQt6_arm64-v8a.so: Failed to create graphics pipeline: -13
          Failed to build graphics pipeline state
      I/AdrenoVK-0: Failed to link shaders.
          Info log: Error: Bind group info mismatches the shader source for symbol qt_lightProbe
      W/libBenchmarkDemoQt6_arm64-v8a.so: Failed to create graphics pipeline: -13
          Failed to build graphics pipeline state
      I/AdrenoVK-0: Failed to link shaders.
          Info log: Error: Bind group info mismatches the shader source for symbol qt_lightProbe
      W/libBenchmarkDemoQt6_arm64-v8a.so: Failed to create graphics pipeline: -13
          Failed to build graphics pipeline state
      I/AdrenoVK-0: Failed to link shaders.
      I/AdrenoVK-0: Info log: Error: Bind group info mismatches the shader source for symbol qt_lightProbe
      W/libBenchmarkDemoQt6_arm64-v8a.so: Failed to create graphics pipeline: -13
          Failed to build graphics pipeline state
      I/AdrenoVK-0: Failed to link shaders.
          Info log: Error: Bind group info mismatches the shader source for symbol qt_lightProbe
      

      Demo works fine when running using OpenGL ES instead of Vulkan.

      Building Android with Vulkan support requires https://codereview.qt-project.org/c/qt/qtbase/+/357515

      Attachments

        Issue Links

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

          Activity

            People

              qt.team.graphics.and.multimedia Qt Graphics Team
              alexandru.croitor Alexandru Croitor
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews

                  There are no open Gerrit changes