forked from Shinonome/dots-hyprland
switchwall: fix mpv options being overriden by load-scripts only (#1696)
This commit is contained in:
@@ -114,7 +114,7 @@ THUMBNAIL_DIR="/tmp/mpvpaper_thumbnails"
|
|||||||
CUSTOM_DIR="$XDG_CONFIG_HOME/hypr/custom"
|
CUSTOM_DIR="$XDG_CONFIG_HOME/hypr/custom"
|
||||||
RESTORE_SCRIPT_DIR="$CUSTOM_DIR/scripts"
|
RESTORE_SCRIPT_DIR="$CUSTOM_DIR/scripts"
|
||||||
RESTORE_SCRIPT="$RESTORE_SCRIPT_DIR/__restore_video_wallpaper.sh"
|
RESTORE_SCRIPT="$RESTORE_SCRIPT_DIR/__restore_video_wallpaper.sh"
|
||||||
VIDEO_OPTS="no-audio loop hwdec=auto scale=bilinear interpolation=no video-sync=display-resample panscan=1.0 video-scale-x=1.0 video-scale-y=1.0 video-align-x=0.5 video-align-y=0.5"
|
VIDEO_OPTS="no-audio loop hwdec=auto scale=bilinear interpolation=no video-sync=display-resample panscan=1.0 video-scale-x=1.0 video-scale-y=1.0 video-align-x=0.5 video-align-y=0.5 load-scripts=no"
|
||||||
|
|
||||||
is_video() {
|
is_video() {
|
||||||
local extension="${1##*.}"
|
local extension="${1##*.}"
|
||||||
@@ -135,7 +135,7 @@ create_restore_script() {
|
|||||||
pkill -f -9 mpvpaper
|
pkill -f -9 mpvpaper
|
||||||
|
|
||||||
for monitor in \$(hyprctl monitors -j | jq -r '.[] | .name'); do
|
for monitor in \$(hyprctl monitors -j | jq -r '.[] | .name'); do
|
||||||
mpvpaper -o "$VIDEO_OPTS" "\$monitor" "$video_path" --mpv-options '--load-scripts=no' &
|
mpvpaper -o "$VIDEO_OPTS" "\$monitor" "$video_path" &
|
||||||
sleep 0.1
|
sleep 0.1
|
||||||
done
|
done
|
||||||
EOF
|
EOF
|
||||||
|
|||||||
Reference in New Issue
Block a user