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

Android camera doesn't work with qt6

    XMLWordPrintable

Details

    • Android
    • 34bdc50c8a (qt/qtmultimedia/dev) 84122f1b09 (qt/qtmultimedia/6.3)
    • 2022wk08FOAndroid&Automotive

    Description

      Hello,

      The camera raise exception on android :

      With declarative-camera or with a minimal example : Quick empty project, update main.qml like below and add Qt:Multimedia package in CMakeLists.txt (Idem with qmake and .pro file) :

      import QtQuick
      import QtMultimedia
      
      Window {
          visible: true
          Camera {
              id: camera
          }
      
          CaptureSession {
              id: captureSession
              camera: camera
              videoOutput: videoOutput
          }
      
      
          VideoOutput {
              id: videoOutput
              anchors.fill: parent
          }
      }
      

      This works well on IOS but on android, there are error and a white screen :

      
      E libc    : Access denied finding property "camera.hal1.packagelist"
      I FeatureParser: can't find capricorn.xml in assets/device_features/,it may be in /system/etc/device_features
      E libc    : Access denied finding property "camera.hal1.packagelist"
      E libc    : Access denied finding property "camera.hal1.packagelist"
      W System.err: java.lang.RuntimeException: setParameters failed
      W System.err: 	at android.hardware.Camera.native_setParameters(Native Method)
      W System.err: 	at android.hardware.Camera.setParameters(Camera.java:2098)
      W System.err: java.lang.RuntimeException: setParameters failed
      W System.err: 	at android.hardware.Camera.native_setParameters(Native Method)
      W System.err: 	at android.hardware.Camera.setParameters(Camera.java:2098)
      

      Attachments

        Issue Links

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

          Activity

            People

              qtandroidteam Qt Android Team
              leocouturier Léo Couturier
              Votes:
              1 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews

                  There are no open Gerrit changes