32dfa102b3
This fixes a build error if Qt was build without accessibility support: ../../../../../gstreamer/subprojects/gst-plugins-good/ext/qt/qtglrenderer.cc: In member function 'bool GstQuickRenderer::init(GstGLContext*, GError**)': ../../../../../gstreamer/subprojects/gst-plugins-good/ext/qt/qtglrenderer.cc:341:13: error: 'QCoreApplication' was not declared in this scope; did you mean 'QApplication'? ../../../../../gstreamer/subprojects/gst-plugins-good/ext/qt/qtglrenderer.cc:341:31: error: 'app' was not declared in this scope ../../../../../gstreamer/subprojects/gst-plugins-good/ext/qt/qtglrenderer.cc:341:37: error: 'QCoreApplication' is not a class, namespace, or enumeration [...] ../../../../../gstreamer/subprojects/gst-plugins-good/ext/qt/qtglrenderer.cc:458:5: error: 'QEventLoop' was not declared in this scope; did you mean 'QEvent'? ../../../../../gstreamer/subprojects/gst-plugins-good/ext/qt/qtglrenderer.cc:459:9: error: 'loop' was not declared in this scope If accessibility is enabled, the includes for QCoreApplication and QEventLoop are indirectly pulled via QWidget. Add the required headers as documented in [1] and [2]. [1] https://doc.qt.io/qt-5/qcoreapplication.html [2] https://doc.qt.io/qt-5/qeventloop.html Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4815> |
||
---|---|---|
.. | ||
gstplugin.cc | ||
gstqsgtexture.cc | ||
gstqsgtexture.h | ||
gstqtelement.cc | ||
gstqtelements.h | ||
gstqtgl.h | ||
gstqtglutility.cc | ||
gstqtglutility.h | ||
gstqtoverlay.cc | ||
gstqtoverlay.h | ||
gstqtsink.cc | ||
gstqtsink.h | ||
gstqtsrc.cc | ||
gstqtsrc.h | ||
meson.build | ||
qtglrenderer.cc | ||
qtglrenderer.h | ||
qtitem.cc | ||
qtitem.h | ||
qtplugin.pro | ||
qtwindow.cc | ||
qtwindow.h | ||
README.md |
Building for non-linux platforms
Compiling the gstqmlgl plugin for non-linux platforms is not so trivial. This file explains the steps that need to be followed for a successful build.
Step 1
Build GStreamer for the target platform using cerbero.
Step 2
Enter the cerbero shell:
./cerbero-uninstalled -c config/<target platform config>.cbc shell
Step 3
Export the following environment variables:
export PATH=/path/to/Qt/<version>/<platform>/bin:$PATH
if you are cross-compiling (ex. for android), also export:
export PKG_CONFIG_SYSROOT_DIR=/
Additionally, if you are building for android:
export ANDROID_NDK_ROOT=$ANDROID_NDK
Note: the ANDROID_NDK variable is set by the cerbero shell; if you are not using this shell, set it to the directory where you have installed the android NDK. Additionally, if you are not building through the cerbero shell, it is also important to have set PKG_CONFIG_LIBDIR to $GSTREAMER_ROOT/lib/pkgconfig.
Step 4
cd to the directory of the gstqmlgl plugin and run:
qmake .
make
Step 5
Copy the built plugin to your $GSTREAMER_ROOT/lib/gstreamer-1.0 or link to it directly if it is compiled statically
Building for Windows using pre-built gstreamer development package and Qt Creator
Step 1
Open qtplugin.pro
in Qt Creator as project and configure it as usual.
Step 2
Open qtplugin.pro
in the editor and make sure GSTREAMER_PATH
variable in qmlplugin.pro
is set to the path of your gstreamer SDK installation. This directory
should contain subdirectories bin
, include
, lib
etc. Pay attention to the correct choice
of x86 or x86_64 platform.
Step 3
Build the project as usual.
Step 3
Copy the built plugin to your $GSTREAMER_ROOT/lib/gstreamer-1.0 or link to it directly if it is compiled statically.
Building for Windows using pre-built gstreamer development package and Qt on MinGW command line
Step 1
Launch Qt developer command line from the Start menu.
Step 2
cd to the directory of the gstqmlgl plugin and make sure GSTREAMER_PATH
variable in qmlplugin.pro
is set to the path of your gstreamer SDK installation. This directory
should contain subdirectories bin
, include
, lib
etc. Pay attention to the correct choice
of x86 or x86_64 platform.
Step 3
Run the following commands in the gstqmlgl plugin directory:
qmake
mingw32-make
Step 4
Copy the built plugin to your $GSTREAMER_ROOT/lib/gstreamer-1.0 or link to it directly if it is compiled statically.