Can I use QtMultimedia Private API ?
-
Hi all,
I am experimenting with the new QtMultimedia module on Linux (Kubuntu 21.04). I would like to create a custom GStreamer pipeline by using some helper classes from the QtMultimedia/GStreamer backend. I have added
multimedia-private
to myQT
.My problem is that I get
undefined references
for some private classes.For example, when I build this snippet:
#include "widget.h" #include <QtMultimedia/private/qgstpipeline_p.h> Widget::Widget(QWidget *parent) : QWidget(parent) { QGstPipeline pipeline("my-pipeline"); QGstElement element("videotestsrc"); }
I get:
undefined reference to `QGstPipeline::QGstPipeline(char const*)' undefined reference to `QGstPipeline::~QGstPipeline()'
So
QGstPipeline
is undefined, butQGstElement
is all good. Could anybody help me understand ?I also tried with a CMake project by adding a project dependency to
Qt6::MultimediaPrivate
, same result 😕Thanks!
-
Hi,
From the looks of it, the class was not exported. I don't think it's intentional though.
-
Bummer.
Can you point me to the files / docs I should look at to get the missing symbols exported. I am building Qt from source anyway and would be happy to contribute to QtMultimedia.
Dropping the plugin architecture in Qt6 is making everything so much simpler and interesting. I have a few apps which I want to migrate to Qt6 just to throw away custom Qt5/Multimedia code 😄
-
From the looks of it, it's in gstpipeline_p.h. The other private classes seem to be exported.