ytcc: Prefer newer video codecs

This commit is contained in:
Simon Bruder 2021-10-10 14:43:59 +02:00
parent ec0a8dfa49
commit abe078a914
Signed by: simon
GPG key ID: 8D3C82F9F309F8EC

View file

@ -1,5 +1,12 @@
{ lib, pkgs, ... }:
let
ytdl-format = map (vc: "bestvideo[vcodec^=${vc}][width<=1920]+bestaudio[acodec^=opus]") [ "av01" "vp9" "avc1" ]
++ [
"bestvideo+bestaudio[acodec^=opus]"
"bestvideo+bestaudio"
"best"
];
in
{
xdg.configFile."ytcc/ytcc.conf".text = lib.generators.toINI { } {
ytcc = {
@ -8,7 +15,7 @@
"--volume=90"
"--profile=clear-speed"
"--ytdl"
"--ytdl-format=bestvideo[vcodec^=avc1][width<=1920][fps<=30]+bestaudio[acodec^=opus]/bestvideo+bestaudio/best"
"--ytdl-format=${lib.concatStringsSep "/" ytdl-format}"
];
};