Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Strange lines on transparent windows #319

Open
jEsuSdA opened this issue Feb 21, 2020 · 12 comments
Open

Strange lines on transparent windows #319

jEsuSdA opened this issue Feb 21, 2020 · 12 comments

Comments

@jEsuSdA
Copy link

jEsuSdA commented Feb 21, 2020

Platform

Debian Testing 64bits

GPU, drivers, and screen setup

Intel Haswell, two monitors configured side-by-side

Drivers: package xserver-xorg-video-intel 2:2.99.917+git20190815-1

glxinfo -B:

name of display: :0.0
display: :0  screen: 0
direct rendering: Yes
Extended renderer info (GLX_MESA_query_renderer):
    Vendor: Intel Open Source Technology Center (0x8086)
    Device: Mesa DRI Intel(R) Haswell Desktop  (0x412)
    Version: 19.2.6
    Accelerated: yes
    Video memory: 1536MB
    Unified memory: yes
    Preferred profile: core (0x1)
    Max core profile version: 4.5
    Max compat profile version: 3.0
    Max GLES1 profile version: 1.1
    Max GLES[23] profile version: 3.1
OpenGL vendor string: Intel Open Source Technology Center
OpenGL renderer string: Mesa DRI Intel(R) Haswell Desktop 
OpenGL core profile version string: 4.5 (Core Profile) Mesa 19.2.6
OpenGL core profile shading language version string: 4.50
OpenGL core profile context flags: (none)
OpenGL core profile profile mask: core profile

OpenGL version string: 3.0 Mesa 19.2.6
OpenGL shading language version string: 1.30
OpenGL context flags: (none)

OpenGL ES profile version string: OpenGL ES 3.1 Mesa 19.2.6
OpenGL ES profile shading language version string: OpenGL ES GLSL ES 3.10


Environment

XFCE 4.14

picom version

v7

picom --diagnostics:

**Version:** v7

### Extensions:

* Shape: Yes
* XRandR: Yes
* Present: Present

### Misc:

* Use Overlay: Yes
* Config file used: /home/jesusda/.config/picom.conf

### Drivers (inaccurate):

modesetting  

Configuration:



#################################
#
# Backend
#
#################################

# Backend to use: "xrender" or "glx".
# GLX backend is typically much faster but depends on a sane driver.

# backend = "xrender";
# backend = "xr_glx_hybrid";
backend = "glx";

#################################
#
# GLX backend
#
#################################

glx-no-stencil = true;

# GLX backend: Copy unmodified regions from front buffer instead of redrawing them all.
# My tests with nvidia-drivers show a 10% decrease in performance when the whole screen is modified,
# but a 20% increase when only 1/4 is.
# My tests on nouveau show terrible slowdown.
# Useful with --glx-swap-method, as well.
glx-copy-from-front = false;

# GLX backend: Use MESA_copy_sub_buffer to do partial screen update.
# My tests on nouveau shows a 200% performance boost when only 1/4 of the screen is updated.
# May break VSync and is not available on some drivers.
# Overrides --glx-copy-from-front.
# glx-use-copysubbuffermesa = true;

# GLX backend: Avoid rebinding pixmap on window damage.
# Probably could improve performance on rapid window content changes, but is known to break things on some drivers (LLVMpipe).
# Recommended if it works.
# glx-no-rebind-pixmap = true;


use-damage = true;

#################################
#
# Shadows
#
#################################

# Enabled client-side shadows on windows.
shadow = true;


# The blur radius for shadows. (default 12)
shadow-radius = 35;
# The left offset for shadows. (default -15)
shadow-offset-x = -35;
# The top offset for shadows. (default -15)
shadow-offset-y = -35;
# The translucency for shadows. (default .75)
shadow-opacity = 0.8;

# Set if you want different colour shadows
# shadow-red = 0.0;
# shadow-green = 0.0;
# shadow-blue = 0.0;



# shadow-exclude-reg = "x10+0+0";
# xinerama-shadow-crop = true;


# The shadow exclude options are helpful if you have shadows enabled. Due to the way compton draws its shadows, certain applications will have visual glitches
# (most applications are fine, only apps that do weird things with xshapes or argb are affected).
# This list includes all the affected apps I found in my testing. The "! name~=''" part excludes
# shadows on any "Unknown" windows, this prevents a visual glitch with the XFWM alt tab switcher.

