some discofd flags. fixes something i think
This commit is contained in:
parent
bbe0c17023
commit
62acc8b4dd
1 changed files with 20 additions and 15 deletions
|
@ -3,6 +3,19 @@
|
||||||
with lib;
|
with lib;
|
||||||
let
|
let
|
||||||
cfg = config.modules.software.distractions.discord;
|
cfg = config.modules.software.distractions.discord;
|
||||||
|
flags = [
|
||||||
|
"--flag-switches-begin"
|
||||||
|
"--flag-switches-end"
|
||||||
|
"--disable-gpu-memory-buffer-video-frames"
|
||||||
|
"--enable-accelerated-mjpeg-decode"
|
||||||
|
"--enable-accelerated-video"
|
||||||
|
"--enable-gpu-rasterization"
|
||||||
|
"--enable-native-gpu-memory-buffers"
|
||||||
|
"--enable-zero-copy"
|
||||||
|
"--ignore-gpu-blocklist"
|
||||||
|
"--disable-features=UseOzonePlatform"
|
||||||
|
"--enable-features=VaapiVideoDecoder"
|
||||||
|
];
|
||||||
in {
|
in {
|
||||||
options.modules.software.distractions.discord = {
|
options.modules.software.distractions.discord = {
|
||||||
enable = mkEnableOption "Enable discord, a social messaging app";
|
enable = mkEnableOption "Enable discord, a social messaging app";
|
||||||
|
@ -12,20 +25,6 @@ in {
|
||||||
config = mkIf cfg.enable (mkMerge [
|
config = mkIf cfg.enable (mkMerge [
|
||||||
(mkIf (!cfg.vesktop) {
|
(mkIf (!cfg.vesktop) {
|
||||||
user.packages = let
|
user.packages = let
|
||||||
flags =
|
|
||||||
[
|
|
||||||
"--flag-switches-begin"
|
|
||||||
"--flag-switches-end"
|
|
||||||
"--disable-gpu-memory-buffer-video-frames"
|
|
||||||
"--enable-accelerated-mjpeg-decode"
|
|
||||||
"--enable-accelerated-video"
|
|
||||||
"--enable-gpu-rasterization"
|
|
||||||
"--enable-native-gpu-memory-buffers"
|
|
||||||
"--enable-zero-copy"
|
|
||||||
"--ignore-gpu-blocklist"
|
|
||||||
"--disable-features=UseOzonePlatform"
|
|
||||||
"--enable-features=VaapiVideoDecoder"
|
|
||||||
];
|
|
||||||
discord = (pkgs.discord-canary.override {
|
discord = (pkgs.discord-canary.override {
|
||||||
withOpenASAR = true;
|
withOpenASAR = true;
|
||||||
withVencord = true;
|
withVencord = true;
|
||||||
|
@ -37,7 +36,13 @@ in {
|
||||||
in [ discord ];
|
in [ discord ];
|
||||||
})
|
})
|
||||||
(mkIf cfg.vesktop {
|
(mkIf cfg.vesktop {
|
||||||
user.packages = with pkgs; [ vesktop ];
|
user.packages = [
|
||||||
|
(pkgs.vesktop.overrideAttrs (old: {
|
||||||
|
preInstall = ''
|
||||||
|
gappsWrapperArgs+=("--add-flags" "${concatStringsSep " " flags}")
|
||||||
|
'';
|
||||||
|
}))
|
||||||
|
];
|
||||||
})
|
})
|
||||||
]);
|
]);
|
||||||
}
|
}
|
Loading…
Add table
Add a link
Reference in a new issue