yshui / picom

A lightweight compositor for X11 with animation support
https://picom.app/
Other
4.1k stars 587 forks source link

dual_kawase with transparent-clipping creates inner shadow #936

Open Anarky opened 1 year ago

Anarky commented 1 year ago

Platform

Archlinux

GPU, drivers, and screen setup

name of display: :0
display: :0  screen: 0
direct rendering: Yes
Extended renderer info (GLX_MESA_query_renderer):
    Vendor: Intel (0x8086)
    Device: Mesa Intel(R) HD Graphics 4600 (HSW GT2) (0x416)
    Version: 22.2.3
    Accelerated: yes
    Video memory: 1536MB
    Unified memory: yes
    Preferred profile: core (0x1)
    Max core profile version: 4.6
    Max compat profile version: 4.6
    Max GLES1 profile version: 1.1
    Max GLES[23] profile version: 3.2
OpenGL vendor string: Intel
OpenGL renderer string: Mesa Intel(R) HD Graphics 4600 (HSW GT2)
OpenGL core profile version string: 4.6 (Core Profile) Mesa 22.2.3
OpenGL core profile shading language version string: 4.60
OpenGL core profile context flags: (none)
OpenGL core profile profile mask: core profile

OpenGL version string: 4.6 (Compatibility Profile) Mesa 22.2.3
OpenGL shading language version string: 4.60
OpenGL context flags: (none)
OpenGL profile mask: compatibility profile

OpenGL ES profile version string: OpenGL ES 3.2 Mesa 22.2.3
OpenGL ES profile shading language version string: OpenGL ES GLSL ES 3.20

Environment

Awesome WM

picom version

vgit-98a5c

Diagnostics **Version:** vgit-98a5c ### Extensions: * Shape: Yes * XRandR: Yes * Present: Present ### Misc: * Use Overlay: No (Another compositor is already running) * Config file used: /home/anarky/.config/picom.conf ### Drivers (inaccurate): modesetting ### Backend: glx * Driver vendors: * GLX: Mesa Project and SGI * GL: Intel * GL renderer: Mesa Intel(R) HD Graphics 4600 (HSW GT2) * Accelerated: 1 ### Backend: egl * Driver vendors: * EGL: Mesa Project * EGL driver: crocus * GL: Intel * GL renderer: Mesa Intel(R) HD Graphics 4600 (HSW GT2)

Configuration:

Configuration file ``` backend = "glx"; transparent-clipping = true; blur-method = "dual_kawase"; opacity-rule = [ "70:class_g = 'URxvt'", ]; ```

Steps of reproduction

  1. Use the provided configuration - it only contains the minimal options to reproduce the bug
  2. Move windows in floating mode, making them overlapping or touching each other

Expected behavior

There are no shadows inside the window

Current Behavior

A shadow appears inside the window that is touching or overlapping another windows or Awesome's top bar:

1 2 3 4 5

Anarky commented 1 year ago

Very small update: I was using an old version, it is now up-to-date but the issue is still the same. I updated picom --version and picom --diagnostics on the first comment, if it helps.

absolutelynothelix commented 1 year ago

@yshui, some thoughts on this: we're doing this, but in a blur function reg_blur gets resized - may it be the issue? however, 1) doing pixman_region32_intersect(&reg_blur_resized, &reg_blur_resized, reg_visible); after resizing doesn't change anything 2) doing pixman_region32_intersect(&reg_blur_resized, &reg_blur_resized, reg_blur); after risizing fixes the issue, but i have a feeling that it undoes resizing (if i understand regions correctly)

also, no matter what we do in blur function we need to check if we have transparent clipping enabled, but there is no access to ps->o.transparent_clipping.

i hope this information will help you somehow.