gst1-imx: add package
PATCH v3 1/1 gst1-imx: add package
Open-source GStreamer 1.0 plugins for i.MX6 platforms. More info at https://github.com/Freescale/gstreamer-imx
---
Modifications v2->v3:
- Change package name from gst1-plugins-imx to gst1-imx
- Remove commands unnecessary parentheses
- Modify package comment to clarify it is only working on i.MX6
Modifications v1->v2:
- Use of github helper macro
- Modify package comment with Peter S. original patch
- Add comment for eglibc dependency (due to GPU libs)
- Remove comments on package dependencies
This patch has been tested using an i.MX6Q SabreLite (nitrogen6x config) along with the usual Tears of Steel movie in 1080p:
http://media.xiph.org/mango/tears_of_steel_1080p.webm
Below are the commands used to test the different sinks:
$ gst-launch-1.0 playbin uri=file:///root/tears_of_steel_1080p.webm $ gst-launch-1.0 filesrc location=/root/tears_of_steel_1080p.webm ! \ matroskademux ! imxvpudec ! imxipusink $ gst-launch-1.0 filesrc location=/root/tears_of_steel_1080p.webm ! \ matroskademux ! imxvpudec ! imxeglvivsink
The toolchain used was the Sourcery CodeBench 2014.05. The video above also requires the following extra configuration in order to demux the content:
BR2_PACKAGE_GST1_PLUGINS_GOOD=y BR2_PACKAGE_GST1_PLUGINS_GOOD_PLUGIN_MATROSKA=y
Thanks,
Gary
--- package/gstreamer1/Config.in | 1 + package/gstreamer1/gst1-imx/Config.in | 25 ++++++++++++++++ package/gstreamer1/gst1-imx/gst1-imx.mk | 52 +++++++++++++++++++++++++++++++++ 3 files changed, 78 insertions(+) create mode 100644 package/gstreamer1/gst1-imx/Config.in create mode 100644 package/gstreamer1/gst1-imx/gst1-imx.mk
package/gstreamer1/Config.in +1 -0
@@ -6,6 +6,7 @@ source "package/gstreamer1/gst1-plugins-base/Config.in" source "package/gstreamer1/gst1-plugins-good/Config.in" source "package/gstreamer1/gst1-plugins-bad/Config.in" source "package/gstreamer1/gst1-plugins-ugly/Config.in" +source "package/gstreamer1/gst1-imx/Config.in" source "package/gstreamer1/gst1-libav/Config.in" source "package/gstreamer1/gst1-validate/Config.in" source "package/gstreamer1/gst-omx/Config.in"
package/gstreamer1/gst1-imx/Config.in new file +25 -0
@@ -0,0 +1,25 @@ +comment "gst1-imx needs an imx-specific Linux kernel to be built" + depends on BR2_arm && !BR2_LINUX_KERNEL + +# Required by gpu-viv-bin-mx6q +comment "gst1-imx needs an (e)glibc toolchain" + depends on BR2_arm + depends on !BR2_TOOLCHAIN_USES_GLIBC + +config BR2_PACKAGE_GST1_IMX + bool "gst1-imx" + depends on BR2_LINUX_KERNEL + depends on BR2_arm # Only relevant for i.MX + depends on BR2_TOOLCHAIN_USES_GLIBC # gpu-viv-bin-mx6q + depends on BR2_PACKAGE_GPU_VIV_BIN_MX6Q + depends on BR2_PACKAGE_LIBFSLVPUWRAP + select BR2_PACKAGE_GST1_PLUGINS_BASE + help + This is a set of GStreamer 1.0 plugins for plugins for Freescale's + i.MX6 platforms, with emphasis on video en/decoding using the VPU + engine. + + This software supports only the i.MX6 SoC family and requires a + kernel that includes the i.MX6 specific headers to be built. + + The software as a whole is currently in beta stage.
package/gstreamer1/gst1-imx/gst1-imx.mk new file +52 -0
52 lines not on this page · raw message
Signature · 1 line
2.1.1
PATCH v3 1/1 gst1-imx: add package
Dear Gary,
Quoted 20 lines · Gary Bisson
Open-source GStreamer 1.0 plugins for i.MX6 platforms. More info at https://github.com/Freescale/gstreamer-imx
Signed-off-by Gary Bisson <[email protected]>---
Modificationsv2->v3:
- Change package name from gst1-plugins-imx to gst1-imx
- Remove commands unnecessary parentheses
- Modify package comment to clarify it is only working on i.MX6Modifications
v1->v2:
- Use of github helper macro
- Modify package comment with Peter S. original patch
- Add comment for eglibc dependency (due to GPU libs)
- Remove comments on package dependenciesThis patch has been tested using an i.MX6Q SabreLite (nitrogen6x config) along with the usual Tears of Steel movie in 1080p:
http://media.xiph.org/mango/tears_of_steel_1080p.webm
Quoted 7 lines
Below are the commands used to test the different sinks:
$ gst-launch-1.0 playbin uri=file:///root/tears_of_steel_1080p.webm $ gst-launch-1.0 filesrc location=/root/tears_of_steel_1080p.webm ! \ matroskademux ! imxvpudec ! imxipusink $ gst-launch-1.0 filesrc location=/root/tears_of_steel_1080p.webm ! \ matroskademux ! imxvpudec ! imxeglvivsink
I tested it on i.MX6DL SABRESD (not Quad), based on freescale_imx6dlsabresd_defconfig, but with libc changed to glibc. All the three pipelines you provided work, with the first one eating up ~30% of CPU time, while the other two ones take only 2~3% CPU only (but play no audio of course).
A couple of comments below.
package/gstreamer1/gst1-imx/Config.in line 7
Quoted 13 lines
package/gstreamer1/gst1-imx/Config.in new file +7
-0@@ -0,0 +1,25 @@ +comment "gst1-imx needs an imx-specific Linux kernel to be built" + depends on BR2_arm && !BR2_LINUX_KERNEL + +# Required by gpu-viv-bin-mx6q +comment "gst1-imx needs an (e)glibc toolchain" + depends on BR2_arm + depends on !BR2_TOOLCHAIN_USES_GLIBC
Sorry for coming back on the comments issue, but...
I simulated a newbie wanting to use gst1-imx:
- make freescale_imx6dlsabresd_defconfig
- make menuconfig
- go to target packages -> audio/video, look for gst1
-> "gstreamer 1.x needs a toolchain w/ wchar, threads" is shown
- change toolchain settings to enable wchar
- go to target packages -> audio/video, enable gst1
-> "gst1-imx needs an (e)glibc toolchain" is shown
- change toolchain settings to use glibc
- go back to target packages -> audio/video
-> gst1-imx disappeared, no comments shown
-> user panic!Well, I don't remember exactly how we came to the conclusion that some of the comments should be removed, but I think they should have not.
The BR2_PACKAGE_LIBFSLVPUWRAP and BR2_PACKAGE_GPU_VIV_BIN_MX6Q dependencies are software packages, not architecture features, so they are user-selectable and thus should show a comment when not satisfied.
However, to me this patch is an improvement and could be merged as-is, and the comments re-added later if discussions on this point does not settle quickly. Gary seems very responsive and willing to have a good support for this package, so I guess he will keep on.
package/gstreamer1/gst1-imx/Config.in line 11
Quoted 4 lines
package/gstreamer1/gst1-imx/Config.in new file +4
-0+ +config BR2_PACKAGE_GST1_IMX + bool "gst1-imx" + depends on BR2_LINUX_KERNEL
As per Arnout's suggestion on v2, there should be a # libfslvpuwrap here.
With that fixed:
Signature · 1 line
Luca
PATCH v3 1/1 gst1-imx: add package
Luca, All,
Quoted 10 lines · Luca Ceresoli
Dear Gary,
Quoted 6 lines · Gary Bisson
[snip]
$ gst-launch-1.0 playbin uri=file:///root/tears_of_steel_1080p.webm $ gst-launch-1.0 filesrc location=/root/tears_of_steel_1080p.webm ! \ matroskademux ! imxvpudec ! imxipusink $ gst-launch-1.0 filesrc location=/root/tears_of_steel_1080p.webm ! \ matroskademux ! imxvpudec ! imxeglvivsink
Quoted 5 lines
I tested it on i.MX6DL SABRESD (not Quad), based on
freescale_imx6dlsabresd_defconfig, but with libc changed to glibc. All the three pipelines you provided work, with the first one eating up ~30% of CPU time, while the other two ones take only 2~3% CPU only (but play no audio of course).
Good to hear everything worked out. Thanks for checking CPU consumption, although 30% seems high for audio handling we can clearly see the video is decoded through the VPU.
Quoted 14 lines
[snip]
Sorry for coming back on the comments issue, but...I simulated a newbie wanting to use gst1-imx:
- makefreescale_imx6dlsabresd_defconfig
- make menuconfig
- go to target packages -> audio/video, look for gst1 -> "gstreamer 1.x needs a toolchain w/ wchar, threads" is shown
- change toolchain settings to enable wchar
- go to target packages -> audio/video, enable gst1
-> "gst1-imx needs an (e)glibc toolchain" is shown
- change toolchain settings to use glibc
- go back to target packages -> audio/video
-> gst1-imx disappeared, no comments shown
Quoted 8 lines
-> user panic!Well, I don't remember exactly how we came to the conclusion that some of the comments should be removed, but I think they should have not.
The
BR2_PACKAGE_LIBFSLVPUWRAPandBR2_PACKAGE_GPU_VIV_BIN_MX6Qdependencies are software packages, not architecture features, so they are user-selectable and thus should show a comment when not satisfied.
Yes that is exactly why I've put comments in the first place. Yann wasn't a huge fan of that solution and I understand it [1]. The best would be to find another approach to be able to do the select.
Quoted 5 lines
However, to me this patch is an improvement and could be merged as-is, and the comments re-added later if discussions on this point does not settle quickly. Gary seems very responsive and willing to have a good support for this package, so I guess he will keep on.
Quoted 7 lines
package/gstreamer1/gst1-imx/Config.in line 11
Quoted 4 lines
package/gstreamer1/gst1-imx/Config.in new file +4
-0+ +config BR2_PACKAGE_GST1_IMX + bool "gst1-imx" + depends on BR2_LINUX_KERNELAs per Arnout's suggestion on v2, there should be a # libfslvpuwrap here.
Actually I think this should not be added as this package also needs the kernel headers for IPU use (see source code under src/ipu).
Quoted 3 lines
With that fixed:
Reviewed-by Luca Ceresoli <[email protected]>Tested-by Luca Ceresoli <[email protected]>
Thanks,
Gary
[1] http://lists.busybox.net/pipermail/buildroot/2014-October/109264.html
PATCH v3 1/1 gst1-imx: add package
Dear Gary,
Quoted 19 lines · Gary Bisson
Luca, All,
Quoted 10 lines · Luca Ceresoli
Dear Gary,
Quoted 6 lines · Gary Bisson
[snip]
$ gst-launch-1.0 playbin uri=file:///root/tears_of_steel_1080p.webm $ gst-launch-1.0 filesrc location=/root/tears_of_steel_1080p.webm ! \ matroskademux ! imxvpudec ! imxipusink $ gst-launch-1.0 filesrc location=/root/tears_of_steel_1080p.webm ! \ matroskademux ! imxvpudec ! imxeglvivsinkQuoted 5 lines
I tested it on i.MX6DL SABRESD (not Quad), based on
freescale_imx6dlsabresd_defconfig, but with libc changed to glibc. All the three pipelines you provided work, with the first one eating up ~30% of CPU time, while the other two ones take only 2~3% CPU only (but play no audio of course).
Quoted 3 lines
Good to hear everything worked out. Thanks for checking CPU consumption, although 30% seems high for audio handling we can clearly see the video is decoded through the VPU.
Isn't the first pipeline simply not using the hardware decoder?
Quoted 10 lines
Quoted 7 lines
package/gstreamer1/gst1-imx/Config.in line 11
Quoted 4 lines
package/gstreamer1/gst1-imx/Config.in new file +4
-0+ +config BR2_PACKAGE_GST1_IMX + bool "gst1-imx" + depends on BR2_LINUX_KERNELAs per Arnout's suggestion on v2, there should be a # libfslvpuwrap here.
Actually I think this should not be added as this package also needs the kernel headers for IPU use (see source code under src/ipu).
I see. Thanks for the clarification.
Signature · 1 line
Luca
PATCH v3 1/1 gst1-imx: add package
Luca, All,
Quoted 27 lines · Luca Ceresoli
Dear Gary,
Quoted 24 lines · Gary Bisson
Luca, All,
Quoted 18 lines · Luca Ceresoli
Dear Gary,
Quoted 7 lines · Gary Bisson
[snip]
$ gst-launch-1.0 playbin uri=file:///root/tears_of_steel_1080p.webm $ gst-launch-1.0 filesrc location=/root/tears_of_steel_1080p.webm ! \ matroskademux ! imxvpudec ! imxipusink $ gst-launch-1.0 filesrc location=/root/tears_of_steel_1080p.webm ! \ matroskademux ! imxvpudec ! imxeglvivsinkI tested it on i.MX6DL SABRESD (not Quad), based on
freescale_imx6dlsabresd_defconfig, but with libc changed to glibc. All the three pipelines you provided work, with the first one eating up ~30% of CPU time, while the other two ones take only 2~3% CPU only (but play no audio of course).
Quoted 7 lines
Quoted 3 lines
Good to hear everything worked out. Thanks for checking CPU consumption, although 30% seems high for audio handling we can clearly see the video is decoded through the VPU.
Isn't the first pipeline simply not using the hardware decoder?
No, decoding both 1080p video plus audio in software would be using even more CPU. Plus the traces suggest the use of imxvpudec.
Quoted 10 lines
Quoted 10 lines
Quoted 8 lines
package/gstreamer1/gst1-imx/Config.in line 11
Quoted 4 lines
package/gstreamer1/gst1-imx/Config.in new file +4
-0+ +config BR2_PACKAGE_GST1_IMX + bool "gst1-imx" + depends on BR2_LINUX_KERNELAs per Arnout's suggestion on v2, there should be a # libfslvpuwrap here.
Quoted 6 lines
Quoted 2 lines
Actually I think this should not be added as this package also needs the kernel headers for IPU use (see source code under src/ipu).
I see. Thanks for the clarification.
Let me know if there's any modification you'd like on this patch.
Thanks,
Gary
PATCH v3 1/1 gst1-imx: add package
Dear Gary, All,
Quoted 1 line · Gary Bisson
Let me know if there's any modification you'd like on this patch.
I haven't (that's why I gave you my Reviewed-by and Acked-by tags).
As I wrote in my first reply, I am not that happy with the absence of kconfig comments about missing dependencies. Nevertheless I would commit this patch, because it is an improvement anyway. Comments may be added later if desired.
Yann, you commented on this topic in past submissions of this patch, are you satisfied with the current approach?
Now that the stabilization month is over, hopefully this patch will get merged. BTW, it cleanly applies on current master.
Signature · 1 line
Luca