vdpau/vaapi
This commit is contained in:
@ -20,10 +20,9 @@ in {
|
|||||||
home.packages = with pkgs; builtins.concatLists [
|
home.packages = with pkgs; builtins.concatLists [
|
||||||
# TODO: I don't think vaapi works yet
|
# TODO: I don't think vaapi works yet
|
||||||
(optionals cfg.vaapi [
|
(optionals cfg.vaapi [
|
||||||
libva
|
# NOTE: I put these into hardware.opengl.extrapackages, don't know if they belong there...
|
||||||
libva-utils
|
# libva
|
||||||
# nvidia-vaapi-driver # Nvidia is gone :)
|
# libvdpau
|
||||||
vulkan-tools
|
|
||||||
])
|
])
|
||||||
|
|
||||||
(optionals cfg.gnomeTheme [ firefox-gnome-theme ])
|
(optionals cfg.gnomeTheme [ firefox-gnome-theme ])
|
||||||
@ -40,7 +39,7 @@ in {
|
|||||||
})
|
})
|
||||||
|
|
||||||
(optionalAttrs cfg.vaapi {
|
(optionalAttrs cfg.vaapi {
|
||||||
LIBVA_DRIVER_NAME = "nvidia";
|
LIBVA_DRIVER_NAME = "radeonsi"; # "nvidia" for Nvidia card
|
||||||
MOZ_DISABLE_RDD_SANDBOX = 1;
|
MOZ_DISABLE_RDD_SANDBOX = 1;
|
||||||
})
|
})
|
||||||
];
|
];
|
||||||
|
@ -76,10 +76,22 @@
|
|||||||
opengl.driSupport = true;
|
opengl.driSupport = true;
|
||||||
opengl.driSupport32Bit = true;
|
opengl.driSupport32Bit = true;
|
||||||
|
|
||||||
# OpenCL
|
# AMD: https://nixos.wiki/wiki/AMD_GPU
|
||||||
opengl.extraPackages = with pkgs; [
|
opengl.extraPackages = with pkgs; [
|
||||||
|
# amdvlk # RADV (mesa) and AMDVLK (amd) can be used simultaneously
|
||||||
|
|
||||||
|
# OpenCL
|
||||||
rocm-opencl-icd
|
rocm-opencl-icd
|
||||||
rocm-opencl-runtime
|
rocm-opencl-runtime
|
||||||
|
# rocm-runtime # Wiki doesn't mention this, but it exists...
|
||||||
|
|
||||||
|
# VAAPI/VDPAU: https://nixos.wiki/wiki/Accelerated_Video_Playback
|
||||||
|
vaapiVdpau # Taken from wiki
|
||||||
|
libvdpau-va-gl # Taken from wiki
|
||||||
|
|
||||||
|
# TODO: Figure this out (vainfo), it works this way but I still don't know if this is completely correct
|
||||||
|
libvdpau # NOTE: Don't know if needed/where it belongs...
|
||||||
|
libva # NOTE: Don't know if needed/where it belongs...
|
||||||
];
|
];
|
||||||
|
|
||||||
sane.enable = true; # Scanning
|
sane.enable = true; # Scanning
|
||||||
@ -87,5 +99,7 @@
|
|||||||
xpadneo.enable = true; # Xbox Controller
|
xpadneo.enable = true; # Xbox Controller
|
||||||
};
|
};
|
||||||
|
|
||||||
|
environment.variables.AMD_VULKAN_ICD = "RADV"; # Choose mesa driver by default
|
||||||
|
|
||||||
powerManagement.cpuFreqGovernor = lib.mkDefault "powersave";
|
powerManagement.cpuFreqGovernor = lib.mkDefault "powersave";
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user