Enable Gstreamer in Qt5 configuration
-
[quote author="_dmp" date="1386143087"]I cross compile Qt 5.2 for imx6 from source and ./configure just dont try find gstreamer from rootfs. I look at ./configure inside and dont find anything about gstreamer. What can I do?[/quote]
Have you solved this problem?
I'm working on it too. -
I did not try to cross-compile neither Qt nor GStreamer. So this is just my guess.
On Linux Qt configure tries to find gstreamer using pkg-config utility.
pkg-config uses $PKG_CONFIG_PATH to look for all available packages.
The packages are the text files with simple structure and .pc extension.Try to find gstreamer*.pc files in your cross-compiled gstreamer and if you find the files then append a path to these files to PKG_CONFIG_PATH environment variable and then run configure from Qt.
-
Is there meanwhile a solution on how to configure Qt5.3 to use gstreamer? I have the same Problem on the Raspberry Pi.
I'm using this tutorial: http://qt-project.org/wiki/Native_Build_of_Qt5_on_a_Raspberry_Pi
I ignored the change of "QT_CFLAGS_GSTREAMER=" in the configure script, because it is not there. Additionally I set the following environment variables before running configure to get "pkg-config ............. yes":
@PKG_CONFIG_LIBDIR="/usr/lib/pkgconfig:/usr/lib/arm-linux-gnueabihf/pkgconfig:/usr/share/pkgconfig"
PKG_CONFIG_SYSROOT_DIR="/."
PKG_CONFIG_PATH="/usr/lib/pkgconfig:/usr/lib/arm-linux-gnueabihf/pkgconfig:/usr/share/pkgconfig"@I read a little bit in the configure script code and at the part where the "Configure summary" is generated I found nothing where it is possible to add additional Packages (for example found by pkg-config) so is it even possible that the configure script finds gstreamer or is it even searching?
-
Hi and welcome to devnet,
Did you install the gstreamer development packages ?
-
yes I have installed all packages which are listed on the "wiki page":http://qt-project.org/wiki/Native_Build_of_Qt5_on_a_Raspberry_Pi (first code section line 3). For gstreamer this are the following:
@libgstreamer0.10-dev
libgstreamer-plugins-base0.10-dev
gstreamer-tools
gstreamer0.10-plugins-good
gstreamer0.10-plugins-bad@gstreamer itselfs works:
@gst-launch-0.10 videotestsrc ! video/x-raw-rgb, framerate=25/1, width=640, height=360 ! ffmpegcolorspace ! fbdevsink@ -
Did you do that on your Raspberry Pi ?
-
Do you have your Pi root filesystem accessible on your desktop computer ?
-
What parameters did you pass to configure ?
-
I copied it from the wiki page: "http://qt-project.org/wiki/Native_Build_of_Qt5_on_a_Raspberry_Pi":http://qt-project.org/wiki/Native_Build_of_Qt5_on_a_Raspberry_Pi
@./configure -v -opengl es2 -device linux-rasp-pi-g++ -device-option CROSS_COMPILE=/usr/bin/ -opensource -confirm-license -optimized-qmake -reduce-exports -release -qt-pcre -make libs -prefix /usr/local/qt5 &> output@
-
Ok… I missed it the first time… you are following the instructions to build Qt ON the raspberry pi but you are trying to cross-compile it from your desktop…
"This":https://qt-project.org/wiki/RaspberryPi_Beginners_guide guid shows how to cross-compile it
-
No, I'm building Qt direct on the Raspberry, like on the wiki page.
Sorry if I understand your question wrong when you asked if I had the filesystem accessible on my desktop computer. At the moment I dont have it on my desktop pc, I wanted to say that I could easily access it if needed for the solution by just insert the Raspberry Pi SD Card to my desktop computer. (Did you mean if I had an image of the filesystem on my desktop computer for cross compiling? => No)
If your thinking of the CROSS_COMPILE option by calling configure: This is sayed on the wiki page:
bq. In order to properly run configure for Qt5 on the Raspberry Pi, you need to point the CROSS_COMPILE variable to the native compiler located at /usr/bin/g++. The CROSS_COMPILE parameter is the path to the compiler (without the g++). If you do not do this properly it will complain that it is not being cross compiled.
-
My bad, I was thinking about the SYSROOT parameter that was missing. But in your case it's unrelated.
-
Found the solution in the compile logfiles. The configure script does not search for gstreamer anymore. Qt searches for gstreamer during compile of qt multimedia plugin in. But the compile step needs pkg-config to be set (see above) to find gstreamer.
Now I can play videos, but very very slow, so I don't know if additional steps are needed for hardware acceleration.
-
IIRC, you have to look for "gst omx raspberry pi"
-
gst-omx is the rigth track but it doesn't compile anymore.
I started with this: http://raspberrypi.stackexchange.com/questions/528/how-can-i-install-gstreamer-gst-omx
This post is 2 years old so the git repository moved here: http://cgit.freedesktop.org/gstreamer/gst-omx/ and the configure call need aditional parameters, see here: http://gstreamer-devel.966125.n4.nabble.com/Pb-with-omx-compilation-td4668631.html#a4668934But make throws still errors like "unknown type name 'GStaticMutex'". With google i found presumtions that this is because GStaticMutex, etc. was deprecated in some librarys.
The gst-omx development of the 0.10 branch stopped a year ago. So I think this errors are fixed in current version but the current version needs gstreamer-1.x and Qt5 wants gstreamer.0.10 :-(
-
Depending on your needs you could use QtGStreamer in between