Intel Graphics: Difference between revisions

From NixOS Wiki
imported>Primeos
m Iris is the default on nixos-unstable (since Mesa 20.0)
imported>Primeos
Move the VA-API note into a dedicated section
Line 1: Line 1:
== Video acceleration ==
To enable hardware (GPU) accelerated video decoding and encoding you need to add additional entries in <code>hardware.opengl.extraPackages</code> (see [[Accelerated_Video_Playback|"accelerated video playback"]]).
== Iris ==
== Iris ==


Line 13: Line 17:
   };
   };
</syntaxHighlight>
</syntaxHighlight>
Note that you might want additional entries in <code>extraPackages</code>, for example, to enable [[Accelerated_Video_Playback|"accelerated video playback"]].


(See [https://github.com/NixOS/nixpkgs/pull/65017 this GitHub thread] for context and explanation. <code>nouveau</code> is included to trigger the gallium-xa build, which is currently required because the nix derivation expects to copy the gallium-xa pkg-config files into place. Without <code>swrast</code> and/or <code>virgl</code>, it complains about needing softpipe/llvmpipe to build the <code>nine state tracker</code>.)
(See [https://github.com/NixOS/nixpkgs/pull/65017 this GitHub thread] for context and explanation. <code>nouveau</code> is included to trigger the gallium-xa build, which is currently required because the nix derivation expects to copy the gallium-xa pkg-config files into place. Without <code>swrast</code> and/or <code>virgl</code>, it complains about needing softpipe/llvmpipe to build the <code>nine state tracker</code>.)

Revision as of 09:44, 6 August 2020

Video acceleration

To enable hardware (GPU) accelerated video decoding and encoding you need to add additional entries in hardware.opengl.extraPackages (see "accelerated video playback").

Iris

On nixos-unstable the new Gallium iris driver is enabled by default. For nixos-20.03 you can use the following in your system configuration:

  config = {
    environment.variables = {
      MESA_LOADER_DRIVER_OVERRIDE = "iris";
    };
    hardware.opengl.package = (pkgs.mesa.override {
      galliumDrivers = [ "nouveau" "virgl" "swrast" "iris" ];
    }).drivers;
  };

(See this GitHub thread for context and explanation. nouveau is included to trigger the gallium-xa build, which is currently required because the nix derivation expects to copy the gallium-xa pkg-config files into place. Without swrast and/or virgl, it complains about needing softpipe/llvmpipe to build the nine state tracker.)