# shadow-exclude = "n:e:Notification";

shadow-exclude = [
	"_GTK_FRAME_EXTENTS@:c",
	# Removed to avoid no-shadow in modal dialog windows.
	# "! name~=''",
    "name = 'Notification'",
    "name = 'Plank'",
    "name = 'Docky'",
    "name = 'Kupfer'",
	#
	# Workaround for VirtualBox empty window at launching
	"name = 'VirtualBox'",
	"name = 'VirtualBoxVM'",
	#
	# Avoid shadow for the XFCE alt tab TaskSwitcher
    "name ?= 'xfwm4' && argb",
	#
    # "name *= 'compton'",
    "class_g = 'Conky'",
    "class_g = 'Kupfer'",
    "class_g = 'Synapse'",
    "class_g ?= 'Notify-osd'",
    "class_g ?= 'Cairo-dock'",
	"class_g = 'Cairo-clock'",
    "class_g ?= 'Xfce4-notifyd'",
	#
	# Exclude special Firefox/Firefox-esr/Thunderbird dropdowns.
  	# Ref: https://github.com/chjj/compton/issues/247
  	# "class_g = 'Firefox' && argb",
  	# "class_g = 'Firefox-esr' && argb",
	# "class_g = 'Thunderbird' && argb",
	#
	# Exclude some special popup menu shadows, but Modal Windows.
	# These are more finetuning thant previous ones:
	"class_g = 'Firefox-esr' && class_i = 'Popup' && argb",
	"class_g = 'Firefox' && class_i = 'Popup' && argb",
	"class_g = 'Navegador Tor' && class_i = 'Popup' && argb",
	"class_g = 'Tor Browser' && class_i = 'Popup' && argb",
	"class_g = 'Thunderbird' && class_i = 'Popup' && argb",
	"class_g ?= 'Thunderbird' && class_i = 'Popup' && argb",
    "class_g ?= 'Xfce4-power-manager'",
	"_GTK_FRAME_EXTENTS@:c"
];
# Avoid drawing shadow on all shaped windows (see also: --detect-rounded-corners)
#  Deprecated, use --shadow-exclude 'bounding_shaped' or --shadow-exclude 'bounding_shaped && !rounded_corners' instead.
shadow-ignore-shaped = false;




#################################
#
# Opacity
#
#################################


inactive-opacity = 1;
active-opacity = 1;
frame-opacity = 1;
inactive-opacity-override = false;

# Desaturate and darken the inactive windows
# Dim inactive windows. (0.0 - 1.0)
#inactive-dim = 0.2;
#inactive-dim-fixed = true;




# Do not let dimness adjust based on window opacity.
# inactive-dim-fixed = true;


# Blur background of transparent windows. Bad performance with X Render backend. GLX backend is preferred.

blur-background = true;


# Blur background of opaque windows with transparent frames as well.
# blur-background-frame = true;
# Do not let blur radius adjust based on window opacity.
#blur-background-fixed = true;

# blur-kern = "3x3box";
# blur-kern = "5,5,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1";
# blur-kern = "5x5box";
blur-kern = "5x5gaussian"


blur-background-exclude = [
    "class_g = 'Peek'",
    "window_type = 'dock'",
	"window_type = 'dropdown_menu'",
	"window_type = 'combo'",
	"window_type = 'popup_menu'",
	"window_type = 'utility'",
    "window_type = 'desktop'",
	"_GTK_FRAME_EXTENTS@:c"
];
opacity-exclude = [
    "name = 'Stratagus'"
];


#################################
#
# Fading
#
#################################

fading = true;
# fade-delta = 30;
#fade-in-step = 0.03;
#fade-out-step = 0.03;
fade-in-step = 0.07;
fade-out-step = 0.07;
# no-fading-openclose = true;
# no-fading-destroyed-argb = true;
fade-exclude = [ ];



#################################
#
# OTHER CONFIG
#
#################################

log-level = "warn";
# log-file = "/path/to/your/log/file";


mark-wmwin-focused = true;
mark-ovredir-focused = true;
# use-ewmh-active-win = true;
detect-rounded-corners = true;
detect-client-opacity = true;
refresh-rate = 0;
vsync = true;
# sw-opti = true;
# unredir-if-possible = true;
# unredir-if-possible-delay = 5000;
# unredir-if-possible-exclude = [ ];

