diff --git a/bin/brightne.sh b/bin/brightne.sh index 59aa37f..ab384f4 100755 --- a/bin/brightne.sh +++ b/bin/brightne.sh @@ -8,10 +8,10 @@ E_NOARGS=75 -backlight_path=/sys/class/backlight/nvidia_backlight +backlight_path=/sys/class/backlight/nv_backlight usage() { - echo "Usage: brightne.sh [set|fix|up|down] arg between 0 and 1024" + echo "Usage: brightne.sh [set|fix|up|down] arg between 0 and 1000" } get_raw_maximum() { @@ -26,7 +26,7 @@ set_raw() { echo $1 > $backlight_path/brightness } -# from 0-1024 to 0-max +# from 0-1000 to 0-max scale_to_bl() { get_raw_maximum max=$? @@ -34,14 +34,14 @@ scale_to_bl() { } scale_from_to() { - echo "$2 * $1 / 1024" | bc + echo "$2 * $1 / 1000" | bc } -# from 0-max to 0-1024 +# from 0-max to 0-1000 scale_from_bl() { get_raw_maximum max=$? - echo "1024 * $1 / $max" | bc + echo "1000 * $1 / $max" | bc } off() { diff --git a/i3/i3.nix b/i3/i3.nix index 2afa15f..a625ae0 100644 --- a/i3/i3.nix +++ b/i3/i3.nix @@ -175,8 +175,8 @@ exec --no-startup-id ${xautolock}/bin/xautolock -time 15 -locker ${locker} -lock '') + '' -bindsym XF86MonBrightnessUp exec ${brightness}/bin/brightness up 50 -bindsym XF86MonBrightnessDown exec ${brightness}/bin/brightness down 50 +bindsym XF86MonBrightnessUp exec ${brightness}/bin/brightness up 10 +bindsym XF86MonBrightnessDown exec ${brightness}/bin/brightness down 10 bindsym XF86AudioLowerVolume exec ${alsaUtils}/bin/amixer set Master 1%- bindsym XF86AudioRaiseVolume exec ${alsaUtils}/bin/amixer set Master 1%+ bindsym XF86AudioMute exec ${alsaUtils}/bin/amixer set Master toggle diff --git a/x/compton.conf b/x/compton.conf index 29355ea..68f7ee0 100644 --- a/x/compton.conf +++ b/x/compton.conf @@ -11,9 +11,10 @@ backend = "glx" paint-on-overlay = true; glx-no-stencil = true; glx-no-rebind-pixmap = true; +glx-swap-method = -1; # With newer NVIDIA drivers, this option is needed to prevent lags/flickering: -xrender-sync-fence = true; +#xrender-sync-fence = true; unredir-if-possible = true; -vsync = "opengl-swc"; +vsync = "opengl-oml";