feat(hardware): enable hardware transcoding support

This commit is contained in:
Khaïs COLIN 2024-09-16 19:14:49 +02:00
parent 2b19dfc02b
commit d5c4cd1204
2 changed files with 24 additions and 1 deletions

View file

@ -1,4 +1,4 @@
{ pkgs, ... }: { pkgs, pkgs-unstable, ... }:
{ {
# Bootloader. # Bootloader.
boot.loader.systemd-boot.enable = true; boot.loader.systemd-boot.enable = true;
@ -221,6 +221,23 @@
dockerSocket.enable = true; dockerSocket.enable = true;
}; };
# enable VAAPI and intel QSV
# enable vaapi
nixpkgs.config.packageOverrides = pkgs: {
vaapiIntel = pkgs.vaapiIntel.override { enableHybridCodec = true; };
};
hardware.opengl = { # hardware.graphics in unstable
enable = true;
extraPackages = with pkgs; [
intel-media-driver
intel-vaapi-driver
vaapiVdpau
intel-compute-runtime
pkgs-unstable.vpl-gpu-rt
intel-media-sdk
];
};
# enable hardware acceleration for qemu # enable hardware acceleration for qemu
virtualisation.libvirtd.enable = true; virtualisation.libvirtd.enable = true;
programs.virt-manager.enable = true; programs.virt-manager.enable = true;

View file

@ -73,6 +73,9 @@
stylix.nixosModules.stylix stylix.nixosModules.stylix
./stylix.nix ./stylix.nix
]; ];
specialArgs = {
pkgs-unstable = nixpkgs-unstable.legacyPackages.${system};
};
}; };
nixosConfigurations.t470 = nixpkgs.lib.nixosSystem { nixosConfigurations.t470 = nixpkgs.lib.nixosSystem {
inherit system; inherit system;
@ -94,6 +97,9 @@
nixos-06cb-009a-fingerprint-sensor.nixosModules.open-fprintd nixos-06cb-009a-fingerprint-sensor.nixosModules.open-fprintd
nixos-06cb-009a-fingerprint-sensor.nixosModules.python-validity nixos-06cb-009a-fingerprint-sensor.nixosModules.python-validity
]; ];
specialArgs = {
pkgs-unstable = nixpkgs-unstable.legacyPackages.${system};
};
}; };
}; };
} }