Adjust bg script animation speed

This commit is contained in:
davidovski 2023-02-06 12:07:49 +00:00
parent 886f6d7aad
commit 8c1786d852
6 changed files with 23 additions and 14 deletions

View File

@ -13,6 +13,14 @@ audio_output {
max_clients "0"
}
audio_output {
type "httpd"
name "HQ HTTP Stream"
encoder "wave" # optional, vorbis or lame
port "6681"
max_clients "0"
}
audio_output {
type "pulse"
name "mpd"

View File

@ -162,8 +162,8 @@ format-prefix = "力 "
[module/battery]
type = internal/battery
full-at = 99
battery = BAT1
adapter = ADP1
battery = BAT0
adapter = AC
poll-interval = 3
time-format = %H:%M
@ -171,8 +171,8 @@ time-format = %H:%M
format-charging = <animation-charging> <label-charging>
format-discharging = <ramp-capacity> <label-discharging>
label-charging = -%percentage%%
label-discharging = -%percentage%%
label-charging = +%percentage%%
label-discharging = %percentage%%
label-full = %percentage%%
ramp-capacity-0 = 

View File

@ -25,8 +25,8 @@
background-color: #00000000;
background: #191919;
background2: #191919;
foreground: #f58f44;
foreground2: #5f819d;
foreground: #fefefe;
foreground2: #373b41;
spacing: 2;
font: "mononoki 12";

2
mkshrc
View File

@ -50,6 +50,8 @@ function parse_git_dirty {
[ ! "${bits}" == "" ] && echo " ${bits}" || echo ""
}
#set -o vi
bind '^L=clear-screen'
export PS1=$(echo -e "\e[0;97m\${PWD/#\$HOME/\~}\e[0;37m\`parse_git_branch\` > \e[0;0m")

View File

@ -12,7 +12,7 @@ convert -coalesce $image $dir/%05d.png
printf "done\n"
amount_of_frames=$(ls -1 "$dir" | wc -l)
frames_per_second=30
frames_per_second=10
speed=$(echo "scale=3; ($amount_of_frames/$frames_per_second) * (1/$frames_per_second)" | bc -l)
while : ; do

View File

@ -19,23 +19,22 @@ tablet_ratio = (lambda s: float(s[0]) / float(s[1]))(sys.argv[4].split(":")) if
#]
screens = [
(0, 0, 1280, 1024),
(1280, 0, 2560, 1440),
(3840, 0, 1920, 1080),
(5760, 0, 1920, 1080),
(0, 0, 1920, 1080),
(0, 1080, 1920, 1080),
(1920, 1080, 2560, 1440),
]
#TODO find this with xrandr
target = screens[1]
target = screens[2]
#Physical offset of the selected screen
offsetx = target[0]
offsety = target[1]
#Size of the full screen areas
sh = 1920
sw = 1280 + 2560 + 1080 + 1080
sh = 1080+ 1440
sw = 1920 + 2560
#TODO calculate using list of screens
#Aspect ratio of the tablet, to avoid weird scaling problems