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. Is it possible to load a QML module at runtime with a static-compiled Qt Application?
Forum Updated to NodeBB v4.3 + New Features

Is it possible to load a QML module at runtime with a static-compiled Qt Application?

Scheduled Pinned Locked Moved Unsolved QML and Qt Quick
1 Posts 1 Posters 411 Views 1 Watching
  • 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.
  • T Offline
    T Offline
    TFSun
    wrote on last edited by
    #1

    I have a Qt application which is statically build based on Qt 5.15.2. I would like to use the GLVideoItem module which comes with the qmlgl plugin of GStreamer.

    Right now I'm trying to use the GStreamer plugin installed in the system without compile the GStreamer plugin by myself.

    From the C++ side I see the plugin is found and loaded correctly because the GstElement *sink = gst_element_factory_make("qmlglsink", nullptr); returns me a valid pointer.

    However on the QML side it seems not finding the GLVideoItem module because at run-time it shows the module "org.freedesktop.gstreamer.GLVideoItem" is not installed error.

    I'm guessing it's a problem with the static build. In my cmake file I'm using the following commands to statically link the plugins.

    qt5_import_qml_plugins(QGroundControl)
    qt5_import_plugins(QGroundControl
    	INCLUDE
    		Qt5::QXcbIntegrationPlugin
    		Qt5::QVirtualKeyboardPlugin
    		Qt5::QSvgPlugin
    )
    

    My question is, is it possible to let the qml dynamically load the plugins in a static build? Or I shall static build all the plugin I need together with the application?
    Thank you all in advance for your help.

    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