Qml - gstreamer - camera : dont work



  • Hello

    I have linux 3.10.17, gstreamer-0.1, qt5.3.1

    Qt5.3.1 was built separately of buildroot and placed into /opt

    ./configure.imx6
    @./configure -opensource -confirm-license
    -device imx6
    -device-option CROSS_COMPILE=/usr/local/linaro-toolchain/bin/arm-linux-gnueabihf-
    -no-pch
    -no-opengl
    -no-xcb
    -opengl es2
    -make libs
    -nomake examples
    -nomake tests
    -sysroot /home/work/fs -no-gcc-sysroot
    -prefix /opt/qt5.3.1
    -v@

    I try run qml code:
    test src
    @Item {
    width: 640
    height: 360

        Camera {
            id: camera
            imageProcessing.whiteBalanceMode: CameraImageProcessing.WhiteBalanceAuto
    
            exposure {
                exposureCompensation: -1.0
                exposureMode: Camera.ExposurePortrait
            }
    
            flash.mode: Camera.FlashRedEyeReduction
            imageCapture {
                onImageCaptured: {
                    photoPreview.source = preview  // Show the preview in an Image
                }
            }
        }
    
        VideoOutput {
            source: camera
            anchors.fill: parent
            focus : visible // to receive focus and capture key events when visible
        }
    
        Image {
            id: photoPreview
        }
    }@
    

    by shell script:
    @export QT_QPA_PLATFORM_PLUGIN_PATH=/opt/qt5.3.1/plugins/platforms
    export QML2_IMPORT_PATH=/opt/qt5.3.1/qml
    export LD_LIBRARY_PATH=/usr/lib:/opt/qt5.3.1/lib
    export QT_DEBUG_PLUGINS=1

    ./text &@

    and I got message debug log:

    debug messages
    @QFactoryLoader::QFactoryLoader() checking directory path "/opt/qt5.3.1/plugins/platforms/mediaservice" ...
    QFactoryLoader::QFactoryLoader() checking directory path "/opt/qt5.3.1/plugins/mediaservice" ...
    QFactoryLoader::QFactoryLoader() looking at "/opt/qt5.3.1/plugins/mediaservice/libgstaudiodecoder.so"
    Found metadata in lib /opt/qt5.3.1/plugins/mediaservice/libgstaudiodecoder.so, metadata=
    {
    "IID": "org.qt-project.qt.mediaserviceproviderfactory/5.0",
    "MetaData": {
    "Keys": [
    "gstreameraudiodecode"
    ],
    "Services": [
    "org.qt-project.qt.audiodecode"
    ]
    },
    "className": "QGstreamerAudioDecoderServicePlugin",
    "debug": false,
    "version": 328449
    }

    Got keys from plugin meta data ("gstreameraudiodecode")
    QFactoryLoader::QFactoryLoader() looking at "/opt/qt5.3.1/plugins/mediaservice/libgstcamerabin.so"
    Found metadata in lib /opt/qt5.3.1/plugins/mediaservice/libgstcamerabin.so, metadata=
    {
    "IID": "org.qt-project.qt.mediaserviceproviderfactory/5.0",
    "MetaData": {
    "Keys": [
    "gstreamercamerabin"
    ],
    "Services": [
    "org.qt-project.qt.camera"
    ]
    },
    "className": "CameraBinServicePlugin",
    "debug": false,
    "version": 328449
    }

    Got keys from plugin meta data ("gstreamercamerabin")
    QFactoryLoader::QFactoryLoader() looking at "/opt/qt5.3.1/plugins/mediaservice/libgstmediacapture.so"
    Found metadata in lib /opt/qt5.3.1/plugins/mediaservice/libgstmediacapture.so, metadata=
    {
    "IID": "org.qt-project.qt.mediaserviceproviderfactory/5.0",
    "MetaData": {
    "Keys": [
    "gstreamermediacapture"
    ],
    "Services": [
    "org.qt-project.qt.audiosource"
    ]
    },
    "className": "QGstreamerCaptureServicePlugin",
    "debug": false,
    "version": 328449
    }

    Got keys from plugin meta data ("gstreamermediacapture")
    QFactoryLoader::QFactoryLoader() looking at "/opt/qt5.3.1/plugins/mediaservice/libgstmediaplayer.so"
    Found metadata in lib /opt/qt5.3.1/plugins/mediaservice/libgstmediaplayer.so, metadata=
    {
    "IID": "org.qt-project.qt.mediaserviceproviderfactory/5.0",
    "MetaData": {
    "Keys": [
    "gstreamermediaplayer"
    ],
    "Services": [
    "org.qt-project.qt.mediaplayer"
    ]
    },
    "className": "QGstreamerPlayerServicePlugin",
    "debug": false,
    "version": 328449
    }

    Got keys from plugin meta data ("gstreamermediaplayer")
    QFactoryLoader::QFactoryLoader() checking directory path "/work/myapp/mediaservice" ...
    loaded library "/opt/qt5.3.1/plugins/mediaservice/libgstcamerabin.so"
    QFactoryLoader::QFactoryLoader() checking directory path "/opt/qt5.3.1/plugins/platforms/video/declarativevideobackend" ...
    QFactoryLoader::QFactoryLoader() checking directory path "/opt/qt5.3.1/plugins/video/declarativevideobackend" ...
    QFactoryLoader::QFactoryLoader() checking directory path "/work/myapp/video/declarativevideobackend" ...
    QFactoryLoader::QFactoryLoader() checking directory path "/opt/qt5.3.1/plugins/platforms/video/videonode" ...
    QFactoryLoader::QFactoryLoader() checking directory path "/opt/qt5.3.1/plugins/video/videonode" ...
    QFactoryLoader::QFactoryLoader() looking at "/opt/qt5.3.1/plugins/video/videonode/libimx6vivantevideonode.so"
    Found metadata in lib /opt/qt5.3.1/plugins/video/videonode/libimx6vivantevideonode.so, metadata=
    {
    "IID": "org.qt-project.qt.sgvideonodefactory/5.2",
    "MetaData": {
    "Keys": [
    "sgvideonodes"
    ]
    },
    "className": "QSGVivanteVideoNodeFactory",
    "debug": false,
    "version": 328449
    }

    Got keys from plugin meta data ("sgvideonodes")
    QFactoryLoader::QFactoryLoader() checking directory path "/work/myapp/video/videonode" ...
    loaded library "/opt/qt5.3.1/plugins/video/videonode/libimx6vivantevideonode.so"
    QFactoryLoader::QFactoryLoader() checking directory path "/opt/qt5.3.1/plugins/platforms/video/bufferpool" ...
    QFactoryLoader::QFactoryLoader() checking directory path "/opt/qt5.3.1/plugins/video/bufferpool" ...
    QFactoryLoader::QFactoryLoader() checking directory path "/work/myapp/video/bufferpool" ...
    CameraBin error: "Your GStreamer installation is missing a plug-in."

    @

    What need to do it to be able work?


  • Lifetime Qt Champion

    Hi,

    Did you install all gstreamer plugin packages on your target ?



  • what are you mean "all plugins"? all plugin packages as possible at menuconfig of buildroot?



  • how to understand - what the plugin can not downloaded?
    where in the log reports of a missing plugin? I do not see it...


  • Lifetime Qt Champion

    If you take for example the debian package for gstreamer you have the core component and the plugins for gstreamer. These plugins might be missing. I don't know how you installed gstreamer in the first place for your target so I can't tell how to install additional packages if that applies



  • I made all plugins in the buildroot and multimedia started working now. But is some problems. Еру сamera make 2..3 frames and to show this frames around (repeatedly) with 2..3 fps. Not show video, no 30 or 60 fps - only 2..3 fps of first 2..3 frames. How to diagnose this situation?

    log of debug info:

    @QFactoryLoader::QFactoryLoader() checking directory path "/opt/qt5.3.1/plugins/platforms/mediaservice" ...
    QFactoryLoader::QFactoryLoader() checking directory path "/opt/qt5.3.1/plugins/mediaservice" ...
    QFactoryLoader::QFactoryLoader() looking at "/opt/qt5.3.1/plugins/mediaservice/libgstaudiodecoder.so"
    Found metadata in lib /opt/qt5.3.1/plugins/mediaservice/libgstaudiodecoder.so, metadata=
    {
    "IID": "org.qt-project.qt.mediaserviceproviderfactory/5.0",
    "MetaData": {
    "Keys": [
    "gstreameraudiodecode"
    ],
    "Services": [
    "org.qt-project.qt.audiodecode"
    ]
    },
    "className": "QGstreamerAudioDecoderServicePlugin",
    "debug": false,
    "version": 328449
    }

    Got keys from plugin meta data ("gstreameraudiodecode")
    QFactoryLoader::QFactoryLoader() looking at "/opt/qt5.3.1/plugins/mediaservice/libgstcamerabin.so"
    Found metadata in lib /opt/qt5.3.1/plugins/mediaservice/libgstcamerabin.so, metadata=
    {
    "IID": "org.qt-project.qt.mediaserviceproviderfactory/5.0",
    "MetaData": {
    "Keys": [
    "gstreamercamerabin"
    ],
    "Services": [
    "org.qt-project.qt.camera"
    ]
    },
    "className": "CameraBinServicePlugin",
    "debug": false,
    "version": 328449
    }

    Got keys from plugin meta data ("gstreamercamerabin")
    QFactoryLoader::QFactoryLoader() looking at "/opt/qt5.3.1/plugins/mediaservice/libgstmediacapture.so"
    Found metadata in lib /opt/qt5.3.1/plugins/mediaservice/libgstmediacapture.so, metadata=
    {
    "IID": "org.qt-project.qt.mediaserviceproviderfactory/5.0",
    "MetaData": {
    "Keys": [
    "gstreamermediacapture"
    ],
    "Services": [
    "org.qt-project.qt.audiosource"
    ]
    },
    "className": "QGstreamerCaptureServicePlugin",
    "debug": false,
    "version": 328449
    }

    Got keys from plugin meta data ("gstreamermediacapture")
    QFactoryLoader::QFactoryLoader() looking at "/opt/qt5.3.1/plugins/mediaservice/libgstmediaplayer.so"
    Found metadata in lib /opt/qt5.3.1/plugins/mediaservice/libgstmediaplayer.so, metadata=
    {
    "IID": "org.qt-project.qt.mediaserviceproviderfactory/5.0",
    "MetaData": {
    "Keys": [
    "gstreamermediaplayer"
    ],
    "Services": [
    "org.qt-project.qt.mediaplayer"
    ]
    },
    "className": "QGstreamerPlayerServicePlugin",
    "debug": false,
    "version": 328449
    }

    Got keys from plugin meta data ("gstreamermediaplayer")
    QFactoryLoader::QFactoryLoader() checking directory path "/test/mediaservice" ...
    loaded library "/opt/qt5.3.1/plugins/mediaservice/libgstcamerabin.so"
    QFactoryLoader::QFactoryLoader() checking directory path "/opt/qt5.3.1/plugins/platforms/video/declarativevideobackend" ...
    QFactoryLoader::QFactoryLoader() checking directory path "/opt/qt5.3.1/plugins/video/declarativevideobackend" ...
    QFactoryLoader::QFactoryLoader() checking directory path "/test/video/declarativevideobackend" ...
    QFactoryLoader::QFactoryLoader() checking directory path "/opt/qt5.3.1/plugins/platforms/video/videonode" ...
    QFactoryLoader::QFactoryLoader() checking directory path "/opt/qt5.3.1/plugins/video/videonode" ...
    QFactoryLoader::QFactoryLoader() looking at "/opt/qt5.3.1/plugins/video/videonode/libimx6vivantevideonode.so"
    Found metadata in lib /opt/qt5.3.1/plugins/video/videonode/libimx6vivantevideonode.so, metadata=
    {
    "IID": "org.qt-project.qt.sgvideonodefactory/5.2",
    "MetaData": {
    "Keys": [
    "sgvideonodes"
    ]
    },
    "className": "QSGVivanteVideoNodeFactory",
    "debug": false,
    "version": 328449
    }

    Got keys from plugin meta data ("sgvideonodes")
    QFactoryLoader::QFactoryLoader() checking directory path "/test/video/videonode" ...
    loaded library "/opt/qt5.3.1/plugins/video/videonode/libimx6vivantevideonode.so"
    QFactoryLoader::QFactoryLoader() checking directory path "/opt/qt5.3.1/plugins/platforms/video/bufferpool" ...
    QFactoryLoader::QFactoryLoader() checking directory path "/opt/qt5.3.1/plugins/video/bufferpool" ...
    QFactoryLoader::QFactoryLoader() checking directory path "/test/video/bufferpool" ...
    [INFO] Product Info: i.MX6Q/D/S
    vpuenc versions :)
    plugin: 3.0.11
    wrapper: 1.0.46(VPUWRAPPER_ARM_LINUX Build on Sep 12 2014 11:03:44)
    vpulib: 5.4.23
    firmware: 3.1.1.46056
    [INFO] Product Info: i.MX6Q/D/S
    vpuenc versions :)
    plugin: 3.0.11
    wrapper: 1.0.46(VPUWRAPPER_ARM_LINUX Build on Sep 12 2014 11:03:44)
    vpulib: 5.4.23
    firmware: 3.1.1.46056@



  • @_dmp

    I use buildroot as well, and install all gst plugins()198 plugins, after starting camera app, it shows this two errors.

    defaultServiceProvider::requestService(): no service found for - "org.qt-project.qt.camera"
    defaultServiceProvider::requestService(): no service found for - "org.qt-project.qt.mediaplayer"


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.