focus-exclude = [ "class_g = 'Cairo-clock'" ];

detect-transient = true;
detect-client-leader = true;
invert-color-include = [ ];

resize-damage = 2;





#################################
#
# Window type settings
#
#################################
wintypes:
{
   dock = { shadow = true; }
   dnd = { shadow = false; }
   popup_menu = { opacity = 1; }
   dropdown_menu = { opacity = 1; }

#   tooltip = { fade = true; shadow = true; opacity = 0.75; focus = true; full-shadow = false; };

};


Steps of reproduction

  1. Run xfce4-terminal configured with transparent background.
  2. Run another xfce4-terminal and notice the garbage lines that appear when moving one of the windows over the other (in fact there appear a lot of lines while using other apps)

Expected behavior

Not having any artifacts.
In compton (debian official packaged version) this is not happening at all.

Current Behavior

Peek 21-02-2020 17-46

Other details

This behavior appears when using xrender and xr_glx_hybrid too.

Thanks a lot and I hope you could help me.
Thanks!!!

@jEsuSdA
Copy link
Author

jEsuSdA commented Feb 21, 2020

Another example (you can see how horizontal lines appear under the console cursor when it is blinking):

Peek 21-02-2020 21-02

@jEsuSdA jEsuSdA changed the title Extrange lines on transparent windows Strange lines on transparent windows Feb 22, 2020
@jEsuSdA
Copy link
Author

jEsuSdA commented Feb 22, 2020

I don't know it is related, but I notice the transparency is lost in some cases in xfce4-terminal.
Here you can find some black background under certain lines:

imagen

@jEsuSdA
Copy link
Author

jEsuSdA commented Feb 25, 2020

I found a workaround:
adding

normal = { full-shadow = true;};

the strange lines disappear, but the background transparency is too dark (cause the shadow).

So, could you help me to avoid artifacts without using full-shadow?
Thanks a lot!

@jEsuSdA
Copy link
Author

jEsuSdA commented Feb 25, 2020

Damn!!
I just notice the problem also appears when trying to using XFCE4-ScreenShot.
The previous workaround does not helps here. :_(

Peek 25-02-2020 19-05

@jEsuSdA
Copy link
Author

jEsuSdA commented Feb 25, 2020

I finally discover that using:

use-damage = false;

solves the problem, but I feel disabling use-damage causes a bit of lag, so any new ideas are welcome. ;)

@xlucn
Copy link

xlucn commented Mar 8, 2020

I think this is a duplicate of #50

@yshui
Copy link
Owner

yshui commented Mar 10, 2020

@jEsuSdA can you try the latest git version of picom? It might have already been resolved.

@jEsuSdA
Copy link
Author

jEsuSdA commented Mar 13, 2020

@jEsuSdA can you try the latest git version of picom? It might have already been resolved.

It still happens. :_(

Peek 13-03-2020 15-37

@TiZ-HugLife
Copy link

TiZ-HugLife commented Apr 22, 2020

I started getting this issue in v8. Didn't happen with 7.5. Seems to be a regression. Xubuntu 18.04, NVidia 440. Video illustrating, and also illustrating it doesn't happen in 7.5: https://youtu.be/ONoM4dSjlGA

@tryone144
Copy link
Collaborator

tryone144 commented Apr 24, 2020

I started getting this issue in v8. Didn't happen with 7.5. Seems to be a regression. Xubuntu 18.04, NVidia 440. Video illustrating, and also illustrating it doesn't happen in 7.5: https://youtu.be/ONoM4dSjlGA

Might be related to the change of the default for --use-damage from false to true.
Use --no-use-damage (or use-damage = false) as a workaround.

@yshui
Copy link
Owner

yshui commented Apr 24, 2020

@TiZ-EX1 Can you get a trace? I think I fixed most of this problem, but apparently there is still some left.

@TiZ-HugLife
Copy link

TiZ-HugLife commented May 29, 2020

Sorry it took so long to get back regarding this. I've attached the trace in a zip file.
picom.trace.zip

Of note is that it doesn't seem to happen in the experimental GLX backend on v8. And indeed, use_damage = false on the old backend does also get rid of it, per @tryone144's suggestion.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants