Bug 490562

Summary: Switching activities: GL_INVALID_VALUE in glTexStorage2D(width, height or depth < 1)
Product: [Plasma] kwin Reporter: bastimeyer123
Component: scene-openglAssignee: KWin default assignee <kwin-bugs-null>
Status: REPORTED ---    
Severity: normal CC: lingm+kdebugs, postix
Priority: NOR    
Version First Reported In: 6.1.3   
Target Milestone: ---   
Platform: Other   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:

Description bastimeyer123 2024-07-20 14:46:28 UTC
SUMMARY
Not sure if this is related to BUG 488964.

When switching activities and staying on the same virtual desktop, kwin_wayland is logging these error messages:
```
Jul 20 16:27:02 basti-pc kwin_wayland[1843]: kwin_scene_opengl: 0x3: GL_INVALID_VALUE in glTexStorage2D(width, height or depth < 1)
Jul 20 16:27:02 basti-pc kwin_wayland[1843]: kwin_scene_opengl: Invalid framebuffer status:  "GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT"
Jul 20 16:27:02 basti-pc kwin_wayland[1843]: kwin_effect_blur: Failed to create an offscreen framebuffer
```
This however seems to depend on the opened windows on the currently used desktop(s). I can reproduce this every time having Konsole opened. I also don't see any errors being logged when the activity switch involves switching to a different virtual desktop.

STEPS TO REPRODUCE
1. Have more than one activity
2. Open various application windows on both activities
3. Switch activities while staying on the same virtual desktop

SOFTWARE/OS VERSIONS
Linux/KDE Plasma: Arch Linux
KDE Plasma Version: 6.1.3
KDE Frameworks Version: 6.4.0
Qt Version: 6.7.2
Comment 1 postix 2024-10-23 13:08:19 UTC
I've seen this too, but not when switching activities, in my case I've observed it when PyCharm froze.

Operating System: openSUSE Tumbleweed 20241021
KDE Plasma Version: 6.2.1
KDE Frameworks Version: 6.7.0
Qt Version: 6.8.0
Kernel Version: 6.11.3-2-default (64-bit)
Graphics Platform: Wayland
Graphics Processor: AMD Radeon RX 580 Series
Comment 2 postix 2024-10-23 13:09:56 UTC
when the frozen PyCharm 2024.x window is focused and I try to exit the application it in the task manager in the panel, these error lines are logged.
Comment 3 LaughingMan 2025-07-23 05:59:42 UTC
Same error messages in my logs recently, just with kwin_x11:

```
Jul 23 07:11:02 laughingman kwin_x11[1813]: kwin_scene_opengl: 0x3: GL_INVALID_VALUE in glTexStorage2D(width, height or depth < 1)
Jul 23 07:11:02 laughingman kwin_x11[1813]: kwin_scene_opengl: Invalid framebuffer status:  "GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT"
Jul 23 07:11:02 laughingman kwin_x11[1813]: kwin_effect_blur: Failed to create an offscreen framebuffer
```

Haven't been able to pinpoint what triggers them for me though.