battery only on NxXPS
This commit is contained in:
41
home-modules/mpv.nix
Normal file
41
home-modules/mpv.nix
Normal file
@@ -0,0 +1,41 @@
|
||||
{ pkgs, ... }@all: with all; {
|
||||
programs.mpv = {
|
||||
enable = true;
|
||||
package = pkgs.mpv;
|
||||
scrips = with pkgs.mpvScripts; [
|
||||
mpris # use media keys
|
||||
thumbfast # thumbnails on timeline hover
|
||||
uosc # custom ui
|
||||
sponsorblock
|
||||
];
|
||||
bindings = {
|
||||
O = ''no-osd cycle-values glsl-shaders "~~/shaders/invert.glsl" ""; show-text "Invert Shader"'';
|
||||
};
|
||||
scriptOpts = {
|
||||
thumbfast = {
|
||||
spawn_first = true;
|
||||
network = true;
|
||||
hwdec = true;
|
||||
};
|
||||
uosc = {
|
||||
timeline_size = 25;
|
||||
timeline_persistency = "paused,audio";
|
||||
progress = "always";
|
||||
progress_size = 4;
|
||||
progress_line_width = 4;
|
||||
controls = "subtitles,<has_many_audio>audio,<has_many_video>video,<has_many_edition>editions,<stream>stream-quality";
|
||||
top_bar = "never";
|
||||
refine = "text_width";
|
||||
};
|
||||
};
|
||||
};
|
||||
xdg.configfile."mpv/shaders/invert.glsl".text = /* glsl */ ''
|
||||
//!HOOK LUMA
|
||||
//!BIND HOOKED
|
||||
vec4 hook()
|
||||
{
|
||||
float luma = LUMA_texOff(0).x;
|
||||
return vec4(1.0 - luma);
|
||||
}
|
||||
'';
|
||||
}
|
||||
Reference in New Issue
Block a user