]> Git — Sourcephile - julm/julm-nix.git/blob - home-manager/profiles/mpv.nix
gcompris: fix support for WebP images
[julm/julm-nix.git] / home-manager / profiles / mpv.nix
1 { pkgs, ... }:
2 {
3 home.packages = [
4 pkgs.mpv
5 ];
6 xdg.configFile."mpv/input.conf".text = ''
7 # Volume normalization
8 # See https://github.com/mpv-player/mpv/issues/3979
9 Alt+a cycle-values af "loudnorm=I=-25:TP=-1.5:LRA=1:linear=false" "dynaudnorm=framelen=100:gausssize=10:coupling=1:peak=0.58" "speechnorm" ""
10 Alt+f cycle video-unscaled
11
12 # Show all chapters (like a right-clic on |<< or >>|)
13 c show_text ''${chapter-list}
14 = show-text ''${playlist}
15 ! show-text ''${track-list}
16
17 # q is easier to type than Q
18 q quit-watch-later
19 ESC quit-watch-later
20 Q quit
21 ENTER playlist-next force
22 '';
23 xdg.configFile."mpv/mpv.conf".text = ''
24 hwdec=auto-safe
25 profile=gpu-hq
26 vo=gpu
27
28 ytdl-format=18/mp4-480p/hls-480p/http-360p/mp4
29
30 # Don't wait ages for the window to finally show up.
31 force-window=immediate
32
33 stop-screensaver=yes
34
35 slang=eng,en,enUS,en-US,fr,fr-FR
36 alang=eng,en,enUS,en-US,fr,fr-FR
37
38 # Higher quality screenshots. Low compression rate to speed up saving.
39 screenshot-directory=~/Images/mpv
40 screenshot-format=avif
41 screenshot-avif-encoder=libsvtav1
42 screenshot-avif-pixfmt=yuv420p
43 # TODO: change crf= wrt. resolution
44 screenshot-avif-opts=crf=24,aq-mode=complexity
45 screenshot-high-bit-depth=yes
46 screenshot-tag-colorspace=yes
47
48 [extension.gif]
49 interpolation=no
50 '';
51 }