Updates
This commit is contained in:
parent
f515d7b616
commit
2f595ae7f6
1
.settings/wallpaper-effect.sh
Normal file
1
.settings/wallpaper-effect.sh
Normal file
@ -0,0 +1 @@
|
|||||||
|
off
|
1
hypr/effects/wallpaper/blackwhite
Normal file
1
hypr/effects/wallpaper/blackwhite
Normal file
@ -0,0 +1 @@
|
|||||||
|
magick $wallpaper -set colorspace Gray -separate -average $used_wallpaper
|
2
hypr/effects/wallpaper/blackwhite-blur
Normal file
2
hypr/effects/wallpaper/blackwhite-blur
Normal file
@ -0,0 +1,2 @@
|
|||||||
|
magick $wallpaper -set colorspace Gray -separate -average $used_wallpaper
|
||||||
|
magick $used_wallpaper -blur "50x30" $used_wallpaper
|
1
hypr/effects/wallpaper/blur1
Normal file
1
hypr/effects/wallpaper/blur1
Normal file
@ -0,0 +1 @@
|
|||||||
|
magick $wallpaper -blur "50x30" $used_wallpaper
|
1
hypr/effects/wallpaper/blur2
Normal file
1
hypr/effects/wallpaper/blur2
Normal file
@ -0,0 +1 @@
|
|||||||
|
magick $wallpaper -blur "10x30" $used_wallpaper
|
12
hypr/scripts/wallpaper-effects.sh
Executable file
12
hypr/scripts/wallpaper-effects.sh
Executable file
@ -0,0 +1,12 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
# Open rofi to select the Hyprshade filter for toggle
|
||||||
|
options="$(ls ~/dotfiles/hypr/effects/wallpaper/)\noff"
|
||||||
|
|
||||||
|
# Open rofi
|
||||||
|
choice=$(echo -e "$options" | rofi -dmenu -replace -config ~/dotfiles/rofi/config-themes.rasi -i -no-show-icons -l 5 -width 30 -p "Hyprshade")
|
||||||
|
if [ ! -z $choice ] ;then
|
||||||
|
echo "$choice" > ~/dotfiles/.settings/wallpaper-effect.sh
|
||||||
|
dunstify "Changing Wallpaper Effect to " "$choice"
|
||||||
|
~/dotfiles/hypr/scripts/wallpaper.sh init
|
||||||
|
fi
|
@ -14,6 +14,7 @@ wallpaper_folder="$HOME/wallpaper"
|
|||||||
if [ -f ~/dotfiles/.settings/wallpaper-folder.sh ] ;then
|
if [ -f ~/dotfiles/.settings/wallpaper-folder.sh ] ;then
|
||||||
source ~/dotfiles/.settings/wallpaper-folder.sh
|
source ~/dotfiles/.settings/wallpaper-folder.sh
|
||||||
fi
|
fi
|
||||||
|
used_wallpaper="$HOME/.cache/used_wallpaper"
|
||||||
cache_file="$HOME/.cache/current_wallpaper"
|
cache_file="$HOME/.cache/current_wallpaper"
|
||||||
blurred="$HOME/.cache/blurred_wallpaper.png"
|
blurred="$HOME/.cache/blurred_wallpaper.png"
|
||||||
square="$HOME/.cache/square_wallpaper.png"
|
square="$HOME/.cache/square_wallpaper.png"
|
||||||
@ -74,7 +75,6 @@ esac
|
|||||||
# Load current pywal color scheme
|
# Load current pywal color scheme
|
||||||
# -----------------------------------------------------
|
# -----------------------------------------------------
|
||||||
source "$HOME/.cache/wal/colors.sh"
|
source "$HOME/.cache/wal/colors.sh"
|
||||||
echo ":: Wallpaper: $wallpaper"
|
|
||||||
|
|
||||||
# -----------------------------------------------------
|
# -----------------------------------------------------
|
||||||
# get wallpaper image name
|
# get wallpaper image name
|
||||||
@ -93,11 +93,27 @@ transition_type="wipe"
|
|||||||
# transition_type="outer"
|
# transition_type="outer"
|
||||||
# transition_type="random"
|
# transition_type="random"
|
||||||
|
|
||||||
|
cp $wallpaper $HOME/.cache/
|
||||||
|
mv $HOME/.cache/$newwall $used_wallpaper
|
||||||
|
|
||||||
|
# Load Wallpaper Effect
|
||||||
|
if [ -f $HOME/dotfiles/.settings/wallpaper-effect.sh ] ;then
|
||||||
|
effect=$(cat $HOME/dotfiles/.settings/wallpaper-effect.sh)
|
||||||
|
if [ ! "$effect" == "off" ] ;then
|
||||||
|
if [ "$1" == "init" ] ;then
|
||||||
|
echo ":: Init"
|
||||||
|
else
|
||||||
|
dunstify "Using wallpaper effect $effect..." "with image $newwall" -h int:value:10 -h string:x-dunst-stack-tag:wallpaper
|
||||||
|
fi
|
||||||
|
source $HOME/dotfiles/hypr/effects/wallpaper/$effect
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
wallpaper_engine=$(cat $HOME/dotfiles/.settings/wallpaper-engine.sh)
|
wallpaper_engine=$(cat $HOME/dotfiles/.settings/wallpaper-engine.sh)
|
||||||
if [ "$wallpaper_engine" == "swww" ] ;then
|
if [ "$wallpaper_engine" == "swww" ] ;then
|
||||||
# swww
|
# swww
|
||||||
echo ":: Using swww"
|
echo ":: Using swww"
|
||||||
swww img $wallpaper \
|
swww img $used_wallpaper \
|
||||||
--transition-bezier .43,1.19,1,.4 \
|
--transition-bezier .43,1.19,1,.4 \
|
||||||
--transition-fps=60 \
|
--transition-fps=60 \
|
||||||
--transition-type=$transition_type \
|
--transition-type=$transition_type \
|
||||||
@ -108,7 +124,7 @@ elif [ "$wallpaper_engine" == "hyprpaper" ] ;then
|
|||||||
echo ":: Using hyprpaper"
|
echo ":: Using hyprpaper"
|
||||||
killall hyprpaper
|
killall hyprpaper
|
||||||
wal_tpl=$(cat $HOME/dotfiles/.settings/hyprpaper.tpl)
|
wal_tpl=$(cat $HOME/dotfiles/.settings/hyprpaper.tpl)
|
||||||
output=${wal_tpl//WALLPAPER/$wallpaper}
|
output=${wal_tpl//WALLPAPER/$used_wallpaper}
|
||||||
echo "$output" > $HOME/dotfiles/hypr/hyprpaper.conf
|
echo "$output" > $HOME/dotfiles/hypr/hyprpaper.conf
|
||||||
hyprpaper &
|
hyprpaper &
|
||||||
else
|
else
|
||||||
|
@ -111,7 +111,7 @@
|
|||||||
"custom/wallpaper": {
|
"custom/wallpaper": {
|
||||||
"format": "",
|
"format": "",
|
||||||
"on-click": "~/dotfiles/hypr/scripts/wallpaper.sh select",
|
"on-click": "~/dotfiles/hypr/scripts/wallpaper.sh select",
|
||||||
"on-click-right": "~/dotfiles/hypr/scripts/wallpaper.sh",
|
"on-click-right": "~/dotfiles/hypr/scripts/wallpaper-effects.sh",
|
||||||
"tooltip": false
|
"tooltip": false
|
||||||
},
|
},
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user