picom cd
This commit is contained in:
parent
aa31631b95
commit
86b039603e
@ -7,10 +7,14 @@ case "$LANG" in
|
||||
pl*)
|
||||
DISABLED="Kompozytor Picom zastał WYŁĄCZONY"
|
||||
ENABLED="Kompozytor Picom został URUCHOMIONY"
|
||||
RENDERER="Sposób renderowania:"
|
||||
WITHOUT="Bez pliku konfiguracyjnego (/dev/null)"
|
||||
;;
|
||||
*)
|
||||
DISABLED="Picom compositor DISABLED"
|
||||
ENABLED="Picom compositor ENABLED"
|
||||
RENDERER="Renderer backend:"
|
||||
WITHOUT="Running without config file (/dev/null)"
|
||||
;;
|
||||
esac
|
||||
|
||||
@ -21,10 +25,10 @@ else
|
||||
CONFIGFILE="$HOME/.config/picom.conf"
|
||||
if [ -f "$CONFIGFILE" ];then
|
||||
picom --backend "$backend" --config "$CONFIGFILE" &
|
||||
notify-send.sh -i compton -t 5000 "Compositor" "$ENABLED\nRenderer: $backend"
|
||||
notify-send.sh -i compton -t 8000 "$ENABLED" "\n$RENDERER: <b>$backend</b>"
|
||||
else
|
||||
picom --backend "$backend" --config /usr/share/doc/picom/picom.conf.example &
|
||||
notify-send.sh -i compton -t 5000 "Compositor" "$ENABLED\n Using picom example config file\nRenderer: $backend"
|
||||
picom --backend "$backend" --config /dev/null &
|
||||
notify-send.sh -i compton -t 8000 "$ENABLED" "\n$WITHOUT\n$RENDERER <b>$backend</b>"
|
||||
fi
|
||||
fi
|
||||
exit
|
||||
|
@ -1,21 +0,0 @@
|
||||
#!/usr/bin/env bash
|
||||
#
|
||||
# Grayscale using picom.
|
||||
# Based on https://wiki.archlinux.org/title/Picom#Grayscale
|
||||
|
||||
killall picom
|
||||
picom --backend glx --glx-fshader-win "
|
||||
uniform float opacity;
|
||||
uniform bool invert_color;
|
||||
uniform sampler2D tex;
|
||||
|
||||
void main() {
|
||||
vec4 c = texture2D(tex, gl_TexCoord[0].xy);
|
||||
float g = (c.r + c.g + c.b) / 3.0; // EDIT1: Average.
|
||||
c = vec4(vec3(g), c.a); // EDIT2: Color.
|
||||
if (invert_color)
|
||||
c = vec4(vec3(c.a, c.a, c.a) - vec3(c), c.a);
|
||||
c *= opacity;
|
||||
gl_FragColor = c;
|
||||
}
|
||||
"
|
Loading…
Reference in New Issue
Block a user