Bug 428284

Summary: Window thumbnails don't work without EXT_image_dma_buf_import
Product: [Plasma] plasmashell Reporter: Fabian Vogt <fabian>
Component: Task Manager and Icons-Only Task ManagerAssignee: Eike Hein <hein>
Status: RESOLVED FIXED    
Severity: normal CC: aleixpol, nate, plasma-bugs, till2.schaefer
Priority: NOR Keywords: wayland
Version: master   
Target Milestone: 1.0   
Platform: openSUSE   
OS: Linux   
Latest Commit: Version Fixed In: 5.23
Sentry Crash Report:

Description Fabian Vogt 2020-10-26 16:35:41 UTC
The thumbnails in the task manager are either just blank or show invalid data (blue square). eglCreateImageKhr returns EGL_NO_IMAGE_KHR with the error set to EGL_BAD_PARAMETER.

This is because some DRI implementations like swrast and radeon simply do not implement EXT_image_dma_buf_import. If that extension is not detected, some other data type should be requested instead.
Comment 1 Till Schäfer 2020-11-29 15:50:20 UTC
Possible duplicate of Bug 427826, can you check if this is true?
Comment 2 Till Schäfer 2020-11-29 16:08:37 UTC
Seems, that my platform (from Bug 427826) does support that extension, but the thumbnails are still not shown. Thus is think this might be a different bug/cause.

 eglinfo | grep EXT_image_dma_buf_import
    EGL_EXT_image_dma_buf_import EGL_EXT_image_dma_buf_import_modifiers
    EGL_EXT_image_dma_buf_import EGL_EXT_image_dma_buf_import_modifiers
    EGL_EXT_create_context_robustness EGL_EXT_image_dma_buf_import
    EGL_EXT_image_dma_buf_import_modifiers

Operating System: Gentoo Linux
KDE Plasma Version: 5.20.3
KDE Frameworks Version: 5.76.0
Qt Version: 5.15.2
Kernel Version: 5.9.11-gentoo
OS Type: 64-bit
Processors: 8 × Intel® Core™ i7-4810MQ CPU @ 2.80GHz
Memory: 15.5 GiB of RAM
Graphics Processor: Mesa DRI Intel® HD Graphics 4600
Comment 3 Aleix Pol 2021-09-19 22:11:05 UTC
I cannot reproduce. If I force disabling dmabuf on our client code it still works through memfd.

How do you test swrast?
Comment 4 Fabian Vogt 2021-09-20 15:29:32 UTC
I still get a blue square here in a VM.

You can probably reproduce this by running "LIBGL_ALWAYS_SOFTWARE=1 plasmashell --replace".
Comment 5 Bug Janitor Service 2021-09-24 07:30:48 UTC
A possibly relevant merge request was started @ https://invent.kde.org/plasma/plasma-workspace/-/merge_requests/1079
Comment 6 Aleix Pol 2021-09-27 13:29:55 UTC
Git commit ad152a1042cab8335f2bd32d7e30f435324d7517 by Aleix Pol Gonzalez, on behalf of Fabian Vogt.
Committed on 27/09/2021 at 13:29.
Pushed by apol into branch 'master'.

libtaskmanager: Don't request dmabuf if not supported

Previously, it specified invalid modifiers on failure, but that means that
everything is accepted.

M  +8    -5    libtaskmanager/declarative/pipewiresourcestream.cpp

https://invent.kde.org/plasma/plasma-workspace/commit/ad152a1042cab8335f2bd32d7e30f435324d7517
Comment 7 Aleix Pol 2021-09-27 13:31:24 UTC
Git commit 2eb212fe97a8fc43953bf1b2123e56137023c574 by Aleix Pol Gonzalez, on behalf of Fabian Vogt.
Committed on 27/09/2021 at 13:31.
Pushed by apol into branch 'Plasma/5.23'.

libtaskmanager: Don't request dmabuf if not supported

Previously, it specified invalid modifiers on failure, but that means that
everything is accepted.


(cherry picked from commit ad152a1042cab8335f2bd32d7e30f435324d7517)

M  +8    -5    libtaskmanager/declarative/pipewiresourcestream.cpp

https://invent.kde.org/plasma/plasma-workspace/commit/2eb212fe97a8fc43953bf1b2123e56137023c574