This commit is contained in:
2023-10-01 19:57:01 +02:00
parent f40d34aa5f
commit aad2042c6b
9 changed files with 183 additions and 27 deletions

View File

@@ -0,0 +1,22 @@
#version 330
in vec2 texcoord;
uniform float opacity;
uniform bool invert_color;
uniform sampler2D tex;
vec4 window_shader() {
vec4 c = texelFetch(tex, ivec2(texcoord), 0);
{
// Change vec4(1.0, 1.0, 1.0, 1.0) to your desired color
vec4 vdiff = abs(vec4(0.0, 0.0, 0.0, 1.0) - c);
float diff = max(max(max(vdiff.r, vdiff.g), vdiff.b), vdiff.a);
// Change 0.8 to your desired opacity
if (diff < 0.001)
c *= 0;
}
if (invert_color)
c = vec4(vec3(c.a, c.a, c.a) - vec3(c), c.a);
c *= opacity;
vec4 default_post_processing(vec4 c);
return c;
}

View File

@@ -41,7 +41,10 @@ shadow-exclude = [
# disables shadows on sticky windows:
"_NET_WM_STATE@:32a *= '_NET_WM_STATE_STICKY'",
# disables shadows on i3 frames
"class_g ?= 'i3-frame'"
"class_g ?= 'i3-frame'",
"class_g = 'Rofi'",
"class_g = 'Bspwm'",
"class_g ?= 'ulauncher'"
];
# Specify a X geometry that describes the region in which shadow should not
@@ -129,7 +132,7 @@ focus-exclude = [ "class_g = 'Cairo-clock'" ];
# Sets the radius of rounded window corners. When > 0, the compositor will
# round the corners of windows. Does not interact well with
# `transparent-clipping`.
corner-radius = 8
corner-radius = 9
# Exclude conditions for rounded corners.
rounded-corners-exclude = [
@@ -145,7 +148,7 @@ rounded-corners-exclude = [
blur: {
method = "dual_kawase";
strength = 12;
strength = 10;
background = false;
background-frame = false;
background-fixed = false;
@@ -300,6 +303,17 @@ use-damage = true;
#
# glx-fshader-win = ""
window-shader-fg-rule = [
# "black_to_transparent.frag:class_g = 'stalonetray'",
# "black_to_transparent.frag:class_g = 'Minecraft 1.7.10'",
"black_to_transparent.frag:class_g = 'i3lock'",
# "black_to_transparent.frag:focused = true",
# "black_to_transparent.frag:focused != true",
#"sphere.glsl:focused != true"
#"nordify.glsl:class_g = 'miru'"
]
# Force all windows to be painted with blending. Useful if you
# have a glx-fshader-win that could turn opaque pixels transparent.
#