all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* [bug#36814] [PATCH 0/2] Add VA-API Intel back-end and utilities
@ 2019-07-26  3:27 Tobias Geerinckx-Rice via Guix-patches
  2019-07-26  3:30 ` [bug#36814] [PATCH 1/2] gnu: Add intel-vaapi-driver Tobias Geerinckx-Rice via Guix-patches
                   ` (3 more replies)
  0 siblings, 4 replies; 16+ messages in thread
From: Tobias Geerinckx-Rice via Guix-patches @ 2019-07-26  3:27 UTC (permalink / raw)
  To: 36814

[-- Attachment #1: Type: text/plain, Size: 1030 bytes --]

Guix,

The following patches add the VA-API back end for Intel GEN chips 
as well as libva-utils (which provides vainfo amongst many other 
things).  I've tested them on my Ivy Bridge laptop and they work 
wonderfully.

However.

libva (I guess) searches for the back end in mesa's store output 
by default:

--8<---------------cut here---------------start------------->8---
vainfo 
libva info: VA-API version 1.4.1
libva info: va_getDriverName() returns 0
libva info: Trying to open 
/gnu/store/clhrbkacyrclwzkzdj2ql8y572whwjzi-mesa-19.1.1/lib/dri/i965_drv_video.so
libva info: va_openDriver() returns -1
vaInitialize failed with error code -1 (unknown libva error),exit
--8<---------------cut here---------------end--------------->8---

I don't know enough about libva or mesa to know how all this can 
be made to compose nicely.

I just tested and enjoyed VA-API acceleration by (icky icky boo 
boo) copying intel-vaapi-driver's library to the mesa store 
directory, so I need help in more ways than one.

Kind regards,

T G-R

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 227 bytes --]

^ permalink raw reply	[flat|nested] 16+ messages in thread

* [bug#36814] [PATCH 1/2] gnu: Add intel-vaapi-driver.
  2019-07-26  3:27 [bug#36814] [PATCH 0/2] Add VA-API Intel back-end and utilities Tobias Geerinckx-Rice via Guix-patches
@ 2019-07-26  3:30 ` Tobias Geerinckx-Rice via Guix-patches
  2019-07-26  3:30   ` [bug#36814] [PATCH 2/2] gnu: Add libva-utils Tobias Geerinckx-Rice via Guix-patches
  2019-07-27 18:35   ` [bug#36814] [PATCH 1/2] gnu: Add intel-vaapi-driver Marius Bakke
  2019-07-26  8:17 ` [bug#36814] [PATCH 0/2] Add VA-API Intel back-end and utilities Tobias Geerinckx-Rice via Guix-patches
                   ` (2 subsequent siblings)
  3 siblings, 2 replies; 16+ messages in thread
From: Tobias Geerinckx-Rice via Guix-patches @ 2019-07-26  3:30 UTC (permalink / raw)
  To: 36814

* gnu/packages/video.scm (intel-vaapi-driver): New public variable.
---
 gnu/packages/video.scm | 38 ++++++++++++++++++++++++++++++++++++++
 1 file changed, 38 insertions(+)

diff --git a/gnu/packages/video.scm b/gnu/packages/video.scm
index 4b9e05edfe..f068c5df65 100644
--- a/gnu/packages/video.scm
+++ b/gnu/packages/video.scm
@@ -2695,6 +2695,44 @@ of modern, widely supported codecs.")
     ;; Combination under GPLv2.  See LICENSE.
     (license license:gpl2)))
 
+(define-public intel-vaapi-driver
+  (package
+    (name "intel-vaapi-driver")
+    (version "2.3.0")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (string-append "https://github.com/intel/intel-vaapi-driver/"
+                           "releases/download/" version "/intel-vaapi-driver-"
+                           version ".tar.bz2"))
+       (sha256
+        (base32 "1qyzxh3p8cw4fv8bz9zd4kc8hajlaps7xryzh6pad814n3m5sbjw"))))
+    (build-system gnu-build-system)
+    (native-inputs
+     `(("pkg-config" ,pkg-config)))
+    (inputs
+     `(("libdrm" ,libdrm)
+       ("libva" ,libva)
+       ("libx11" ,libx11)))
+    (arguments
+     `(#:phases
+       (modify-phases %standard-phases
+         (add-before 'configure 'set-up-directories
+           (lambda* (#:key outputs #:allow-other-keys)
+             (let ((out (assoc-ref outputs "out")))
+               (setenv "LIBVA_DRIVERS_PATH" (string-append out "/lib/dri"))
+               #t))))))
+    (home-page "https://01.org/linuxmedia/vaapi")
+    (synopsis "VA-API video acceleration driver for Intel GEN Graphics devices")
+    (description
+     "This is the @acronym{VA-API, Video Acceleration API} back end required for
+for hardware-accelerated video processing on Intel GEN Graphics devices
+supported by the i915 driver, such as integrated Intel HD Graphics.  It provides
+access to both hardware and shader functionality for faster encoding, decoding,
+and post-processing video formats like MPEG2, H.264/AVC, and VC-1.")
+    (license (list license:bsd-2        ; src/gen9_vp9_const_def.c
+                   license:expat))))    ; the rest, excluding the test suite
+
 (define-public openh264
   (package
     (name "openh264")
-- 
2.22.0

^ permalink raw reply related	[flat|nested] 16+ messages in thread

* [bug#36814] [PATCH 2/2] gnu: Add libva-utils.
  2019-07-26  3:30 ` [bug#36814] [PATCH 1/2] gnu: Add intel-vaapi-driver Tobias Geerinckx-Rice via Guix-patches
@ 2019-07-26  3:30   ` Tobias Geerinckx-Rice via Guix-patches
  2019-07-27 18:37     ` Marius Bakke
  2019-07-27 18:35   ` [bug#36814] [PATCH 1/2] gnu: Add intel-vaapi-driver Marius Bakke
  1 sibling, 1 reply; 16+ messages in thread
From: Tobias Geerinckx-Rice via Guix-patches @ 2019-07-26  3:30 UTC (permalink / raw)
  To: 36814

* gnu/packages/video.scm (libva-utils): New public variable.
---
 gnu/packages/video.scm | 34 ++++++++++++++++++++++++++++++++++
 1 file changed, 34 insertions(+)

diff --git a/gnu/packages/video.scm b/gnu/packages/video.scm
index f068c5df65..e16dd13765 100644
--- a/gnu/packages/video.scm
+++ b/gnu/packages/video.scm
@@ -753,6 +753,40 @@ entry-points (VLD, IDCT, Motion Compensation etc.) for prevailing coding
 standards (MPEG-2, MPEG-4 ASP/H.263, MPEG-4 AVC/H.264, and VC-1/VMW3).")
     (license license:expat)))
 
+(define-public libva-utils
+  (package
+    (name "libva-utils")
+    (version "2.5.0")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (string-append "https://github.com/intel/libva-utils/releases/download/"
+                           version "/libva-utils-" version ".tar.bz2"))
+       (sha256
+        (base32 "05rasyqnsg522zqxak1q8rrm1hys7wwbi41kd0szjq0d27awjf4j"))))
+    (build-system gnu-build-system)
+    (arguments
+     `(#:configure-flags
+       (list "--enable-wayland"
+             "--enable-x11")))
+    (native-inputs
+     `(("pkg-config" ,pkg-config)))
+    (inputs
+     `(("libdrm" ,libdrm)
+       ("libva" ,libva)
+       ("libx11" ,libx11)
+       ("mesa" ,mesa)
+       ("wayland" ,wayland)))
+    (home-page "https://01.org/linuxmedia/vaapi")
+    (synopsis "Collection of testing utilities for VA-API")
+    (description
+     "This is a collection of utilities and examples to query and test the
+@acronym{VA-API, Video Acceleration API} implemented by the libva library.
+
+These tools require a supported graphics chip, driver, and VA-API back end to
+operate properly.")
+    (license license:expat)))
+
 (define-public ffmpeg
   (package
     (name "ffmpeg")
-- 
2.22.0

^ permalink raw reply related	[flat|nested] 16+ messages in thread

* [bug#36814] [PATCH 0/2] Add VA-API Intel back-end and utilities
  2019-07-26  3:27 [bug#36814] [PATCH 0/2] Add VA-API Intel back-end and utilities Tobias Geerinckx-Rice via Guix-patches
  2019-07-26  3:30 ` [bug#36814] [PATCH 1/2] gnu: Add intel-vaapi-driver Tobias Geerinckx-Rice via Guix-patches
@ 2019-07-26  8:17 ` Tobias Geerinckx-Rice via Guix-patches
  2019-07-26  8:56   ` Jelle Licht
  2019-07-26 18:40 ` [bug#36814] [BONUS PATCH 3/2] gnu: intel-vaapi-driver: Provide LIBVA_DRIVERS_PATH Tobias Geerinckx-Rice via Guix-patches
  2019-07-27 21:29 ` bug#36814: [PATCH 0/2] Add VA-API Intel back-end and utilities Tobias Geerinckx-Rice via Guix-patches
  3 siblings, 1 reply; 16+ messages in thread
From: Tobias Geerinckx-Rice via Guix-patches @ 2019-07-26  8:17 UTC (permalink / raw)
  To: 36814

[-- Attachment #1: Type: text/plain, Size: 331 bytes --]

Tobias Geerinckx-Rice via Guix-patches 写道:
> I don't know enough about libva or mesa to know how all this can 
> be
> made to compose nicely.

It's actually as simple as exporting 
LIBVA_DRIVERS_PATH="<intel-vaapi-driver>/lib/dri".

I guess making that a search-path for libva should work?

Kind regards,

T G-R

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 227 bytes --]

^ permalink raw reply	[flat|nested] 16+ messages in thread

* [bug#36814] [PATCH 0/2] Add VA-API Intel back-end and utilities
  2019-07-26  8:17 ` [bug#36814] [PATCH 0/2] Add VA-API Intel back-end and utilities Tobias Geerinckx-Rice via Guix-patches
@ 2019-07-26  8:56   ` Jelle Licht
  2019-07-26 17:58     ` Tobias Geerinckx-Rice via Guix-patches
  0 siblings, 1 reply; 16+ messages in thread
From: Jelle Licht @ 2019-07-26  8:56 UTC (permalink / raw)
  To: Tobias Geerinckx-Rice, 36814

Hey Tobias,

Tobias Geerinckx-Rice via Guix-patches <guix-patches@gnu.org> writes:

> Tobias Geerinckx-Rice via Guix-patches 写道:
>> I don't know enough about libva or mesa to know how all this can 
>> be
>> made to compose nicely.
>
> It's actually as simple as exporting 
> LIBVA_DRIVERS_PATH="<intel-vaapi-driver>/lib/dri".
A cursory check using the LIBVA_DRIVERS_PATH workaround on a youtube
video using mpv seems to indicate that your packages work wonderfully
(~16% cpu load normally -> ~5% cpu load with vaapi flags).

Thanks for working on this!
>
> I guess making that a search-path for libva should work?
I do not see why not.

>
> Kind regards,
>
> T G-R

^ permalink raw reply	[flat|nested] 16+ messages in thread

* [bug#36814] [PATCH 0/2] Add VA-API Intel back-end and utilities
  2019-07-26  8:56   ` Jelle Licht
@ 2019-07-26 17:58     ` Tobias Geerinckx-Rice via Guix-patches
  0 siblings, 0 replies; 16+ messages in thread
From: Tobias Geerinckx-Rice via Guix-patches @ 2019-07-26 17:58 UTC (permalink / raw)
  To: Jelle Licht; +Cc: 36814

[-- Attachment #1: Type: text/plain, Size: 721 bytes --]

Jelle,

Thank you for testing!

Jelle Licht 写道:
> A cursory check using the LIBVA_DRIVERS_PATH workaround on a 
> youtube
> video using mpv seems to indicate that your packages work 
> wonderfully
> (~16% cpu load normally -> ~5% cpu load with vaapi flags).

On my Intel Corporation 3rd Gen Core processor Graphics 
Controller, the results were even more exciting: from ~35% to ~7% 
CPU load while playing a 720p H.264 film.  That's a factor of 5.

Sadly, my hardware's too old to accelerate H.265 (HEVC) stream 
(they play just fine on the CPU), but even so: a significant 
majority of my media collection just got significantly 
accelerated…  for free!  \o/

I love this business,

T G-R

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 227 bytes --]

^ permalink raw reply	[flat|nested] 16+ messages in thread

* [bug#36814] [BONUS PATCH 3/2] gnu: intel-vaapi-driver: Provide LIBVA_DRIVERS_PATH.
  2019-07-26  3:27 [bug#36814] [PATCH 0/2] Add VA-API Intel back-end and utilities Tobias Geerinckx-Rice via Guix-patches
  2019-07-26  3:30 ` [bug#36814] [PATCH 1/2] gnu: Add intel-vaapi-driver Tobias Geerinckx-Rice via Guix-patches
  2019-07-26  8:17 ` [bug#36814] [PATCH 0/2] Add VA-API Intel back-end and utilities Tobias Geerinckx-Rice via Guix-patches
@ 2019-07-26 18:40 ` Tobias Geerinckx-Rice via Guix-patches
  2019-07-27 18:26   ` Marius Bakke
  2019-07-27 21:29 ` bug#36814: [PATCH 0/2] Add VA-API Intel back-end and utilities Tobias Geerinckx-Rice via Guix-patches
  3 siblings, 1 reply; 16+ messages in thread
From: Tobias Geerinckx-Rice via Guix-patches @ 2019-07-26 18:40 UTC (permalink / raw)
  To: 36814

* gnu/packages/video.scm (intel-vaapi-driver)[native-search-paths]:
Export LIBVA_DRIVERS_PATH when installed.
(libva-without-mesa)[native-search-paths]: Don't inherit any.
---

Guix,

This ties the two together.

I'm leaving the enormocomment in so I don't have to repeat it here, but I'm less sure about it now than when I wrote it.  I thought this was a filthy hack, but maybe it's just mildly unconventional ;-)  The documentation is very sparse indeed.

I don't see any acceptable alternative.

Stormy regards,

T G-R

 gnu/packages/gl.scm    |  3 ++-
 gnu/packages/video.scm | 13 +++++++++++++
 2 files changed, 15 insertions(+), 1 deletion(-)

diff --git a/gnu/packages/gl.scm b/gnu/packages/gl.scm
index 9ed043c7ae..9495e8ee24 100644
--- a/gnu/packages/gl.scm
+++ b/gnu/packages/gl.scm
@@ -219,7 +219,8 @@ also known as DXTn or DXTC) for Mesa.")
         '(#:make-flags)
         (substitute-keyword-arguments (package-arguments libva)
           ((#:configure-flags flags)
-           '(list "--disable-glx" "--disable-egl"))))))))
+           '(list "--disable-glx" "--disable-egl")))))
+      (native-search-paths '()))))
 
 (define-public mesa
   (package
diff --git a/gnu/packages/video.scm b/gnu/packages/video.scm
index b441c5e311..5e26b4c2dc 100644
--- a/gnu/packages/video.scm
+++ b/gnu/packages/video.scm
@@ -2756,6 +2756,19 @@ of modern, widely supported codecs.")
              (let ((out (assoc-ref outputs "out")))
                (setenv "LIBVA_DRIVERS_PATH" (string-append out "/lib/dri"))
                #t))))))
+    ;; XXX This variable is actually respected by libva, and in a perfect world
+    ;; would be found there instead.  Unfortunately, native-search-paths are set
+    ;; up only if the package using them is installed directly into the profile.
+    ;; This means that users would need to install libva into their profile for
+    ;; no good reason other than convincing Guix to export the right paths, or
+    ;; that every single one of libva's many dependents would would need to be
+    ;; modified instead (and would still be semantically dubious).  Moving it
+    ;; here is logically (almost) equivalent, and keeps this hack confined to a
+    ;; tiny handful of back-end packages.
+    (native-search-paths
+     (list (search-path-specification
+            (variable "LIBVA_DRIVERS_PATH")
+            (files '("lib/dri")))))
     (home-page "https://01.org/linuxmedia/vaapi")
     (synopsis "VA-API video acceleration driver for Intel GEN Graphics devices")
     (description
-- 
2.22.0

^ permalink raw reply related	[flat|nested] 16+ messages in thread

* [bug#36814] [BONUS PATCH 3/2] gnu: intel-vaapi-driver: Provide LIBVA_DRIVERS_PATH.
  2019-07-26 18:40 ` [bug#36814] [BONUS PATCH 3/2] gnu: intel-vaapi-driver: Provide LIBVA_DRIVERS_PATH Tobias Geerinckx-Rice via Guix-patches
@ 2019-07-27 18:26   ` Marius Bakke
  2019-07-27 18:50     ` Tobias Geerinckx-Rice via Guix-patches
  0 siblings, 1 reply; 16+ messages in thread
From: Marius Bakke @ 2019-07-27 18:26 UTC (permalink / raw)
  To: Tobias Geerinckx-Rice, 36814

[-- Attachment #1: Type: text/plain, Size: 773 bytes --]

Tobias Geerinckx-Rice via Guix-patches <guix-patches@gnu.org> writes:

> * gnu/packages/video.scm (intel-vaapi-driver)[native-search-paths]:
> Export LIBVA_DRIVERS_PATH when installed.

Can this be squashed into patch 1/2 in this series?

> (libva-without-mesa)[native-search-paths]: Don't inherit any.

...and this added in a separate patch, so that the intel-vaapi-driver
change does not have to go through 'staging'?

> I'm leaving the enormocomment in so I don't have to repeat it here, but I'm less sure about it now than when I wrote it.  I thought this was a filthy hack, but maybe it's just mildly unconventional ;-)  The documentation is very sparse indeed.

The comment could perhaps be shortened by including a link to
<https://issues.guix.gnu.org/issue/22138>.

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 487 bytes --]

^ permalink raw reply	[flat|nested] 16+ messages in thread

* [bug#36814] [PATCH 1/2] gnu: Add intel-vaapi-driver.
  2019-07-26  3:30 ` [bug#36814] [PATCH 1/2] gnu: Add intel-vaapi-driver Tobias Geerinckx-Rice via Guix-patches
  2019-07-26  3:30   ` [bug#36814] [PATCH 2/2] gnu: Add libva-utils Tobias Geerinckx-Rice via Guix-patches
@ 2019-07-27 18:35   ` Marius Bakke
  2019-07-27 19:00     ` Tobias Geerinckx-Rice via Guix-patches
  1 sibling, 1 reply; 16+ messages in thread
From: Marius Bakke @ 2019-07-27 18:35 UTC (permalink / raw)
  To: Tobias Geerinckx-Rice, 36814

[-- Attachment #1: Type: text/plain, Size: 2394 bytes --]

Tobias Geerinckx-Rice via Guix-patches <guix-patches@gnu.org> writes:

> * gnu/packages/video.scm (intel-vaapi-driver): New public variable.
> ---
>  gnu/packages/video.scm | 38 ++++++++++++++++++++++++++++++++++++++
>  1 file changed, 38 insertions(+)
>
> diff --git a/gnu/packages/video.scm b/gnu/packages/video.scm
> index 4b9e05edfe..f068c5df65 100644
> --- a/gnu/packages/video.scm
> +++ b/gnu/packages/video.scm
> @@ -2695,6 +2695,44 @@ of modern, widely supported codecs.")
>      ;; Combination under GPLv2.  See LICENSE.
>      (license license:gpl2)))
>  
> +(define-public intel-vaapi-driver
> +  (package
> +    (name "intel-vaapi-driver")
> +    (version "2.3.0")
> +    (source
> +     (origin
> +       (method url-fetch)
> +       (uri (string-append "https://github.com/intel/intel-vaapi-driver/"
> +                           "releases/download/" version "/intel-vaapi-driver-"
> +                           version ".tar.bz2"))
> +       (sha256
> +        (base32 "1qyzxh3p8cw4fv8bz9zd4kc8hajlaps7xryzh6pad814n3m5sbjw"))))
> +    (build-system gnu-build-system)
> +    (native-inputs
> +     `(("pkg-config" ,pkg-config)))
> +    (inputs
> +     `(("libdrm" ,libdrm)
> +       ("libva" ,libva)
> +       ("libx11" ,libx11)))
> +    (arguments
> +     `(#:phases
> +       (modify-phases %standard-phases
> +         (add-before 'configure 'set-up-directories
> +           (lambda* (#:key outputs #:allow-other-keys)
> +             (let ((out (assoc-ref outputs "out")))
> +               (setenv "LIBVA_DRIVERS_PATH" (string-append out "/lib/dri"))
> +               #t))))))

Can this be passed in #:configure-flags?  What does it do, anyway?  :-)

> +    (home-page "https://01.org/linuxmedia/vaapi")
> +    (synopsis "VA-API video acceleration driver for Intel GEN Graphics devices")
> +    (description
> +     "This is the @acronym{VA-API, Video Acceleration API} back end required for
> +for hardware-accelerated video processing on Intel GEN Graphics devices
> +supported by the i915 driver, such as integrated Intel HD Graphics.  It provides
> +access to both hardware and shader functionality for faster encoding, decoding,
> +and post-processing video formats like MPEG2, H.264/AVC, and VC-1.")

I suppose we should limit this driver to i686-linux and x86_64-linux only.

LGTM, looking forward to try it!

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 487 bytes --]

^ permalink raw reply	[flat|nested] 16+ messages in thread

* [bug#36814] [PATCH 2/2] gnu: Add libva-utils.
  2019-07-26  3:30   ` [bug#36814] [PATCH 2/2] gnu: Add libva-utils Tobias Geerinckx-Rice via Guix-patches
@ 2019-07-27 18:37     ` Marius Bakke
  0 siblings, 0 replies; 16+ messages in thread
From: Marius Bakke @ 2019-07-27 18:37 UTC (permalink / raw)
  To: Tobias Geerinckx-Rice, 36814

[-- Attachment #1: Type: text/plain, Size: 1895 bytes --]

Tobias Geerinckx-Rice via Guix-patches <guix-patches@gnu.org> writes:

> * gnu/packages/video.scm (libva-utils): New public variable.
> ---
>  gnu/packages/video.scm | 34 ++++++++++++++++++++++++++++++++++
>  1 file changed, 34 insertions(+)
>
> diff --git a/gnu/packages/video.scm b/gnu/packages/video.scm
> index f068c5df65..e16dd13765 100644
> --- a/gnu/packages/video.scm
> +++ b/gnu/packages/video.scm
> @@ -753,6 +753,40 @@ entry-points (VLD, IDCT, Motion Compensation etc.) for prevailing coding
>  standards (MPEG-2, MPEG-4 ASP/H.263, MPEG-4 AVC/H.264, and VC-1/VMW3).")
>      (license license:expat)))
>  
> +(define-public libva-utils
> +  (package
> +    (name "libva-utils")
> +    (version "2.5.0")
> +    (source
> +     (origin
> +       (method url-fetch)
> +       (uri (string-append "https://github.com/intel/libva-utils/releases/download/"
> +                           version "/libva-utils-" version ".tar.bz2"))
> +       (sha256
> +        (base32 "05rasyqnsg522zqxak1q8rrm1hys7wwbi41kd0szjq0d27awjf4j"))))
> +    (build-system gnu-build-system)
> +    (arguments
> +     `(#:configure-flags
> +       (list "--enable-wayland"
> +             "--enable-x11")))
> +    (native-inputs
> +     `(("pkg-config" ,pkg-config)))
> +    (inputs
> +     `(("libdrm" ,libdrm)
> +       ("libva" ,libva)
> +       ("libx11" ,libx11)
> +       ("mesa" ,mesa)
> +       ("wayland" ,wayland)))
> +    (home-page "https://01.org/linuxmedia/vaapi")
> +    (synopsis "Collection of testing utilities for VA-API")
> +    (description
> +     "This is a collection of utilities and examples to query and test the
> +@acronym{VA-API, Video Acceleration API} implemented by the libva library.
> +
> +These tools require a supported graphics chip, driver, and VA-API back end to
> +operate properly.")
> +    (license license:expat)))

LGTM.

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 487 bytes --]

^ permalink raw reply	[flat|nested] 16+ messages in thread

* [bug#36814] [BONUS PATCH 3/2] gnu: intel-vaapi-driver: Provide LIBVA_DRIVERS_PATH.
  2019-07-27 18:26   ` Marius Bakke
@ 2019-07-27 18:50     ` Tobias Geerinckx-Rice via Guix-patches
  2019-07-27 19:08       ` Tobias Geerinckx-Rice via Guix-patches
  2019-07-27 19:13       ` Marius Bakke
  0 siblings, 2 replies; 16+ messages in thread
From: Tobias Geerinckx-Rice via Guix-patches @ 2019-07-27 18:50 UTC (permalink / raw)
  To: Marius Bakke; +Cc: 36814

[-- Attachment #1: Type: text/plain, Size: 1300 bytes --]

Marius Bakke 写道:
> Tobias Geerinckx-Rice via Guix-patches <guix-patches@gnu.org> 
> writes:
>
>> * gnu/packages/video.scm 
>> (intel-vaapi-driver)[native-search-paths]:
>> Export LIBVA_DRIVERS_PATH when installed.
>
> Can this be squashed into patch 1/2 in this series?

Sure.  I wasn't really going to merge this as FREE BONUS PATCH, 
don't worry.

>> (libva-without-mesa)[native-search-paths]: Don't inherit any.
>
> ..and this added in a separate patch, so that the 
> intel-vaapi-driver
> change does not have to go through 'staging'?

Are you sure?  This hunk is here to keep the mesa derivation 
unchanged.  Removing (or delaying) it *will* cause all of mesa's 
1436 dependents to be rebuilt.  I don't think we want that.

>> I'm leaving the enormocomment in so I don't have to repeat it 
>> here, but I'm less sure about it now than when I wrote it.  I 
>> thought this was a filthy hack, but maybe it's just mildly 
>> unconventional ;-)  The documentation is very sparse indeed.
>
> The comment could perhaps be shortened by including a link to
> <https://issues.guix.gnu.org/issue/22138>.

Oh thank gods yes.  I missed that bug.  I'm glad this is 
considered important.  For now, this workaround + a link seems 
acceptable to me.

Thanks!

T G-R

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 227 bytes --]

^ permalink raw reply	[flat|nested] 16+ messages in thread

* [bug#36814] [PATCH 1/2] gnu: Add intel-vaapi-driver.
  2019-07-27 18:35   ` [bug#36814] [PATCH 1/2] gnu: Add intel-vaapi-driver Marius Bakke
@ 2019-07-27 19:00     ` Tobias Geerinckx-Rice via Guix-patches
  0 siblings, 0 replies; 16+ messages in thread
From: Tobias Geerinckx-Rice via Guix-patches @ 2019-07-27 19:00 UTC (permalink / raw)
  To: Marius Bakke; +Cc: 36814

[-- Attachment #1: Type: text/plain, Size: 2612 bytes --]

Marius,

Marius Bakke 写道:
> Tobias Geerinckx-Rice via Guix-patches <guix-patches@gnu.org> 
> writes:
>
>> * gnu/packages/video.scm (intel-vaapi-driver): New public 
>> variable.
>> ---
>>  gnu/packages/video.scm | 38 
>>  ++++++++++++++++++++++++++++++++++++++
>>  1 file changed, 38 insertions(+)
>>
>> diff --git a/gnu/packages/video.scm b/gnu/packages/video.scm
>> index 4b9e05edfe..f068c5df65 100644
>> --- a/gnu/packages/video.scm
>> +++ b/gnu/packages/video.scm
>> @@ -2695,6 +2695,44 @@ of modern, widely supported codecs.")
>>      ;; Combination under GPLv2.  See LICENSE.
>>      (license license:gpl2)))
>>  
>> +(define-public intel-vaapi-driver
>> +  (package
>> +    (name "intel-vaapi-driver")
>> +    (version "2.3.0")
>> +    (source
>> +     (origin
>> +       (method url-fetch)
>> +       (uri (string-append 
>> "https://github.com/intel/intel-vaapi-driver/"
>> +                           "releases/download/" version 
>> "/intel-vaapi-driver-"
>> +                           version ".tar.bz2"))
>> +       (sha256
>> +        (base32 
>> "1qyzxh3p8cw4fv8bz9zd4kc8hajlaps7xryzh6pad814n3m5sbjw"))))
>> +    (build-system gnu-build-system)
>> +    (native-inputs
>> +     `(("pkg-config" ,pkg-config)))
>> +    (inputs
>> +     `(("libdrm" ,libdrm)
>> +       ("libva" ,libva)
>> +       ("libx11" ,libx11)))
>> +    (arguments
>> +     `(#:phases
>> +       (modify-phases %standard-phases
>> +         (add-before 'configure 'set-up-directories
>> +           (lambda* (#:key outputs #:allow-other-keys)
>> +             (let ((out (assoc-ref outputs "out")))
>> +               (setenv "LIBVA_DRIVERS_PATH" (string-append out 
>> "/lib/dri"))
>> +               #t))))))
>
> Can this be passed in #:configure-flags?  What does it do, 
> anyway?  :-)
>
>> +    (home-page "https://01.org/linuxmedia/vaapi")
>> +    (synopsis "VA-API video acceleration driver for Intel GEN 
>> Graphics devices")
>> +    (description
>> +     "This is the @acronym{VA-API, Video Acceleration API} 
>> back end required for
>> +for hardware-accelerated video processing on Intel GEN 
>> Graphics devices
>> +supported by the i915 driver, such as integrated Intel HD 
>> Graphics.  It provides
>> +access to both hardware and shader functionality for faster 
>> encoding, decoding,
>> +and post-processing video formats like MPEG2, H.264/AVC, and 
>> VC-1.")
>
> I suppose we should limit this driver to i686-linux and 
> x86_64-linux only.

That is a very good point.

> LGTM, looking forward to try it!

Thanks!

T G-R

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 227 bytes --]

^ permalink raw reply	[flat|nested] 16+ messages in thread

* [bug#36814] [BONUS PATCH 3/2] gnu: intel-vaapi-driver: Provide LIBVA_DRIVERS_PATH.
  2019-07-27 18:50     ` Tobias Geerinckx-Rice via Guix-patches
@ 2019-07-27 19:08       ` Tobias Geerinckx-Rice via Guix-patches
  2019-07-27 19:16         ` Marius Bakke
  2019-07-27 19:13       ` Marius Bakke
  1 sibling, 1 reply; 16+ messages in thread
From: Tobias Geerinckx-Rice via Guix-patches @ 2019-07-27 19:08 UTC (permalink / raw)
  To: Marius Bakke, 36814

[-- Attachment #1: Type: text/plain, Size: 767 bytes --]

Tobias Geerinckx-Rice via Guix-patches 写道:
> Marius Bakke 写道:
>> Tobias Geerinckx-Rice via Guix-patches <guix-patches@gnu.org>
>> writes:
>>> (libva-without-mesa)[native-search-paths]: Don't inherit any.
>>
>> ..and this added in a separate patch, so that the 
>> intel-vaapi-driver
>> change does not have to go through 'staging'?
>
> Are you sure?  This hunk is here to keep the mesa derivation
> unchanged.  Removing (or delaying) it *will* cause all of mesa's 
> 1436
> dependents to be rebuilt.  I don't think we want that.

Actually, we're both wrong.  Yay!

This is a forgotten left-over from when the native-search-paths 
were in libva.  Now that they're not, it's useless & should just 
be dropped.

Right.  Right?

T G-R

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 227 bytes --]

^ permalink raw reply	[flat|nested] 16+ messages in thread

* [bug#36814] [BONUS PATCH 3/2] gnu: intel-vaapi-driver: Provide LIBVA_DRIVERS_PATH.
  2019-07-27 18:50     ` Tobias Geerinckx-Rice via Guix-patches
  2019-07-27 19:08       ` Tobias Geerinckx-Rice via Guix-patches
@ 2019-07-27 19:13       ` Marius Bakke
  1 sibling, 0 replies; 16+ messages in thread
From: Marius Bakke @ 2019-07-27 19:13 UTC (permalink / raw)
  To: Tobias Geerinckx-Rice; +Cc: 36814

[-- Attachment #1: Type: text/plain, Size: 1165 bytes --]

Tobias Geerinckx-Rice <me@tobias.gr> writes:

> Marius Bakke 写道:
>> Tobias Geerinckx-Rice via Guix-patches <guix-patches@gnu.org> 
>> writes:
>>
>>> * gnu/packages/video.scm 
>>> (intel-vaapi-driver)[native-search-paths]:
>>> Export LIBVA_DRIVERS_PATH when installed.
>>
>> Can this be squashed into patch 1/2 in this series?
>
> Sure.  I wasn't really going to merge this as FREE BONUS PATCH, 
> don't worry.
>
>>> (libva-without-mesa)[native-search-paths]: Don't inherit any.
>>
>> ..and this added in a separate patch, so that the 
>> intel-vaapi-driver
>> change does not have to go through 'staging'?
>
> Are you sure?  This hunk is here to keep the mesa derivation 
> unchanged.  Removing (or delaying) it *will* cause all of mesa's 
> 1436 dependents to be rebuilt.  I don't think we want that.

I don't see 'libva' being changed anywhere in this series?  The search
path is added for intel-vaapi-driver only, no?

But then, it's 32 degrees here in Trondheim and I just returned from a
hike, so I have probably missed something.

Leaving libva-without-mesa unchanged was my intent too, so I think we
are all good.  :-)

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 487 bytes --]

^ permalink raw reply	[flat|nested] 16+ messages in thread

* [bug#36814] [BONUS PATCH 3/2] gnu: intel-vaapi-driver: Provide LIBVA_DRIVERS_PATH.
  2019-07-27 19:08       ` Tobias Geerinckx-Rice via Guix-patches
@ 2019-07-27 19:16         ` Marius Bakke
  0 siblings, 0 replies; 16+ messages in thread
From: Marius Bakke @ 2019-07-27 19:16 UTC (permalink / raw)
  To: Tobias Geerinckx-Rice, 36814

[-- Attachment #1: Type: text/plain, Size: 905 bytes --]

Tobias Geerinckx-Rice <me@tobias.gr> writes:

> Tobias Geerinckx-Rice via Guix-patches 写道:
>> Marius Bakke 写道:
>>> Tobias Geerinckx-Rice via Guix-patches <guix-patches@gnu.org>
>>> writes:
>>>> (libva-without-mesa)[native-search-paths]: Don't inherit any.
>>>
>>> ..and this added in a separate patch, so that the 
>>> intel-vaapi-driver
>>> change does not have to go through 'staging'?
>>
>> Are you sure?  This hunk is here to keep the mesa derivation
>> unchanged.  Removing (or delaying) it *will* cause all of mesa's 
>> 1436
>> dependents to be rebuilt.  I don't think we want that.
>
> Actually, we're both wrong.  Yay!
>
> This is a forgotten left-over from when the native-search-paths 
> were in libva.  Now that they're not, it's useless & should just 
> be dropped.
>
> Right.  Right?

Right!  LGTM, thanks!

(...please disregard the other message...)

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 487 bytes --]

^ permalink raw reply	[flat|nested] 16+ messages in thread

* bug#36814: [PATCH 0/2] Add VA-API Intel back-end and utilities
  2019-07-26  3:27 [bug#36814] [PATCH 0/2] Add VA-API Intel back-end and utilities Tobias Geerinckx-Rice via Guix-patches
                   ` (2 preceding siblings ...)
  2019-07-26 18:40 ` [bug#36814] [BONUS PATCH 3/2] gnu: intel-vaapi-driver: Provide LIBVA_DRIVERS_PATH Tobias Geerinckx-Rice via Guix-patches
@ 2019-07-27 21:29 ` Tobias Geerinckx-Rice via Guix-patches
  3 siblings, 0 replies; 16+ messages in thread
From: Tobias Geerinckx-Rice via Guix-patches @ 2019-07-27 21:29 UTC (permalink / raw)
  To: 36814-done

[-- Attachment #1: Type: text/plain, Size: 312 bytes --]

Tobias Geerinckx-Rice via Guix-patches 写道:
> Guix,
>
> The following patches add the VA-API back end for Intel GEN 
> chips as
> well as libva-utils (which provides vainfo amongst many other 
> things).

Pushed atop master as 3563220e1e46b8a1b9af1e3a4c6cb3f9560c2460 &c.

Kind regards,

T G-R

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 227 bytes --]

^ permalink raw reply	[flat|nested] 16+ messages in thread

end of thread, other threads:[~2019-07-27 21:30 UTC | newest]

Thread overview: 16+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-07-26  3:27 [bug#36814] [PATCH 0/2] Add VA-API Intel back-end and utilities Tobias Geerinckx-Rice via Guix-patches
2019-07-26  3:30 ` [bug#36814] [PATCH 1/2] gnu: Add intel-vaapi-driver Tobias Geerinckx-Rice via Guix-patches
2019-07-26  3:30   ` [bug#36814] [PATCH 2/2] gnu: Add libva-utils Tobias Geerinckx-Rice via Guix-patches
2019-07-27 18:37     ` Marius Bakke
2019-07-27 18:35   ` [bug#36814] [PATCH 1/2] gnu: Add intel-vaapi-driver Marius Bakke
2019-07-27 19:00     ` Tobias Geerinckx-Rice via Guix-patches
2019-07-26  8:17 ` [bug#36814] [PATCH 0/2] Add VA-API Intel back-end and utilities Tobias Geerinckx-Rice via Guix-patches
2019-07-26  8:56   ` Jelle Licht
2019-07-26 17:58     ` Tobias Geerinckx-Rice via Guix-patches
2019-07-26 18:40 ` [bug#36814] [BONUS PATCH 3/2] gnu: intel-vaapi-driver: Provide LIBVA_DRIVERS_PATH Tobias Geerinckx-Rice via Guix-patches
2019-07-27 18:26   ` Marius Bakke
2019-07-27 18:50     ` Tobias Geerinckx-Rice via Guix-patches
2019-07-27 19:08       ` Tobias Geerinckx-Rice via Guix-patches
2019-07-27 19:16         ` Marius Bakke
2019-07-27 19:13       ` Marius Bakke
2019-07-27 21:29 ` bug#36814: [PATCH 0/2] Add VA-API Intel back-end and utilities Tobias Geerinckx-Rice via Guix-patches

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/guix.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.