From a902076085c48665e62197c3f4465906ccf09f4d Mon Sep 17 00:00:00 2001 From: Yaroslav Date: Fri, 3 Apr 2020 01:18:01 +0300 Subject: lockscreen improvements --- dotfiles/.local/bin/setbglblur | 21 ++++++++++++++++++--- 1 file changed, 18 insertions(+), 3 deletions(-) (limited to 'dotfiles/.local/bin/setbglblur') diff --git a/dotfiles/.local/bin/setbglblur b/dotfiles/.local/bin/setbglblur index 8a3d51b..b0c55bc 100755 --- a/dotfiles/.local/bin/setbglblur +++ b/dotfiles/.local/bin/setbglblur @@ -2,7 +2,22 @@ vertical=$(swaymsg -t get_outputs | jq ".[0].current_mode.height") horizontal=$(swaymsg -t get_outputs | jq ".[0].current_mode.width") +scale=$(swaymsg -t get_outputs | jq ".[0].scale") +barheight=$(echo ""$scale" * 27" | bc -l) -convert $1 -resize ${horizontal}x${vertical}\> ~/.config/lockwall.png -convert ~/.config/lockwall.png -brightness-contrast -20,-20 -paint 1 -noise 0x8 -blur 9,9 ~/.config/lockwall.png -convert ~/.config/lockwall.png ~/.config/lock.png -gravity center -composite ~/.config/lockwall.png +convert $1 -resize "$horizontal"x"$vertical" ~/.config/lockwall.png +convert ~/.config/lockwall.png \ + -brightness-contrast -20,-20 \ + -paint 1 \ + -noise 0x8 \ + -blur 9,9 \ + -background "#00000000" \ + -gravity North \ + -chop 0x"$barheight" \ + -gravity South \ + -extent "$horizontal"x"$vertical" \ + ~/.config/lockwall.png +convert ~/.config/lockwall.png ~/.config/lock.png \ + -gravity center \ + -composite \ + ~/.config/lockwall.png -- cgit v1.2.3