QtGqtreamer qml example
-
Hi !
In my project I would like to implement a QtGstreamer to display a camera view. I am trying to run this example :
https://gstreamer.freedesktop.org/data/doc/gstreamer/head/qt-gstreamer/html/examples_2qmlplayer_2main_8cpp-example.htmlBut I get an error when I want to import QtGstreamer in my QML : QML Module not found (QtGstreamer)
Here is my pro file, did I miss something ? :
SOURCES += \ main.cpp TEMPLATE = app TARGET = qmlplayer # produce nice compilation output CONFIG += silent LIBS += -Lc:/gstreamer/1.0/x86/lib LIBS += -lglib-2.0 -lwinpthread -lgstreamer-1.0 -lgobject-2.0 -lgmodule-2.0 -lgthread-2.0 PKGCONFIG += Qt5GStreamer-1.0 Qt5GStreamerUi-1.0 QT += widgets # Recommended, to avoid possible issues with the "emit" keyword # You can otherwise also define QT_NO_EMIT, but notice that this is not a documented Qt macro. DEFINES += QT_NO_KEYWORDS # link against QtDeclarative and QtOpenGL QT += quick opengl QT += qml core widgets INCLUDEPATH += "/usr/include/gstreamer-1.0/" DISTFILES += \ qmlplayer.qml
Thanks for help :)
-
I am reading other question on forums, and for this problem, people are speaking about modifying a "bashsrc file".
I am quite loose about it, what should I do with it and why ? :/For example :
https://www.linuxquestions.org/questions/linux-newbie-8/error-package-qt5gstreamer-0-10-not-found-4175492115/ -
@Chanchan said in QtGqtreamer qml example:
bashsrc
it's not bashsrc it's .bashrc and it is located in your home directory.
-
@Chanchan said in QtGqtreamer qml example:
What should I do with it ?
Well, copy the two lines from that link and put it in that file (at the end). But don't forget to adapt these two lines to your situation.
-
@jsulm mmh for the first line I think the good line for me is this one :
export PATH=/home/thales/Qt/5.9.8/gcc_64/bin:$PATH
but I cant understand this line :
export PKG_CONFIG_PATH=~/Desktop/newGSTr/qt-gstreamer-0.10.3/lib/x86_64-linux-gnu/pkgconfig/:$PKG_CONFIG_PATH
It seems referring to the project itself ("newGSTr"), my project doesn't have any ppkgconfig folder or file