* [Buildroot] [PATCH 1/2] gst1-vaapi: new package.
@ 2017-02-01 13:18 Adam Duskett
2017-02-01 13:18 ` [Buildroot] [PATCH 2/2] gst1-vaapi: add optional encoder support Adam Duskett
` (2 more replies)
0 siblings, 3 replies; 7+ messages in thread
From: Adam Duskett @ 2017-02-01 13:18 UTC (permalink / raw)
To: buildroot
gstreamer-vaapi consists in a collection of VA-API based plugins for
GStreamer and helper libraries. These libraries are used for hardware
decoding and encoding of several video formats.
decoding formats:
JPEG, MPEG-2, MPEG-4:2, H.264 AVC, H.264 MVC, VP8, VC-1, WMV3, and HEVC.
encoding formats:
MPEG-2, H.264 AVC, H.264 MVC, JPEG, VP8, HEVC
The package won't compile without at least one renderer enabled, so I
chose to enable DRM by default, as X11, GLX, and wayland are heavy
handed with the dependencies. As such, I have disabled every option
defaulting to yes except for DRM for the first patch.
Also, these codecs are only for x86 and require a Intel CPU (See Hardware
Requirements on line 82 of the README file.)
Signed-off-by: Adam Duskett <Adamduskett@outlook.com>
---
package/gstreamer1/Config.in | 1 +
package/gstreamer1/gst1-vaapi/Config.in | 39 +++++++++++++++++++++++++++
package/gstreamer1/gst1-vaapi/gst1-vaapi.hash | 2 ++
package/gstreamer1/gst1-vaapi/gst1-vaapi.mk | 28 +++++++++++++++++++
4 files changed, 70 insertions(+)
create mode 100644 package/gstreamer1/gst1-vaapi/Config.in
create mode 100644 package/gstreamer1/gst1-vaapi/gst1-vaapi.hash
create mode 100644 package/gstreamer1/gst1-vaapi/gst1-vaapi.mk
diff --git a/package/gstreamer1/Config.in b/package/gstreamer1/Config.in
index 23862bd..aef75b5 100644
--- a/package/gstreamer1/Config.in
+++ b/package/gstreamer1/Config.in
@@ -10,5 +10,6 @@ source "package/gstreamer1/gst1-imx/Config.in"
source "package/gstreamer1/gst1-libav/Config.in"
source "package/gstreamer1/gst1-rtsp-server/Config.in"
source "package/gstreamer1/gst1-validate/Config.in"
+source "package/gstreamer1/gst1-vaapi/Config.in"
source "package/gstreamer1/gst-omx/Config.in"
endif
diff --git a/package/gstreamer1/gst1-vaapi/Config.in b/package/gstreamer1/gst1-vaapi/Config.in
new file mode 100644
index 0000000..44461e3
--- /dev/null
+++ b/package/gstreamer1/gst1-vaapi/Config.in
@@ -0,0 +1,39 @@
+config BR2_PACKAGE_GST1_VAAPI
+ bool "gst1-vaapi"
+ select BR2_PACKAGE_LIBVA
+ select BR2_PACKAGE_LIBDRM
+ select BR2_PACKAGE_GST1_PLUGINS_BASE
+ select BR2_PACKAGE_GST1_PLUGINS_BAD # gstreamer-codecparsers
+ depends on BR2_i386 || BR2_x86_64 # Only relevant for x86
+ depends on !BR2_STATIC_LIBS
+ help
+ gstreamer-vaapi consists in a collection of VA-API based plugins for
+ GStreamer and helper libraries.
+
+ vaapi<CODEC>dec is used to decode JPEG, MPEG-2, MPEG-4:2, H.264
+ AVC, H.264 MVC, VP8, VC-1, WMV3, HEVC videos to VA surfaces,
+ depending on the actual value of <CODEC> and the underlying
+ hardware capabilities. This plugin is also able to implicitly
+ download the decoded surface to raw YUV buffers.
+
+ vaapi<CODEC>enc is used to encode into MPEG-2, H.264 AVC, H.264
+ MVC, JPEG, VP8, HEVC videos, depending on the actual value of
+ <CODEC> (mpeg2, h264, etc.) and the hardware capabilities. By
+ default, raw format bitstreams are generated, so the result may be
+ piped to a muxer, e.g. qtmux for MP4 containers.
+
+ vaapipostproc is used to filter VA surfaces, for e.g. scaling,
+ deinterlacing (bob, motion-adaptive, motion-compensated), noise
+ reduction or sharpening. This plugin is also used to upload raw
+ YUV pixels into VA surfaces.
+
+ vaapisink is used to render VA surfaces to an X11 or Wayland
+ display. This plugin also features a "headless" mode (DRM) more
+ suited to remote transcode scenarios, with faster throughput.
+
+ https://cgit.freedesktop.org/gstreamer/gstreamer-vaapi
+
+comment "gst1-vaapi needs udev /dev management and a toolchain w/ threads, dynamic library"
+ depends on BR2_i386 || BR2_x86_64
+ depends on !BR2_TOOLCHAIN_HAS_THREADS || BR2_STATIC_LIBS || \
+ !BR2_PACKAGE_HAS_UDEV
diff --git a/package/gstreamer1/gst1-vaapi/gst1-vaapi.hash b/package/gstreamer1/gst1-vaapi/gst1-vaapi.hash
new file mode 100644
index 0000000..f3c6252
--- /dev/null
+++ b/package/gstreamer1/gst1-vaapi/gst1-vaapi.hash
@@ -0,0 +1,2 @@
+# from https://gstreamer.freedesktop.org/src/gstreamer-vaapi/gstreamer-vaapi-1.10.3.tar.xz.sha256sum
+sha256 cea827066a152a6afa1d0c43544dfbda285238156d4c3b77f9d4037bbe79361e gstreamer-vaapi-1.10.3.tar.xz
diff --git a/package/gstreamer1/gst1-vaapi/gst1-vaapi.mk b/package/gstreamer1/gst1-vaapi/gst1-vaapi.mk
new file mode 100644
index 0000000..470d95f
--- /dev/null
+++ b/package/gstreamer1/gst1-vaapi/gst1-vaapi.mk
@@ -0,0 +1,28 @@
+################################################################################
+#
+# gst1-vaapi
+#
+################################################################################
+
+GST1_VAAPI_VERSION = 1.10.3
+GST1_VAAPI_SITE = https://gstreamer.freedesktop.org/src/gstreamer-vaapi
+GST1_VAAPI_SOURCE = gstreamer-vaapi-$(GST1_VAAPI_VERSION).tar.xz
+GST1_VAAPI_LICENSE = LGPLv2.1+
+GST1_VAAPI_LICENSE_FILES = COPYING.LIB
+
+GST1_VAAPI_DEPENDENCIES += \
+ gstreamer1 \
+ gst1-plugins-base \
+ gst1-plugins-bad \
+ libva \
+ libdrm
+
+GST1_VAAPI_CONF_OPTS += \
+ --disable-encoders \
+ --disable-x11 \
+ --disable-glx \
+ --disable-wayland \
+ --disable-egl \
+ --disable-gtk-doc-html
+
+$(eval $(autotools-package))
--
2.9.3
^ permalink raw reply related [flat|nested] 7+ messages in thread* [Buildroot] [PATCH 2/2] gst1-vaapi: add optional encoder support.
2017-02-01 13:18 [Buildroot] [PATCH 1/2] gst1-vaapi: new package Adam Duskett
@ 2017-02-01 13:18 ` Adam Duskett
2017-03-12 20:52 ` Thomas Petazzoni
2017-02-01 21:30 ` [Buildroot] [PATCH 1/2] gst1-vaapi: new package Thomas Petazzoni
2017-03-12 20:52 ` Thomas Petazzoni
2 siblings, 1 reply; 7+ messages in thread
From: Adam Duskett @ 2017-02-01 13:18 UTC (permalink / raw)
To: buildroot
Signed-off-by: Adam Duskett <Adamduskett@outlook.com>
---
package/gstreamer1/gst1-vaapi/Config.in | 7 +++++++
package/gstreamer1/gst1-vaapi/gst1-vaapi.mk | 5 ++++-
2 files changed, 11 insertions(+), 1 deletion(-)
diff --git a/package/gstreamer1/gst1-vaapi/Config.in b/package/gstreamer1/gst1-vaapi/Config.in
index 44461e3..e33e612 100644
--- a/package/gstreamer1/gst1-vaapi/Config.in
+++ b/package/gstreamer1/gst1-vaapi/Config.in
@@ -33,6 +33,13 @@ config BR2_PACKAGE_GST1_VAAPI
https://cgit.freedesktop.org/gstreamer/gstreamer-vaapi
+if BR2_PACKAGE_GST1_VAAPI
+
+config BR2_PACKAGE_GST1_VAAPI_ENCODERS
+ bool "Build encoders"
+
+endif
+
comment "gst1-vaapi needs udev /dev management and a toolchain w/ threads, dynamic library"
depends on BR2_i386 || BR2_x86_64
depends on !BR2_TOOLCHAIN_HAS_THREADS || BR2_STATIC_LIBS || \
diff --git a/package/gstreamer1/gst1-vaapi/gst1-vaapi.mk b/package/gstreamer1/gst1-vaapi/gst1-vaapi.mk
index 470d95f..966fe9b 100644
--- a/package/gstreamer1/gst1-vaapi/gst1-vaapi.mk
+++ b/package/gstreamer1/gst1-vaapi/gst1-vaapi.mk
@@ -18,11 +18,14 @@ GST1_VAAPI_DEPENDENCIES += \
libdrm
GST1_VAAPI_CONF_OPTS += \
- --disable-encoders \
--disable-x11 \
--disable-glx \
--disable-wayland \
--disable-egl \
--disable-gtk-doc-html
+ifneq ($(BR2_PACKAGE_GST1_VAAPI_ENCODERS),y)
+ GST1_VAAPI_CONF_OPTS += --disable-encoders
+endif
+
$(eval $(autotools-package))
--
2.9.3
^ permalink raw reply related [flat|nested] 7+ messages in thread
* [Buildroot] [PATCH 2/2] gst1-vaapi: add optional encoder support.
2017-02-01 13:18 ` [Buildroot] [PATCH 2/2] gst1-vaapi: add optional encoder support Adam Duskett
@ 2017-03-12 20:52 ` Thomas Petazzoni
0 siblings, 0 replies; 7+ messages in thread
From: Thomas Petazzoni @ 2017-03-12 20:52 UTC (permalink / raw)
To: buildroot
Hello,
On Wed, 1 Feb 2017 08:18:54 -0500, Adam Duskett wrote:
> +if BR2_PACKAGE_GST1_VAAPI
> +
> +config BR2_PACKAGE_GST1_VAAPI_ENCODERS
> + bool "Build encoders"
Changed to:
bool "enable encoders"
> +ifneq ($(BR2_PACKAGE_GST1_VAAPI_ENCODERS),y)
> + GST1_VAAPI_CONF_OPTS += --disable-encoders
This line should not be indented.
> +endif
Also, we normally explicitly enable and disable, so I've changed this
to:
+ifeq ($(BR2_PACKAGE_GST1_VAAPI_ENCODERS),y)
+GST1_VAAPI_CONF_OPTS += --enable-encoders
+else
+GST1_VAAPI_CONF_OPTS += --disable-encoders
+endif
Best regards,
Thomas
--
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Buildroot] [PATCH 1/2] gst1-vaapi: new package.
2017-02-01 13:18 [Buildroot] [PATCH 1/2] gst1-vaapi: new package Adam Duskett
2017-02-01 13:18 ` [Buildroot] [PATCH 2/2] gst1-vaapi: add optional encoder support Adam Duskett
@ 2017-02-01 21:30 ` Thomas Petazzoni
2017-02-03 13:08 ` Adam Duskett
2017-03-12 20:52 ` Thomas Petazzoni
2 siblings, 1 reply; 7+ messages in thread
From: Thomas Petazzoni @ 2017-02-01 21:30 UTC (permalink / raw)
To: buildroot
Hello,
On Wed, 1 Feb 2017 08:18:53 -0500, Adam Duskett wrote:
> gstreamer-vaapi consists in a collection of VA-API based plugins for
> GStreamer and helper libraries. These libraries are used for hardware
> decoding and encoding of several video formats.
>
> decoding formats:
> JPEG, MPEG-2, MPEG-4:2, H.264 AVC, H.264 MVC, VP8, VC-1, WMV3, and HEVC.
>
> encoding formats:
> MPEG-2, H.264 AVC, H.264 MVC, JPEG, VP8, HEVC
>
> The package won't compile without at least one renderer enabled, so I
> chose to enable DRM by default, as X11, GLX, and wayland are heavy
> handed with the dependencies. As such, I have disabled every option
> defaulting to yes except for DRM for the first patch.
>
> Also, these codecs are only for x86 and require a Intel CPU (See Hardware
> Requirements on line 82 of the README file.)
>
> Signed-off-by: Adam Duskett <Adamduskett@outlook.com>
We already had a patch pending in patchwork adding the same package,
proposed by Jesper Baekdahl. Could you please sync with Jesper to
propose a single patch?
Thanks,
Thomas
--
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Buildroot] [PATCH 1/2] gst1-vaapi: new package.
2017-02-01 21:30 ` [Buildroot] [PATCH 1/2] gst1-vaapi: new package Thomas Petazzoni
@ 2017-02-03 13:08 ` Adam Duskett
2017-02-07 14:07 ` Adam Duskett
0 siblings, 1 reply; 7+ messages in thread
From: Adam Duskett @ 2017-02-03 13:08 UTC (permalink / raw)
To: buildroot
On Wed, Feb 1, 2017 at 4:30 PM, Thomas Petazzoni
<thomas.petazzoni@free-electrons.com> wrote:
> Hello,
>
> On Wed, 1 Feb 2017 08:18:53 -0500, Adam Duskett wrote:
>> gstreamer-vaapi consists in a collection of VA-API based plugins for
>> GStreamer and helper libraries. These libraries are used for hardware
>> decoding and encoding of several video formats.
>>
>> decoding formats:
>> JPEG, MPEG-2, MPEG-4:2, H.264 AVC, H.264 MVC, VP8, VC-1, WMV3, and HEVC.
>>
>> encoding formats:
>> MPEG-2, H.264 AVC, H.264 MVC, JPEG, VP8, HEVC
>>
>> The package won't compile without at least one renderer enabled, so I
>> chose to enable DRM by default, as X11, GLX, and wayland are heavy
>> handed with the dependencies. As such, I have disabled every option
>> defaulting to yes except for DRM for the first patch.
>>
>> Also, these codecs are only for x86 and require a Intel CPU (See Hardware
>> Requirements on line 82 of the README file.)
>>
>> Signed-off-by: Adam Duskett <Adamduskett@outlook.com>
>
> We already had a patch pending in patchwork adding the same package,
> proposed by Jesper Baekdahl. Could you please sync with Jesper to
> propose a single patch?
>
Hey Thomas!
I sent an email out just a few minutes ago. Hopefully, he responds soon!
Question: What is the established procedure if somebody doesn't respond?
>
>
> Thanks,
>
> Thomas
> --
> Thomas Petazzoni, CTO, Free Electrons
> Embedded Linux and Kernel engineering
> http://free-electrons.com
Thanks!
Adam
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Buildroot] [PATCH 1/2] gst1-vaapi: new package.
2017-02-03 13:08 ` Adam Duskett
@ 2017-02-07 14:07 ` Adam Duskett
0 siblings, 0 replies; 7+ messages in thread
From: Adam Duskett @ 2017-02-07 14:07 UTC (permalink / raw)
To: buildroot
Hello,
On Fri, Feb 3, 2017 at 8:08 AM, Adam Duskett <aduskett@gmail.com> wrote:
> On Wed, Feb 1, 2017 at 4:30 PM, Thomas Petazzoni
> <thomas.petazzoni@free-electrons.com> wrote:
>> Hello,
>>
>> On Wed, 1 Feb 2017 08:18:53 -0500, Adam Duskett wrote:
>>> gstreamer-vaapi consists in a collection of VA-API based plugins for
>>> GStreamer and helper libraries. These libraries are used for hardware
>>> decoding and encoding of several video formats.
>>>
>>> decoding formats:
>>> JPEG, MPEG-2, MPEG-4:2, H.264 AVC, H.264 MVC, VP8, VC-1, WMV3, and HEVC.
>>>
>>> encoding formats:
>>> MPEG-2, H.264 AVC, H.264 MVC, JPEG, VP8, HEVC
>>>
>>> The package won't compile without at least one renderer enabled, so I
>>> chose to enable DRM by default, as X11, GLX, and wayland are heavy
>>> handed with the dependencies. As such, I have disabled every option
>>> defaulting to yes except for DRM for the first patch.
>>>
>>> Also, these codecs are only for x86 and require a Intel CPU (See Hardware
>>> Requirements on line 82 of the README file.)
>>>
>>> Signed-off-by: Adam Duskett <Adamduskett@outlook.com>
>>
>> We already had a patch pending in patchwork adding the same package,
>> proposed by Jesper Baekdahl. Could you please sync with Jesper to
>> propose a single patch?
>>
> Hey Thomas!
>
> I sent an email out just a few minutes ago. Hopefully, he responds soon!
>
> Question: What is the established procedure if somebody doesn't respond?
>
>
>>
>>
>> Thanks,
>>
>> Thomas
>> --
>> Thomas Petazzoni, CTO, Free Electrons
>> Embedded Linux and Kernel engineering
>> http://free-electrons.com
>
> Thanks!
>
> Adam
I just got word from Jesper; he is fine with my patch.
"Hi Adam,
Sorry for the late answer. You can take over the patch.
Best Regards,
Jesper B?kdahl
Hardware/Software Developer
Gamblify"
So if you find this patch acceptable it looks like he is fine with it!
Adam
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Buildroot] [PATCH 1/2] gst1-vaapi: new package.
2017-02-01 13:18 [Buildroot] [PATCH 1/2] gst1-vaapi: new package Adam Duskett
2017-02-01 13:18 ` [Buildroot] [PATCH 2/2] gst1-vaapi: add optional encoder support Adam Duskett
2017-02-01 21:30 ` [Buildroot] [PATCH 1/2] gst1-vaapi: new package Thomas Petazzoni
@ 2017-03-12 20:52 ` Thomas Petazzoni
2 siblings, 0 replies; 7+ messages in thread
From: Thomas Petazzoni @ 2017-03-12 20:52 UTC (permalink / raw)
To: buildroot
Hello,
On Wed, 1 Feb 2017 08:18:53 -0500, Adam Duskett wrote:
> gstreamer-vaapi consists in a collection of VA-API based plugins for
> GStreamer and helper libraries. These libraries are used for hardware
> decoding and encoding of several video formats.
>
> decoding formats:
> JPEG, MPEG-2, MPEG-4:2, H.264 AVC, H.264 MVC, VP8, VC-1, WMV3, and HEVC.
>
> encoding formats:
> MPEG-2, H.264 AVC, H.264 MVC, JPEG, VP8, HEVC
>
> The package won't compile without at least one renderer enabled, so I
> chose to enable DRM by default, as X11, GLX, and wayland are heavy
> handed with the dependencies. As such, I have disabled every option
> defaulting to yes except for DRM for the first patch.
>
> Also, these codecs are only for x86 and require a Intel CPU (See Hardware
> Requirements on line 82 of the README file.)
>
> Signed-off-by: Adam Duskett <Adamduskett@outlook.com>
I've applied your patch, but after doing a number of fixes. The most
important one is that your package was not building with the uClibc C
library. uClibc is our default C library, so developers should *always*
build test their packages with this C library before submitting patches.
So, next time, please the test-pkg script to build test your package
properly. Submitting something that doesn't even build with Buildroot
default configuration is not nice at all.
> diff --git a/package/gstreamer1/gst1-vaapi/Config.in b/package/gstreamer1/gst1-vaapi/Config.in
> new file mode 100644
> index 0000000..44461e3
> --- /dev/null
> +++ b/package/gstreamer1/gst1-vaapi/Config.in
> @@ -0,0 +1,39 @@
> +config BR2_PACKAGE_GST1_VAAPI
> + bool "gst1-vaapi"
> + select BR2_PACKAGE_LIBVA
> + select BR2_PACKAGE_LIBDRM
> + select BR2_PACKAGE_GST1_PLUGINS_BASE
> + select BR2_PACKAGE_GST1_PLUGINS_BAD # gstreamer-codecparsers
Your Config.in comment mentioned the udev and thread dependency, but
I don't see them anywhere here... so I've added them.
> + depends on BR2_i386 || BR2_x86_64 # Only relevant for x86
I don't really see why in fact. I've seen the README file, but I don't
quite understand VA-API is a generic API, it can be used on other
platforms than x86. And it builds fine on ARM, so for now, I've removed
this.
> +comment "gst1-vaapi needs udev /dev management and a toolchain w/ threads, dynamic library"
> + depends on BR2_i386 || BR2_x86_64
And removed this line.
> + depends on !BR2_TOOLCHAIN_HAS_THREADS || BR2_STATIC_LIBS || \
> + !BR2_PACKAGE_HAS_UDEV
This last line should have been intended with one more tab.
Also, you missed adding yourself to the DEVELOPERS file, so I've done
that as well. Finally, there were some trailing tabs, and spaces
instead of tabs in the Config.in file.
All in all, the list of changes:
[Thomas:
- Add entry to DEVELOPERS file.
- Add BR2_TOOLCHAIN_HAS_THREADS dependency to the main Config.in
option.
- Add BR2_PACKAGE_HAS_UDEV dependency to the main Config.in option.
- Add comments about the BR2_STATIC_LIBS config option.
- Rewrap Config.in help text and removing trailing tabs/spaces.
- Remove restriction to i386/x86-64
- Add patch to fix build with uClibc.]
Thanks,
Thomas
--
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2017-03-12 20:52 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-02-01 13:18 [Buildroot] [PATCH 1/2] gst1-vaapi: new package Adam Duskett
2017-02-01 13:18 ` [Buildroot] [PATCH 2/2] gst1-vaapi: add optional encoder support Adam Duskett
2017-03-12 20:52 ` Thomas Petazzoni
2017-02-01 21:30 ` [Buildroot] [PATCH 1/2] gst1-vaapi: new package Thomas Petazzoni
2017-02-03 13:08 ` Adam Duskett
2017-02-07 14:07 ` Adam Duskett
2017-03-12 20:52 ` Thomas Petazzoni
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox