(Steam Deck) Black picture in 4-7/10 streams when GAMESCOPE_COMPOSITE_FORCE set to 0 since 2026.906
还没有人认领这个 Issue。
评估
- 难度
- 4/5
- 预计耗时
- 3-5 天
- 新手友好度
- 42/100
- Issue 类型
- 缺陷
- 描述清晰度
- 基本清楚
- 活跃度
- 活跃
- 技术栈
- cpp, linux
调研方向
Start in src/platform/linux/kmsgrab.cpp, especially the plane selection at lines 1539-1542 and the fb() helpers around lines 644-656 and 104-122. Reproduce repeated KMS captures on a Steam Deck with GAMESCOPE_COMPOSITE_FORCE unset or set to 0, comparing working and black streams and their DRM plane state. Done means the capture consistently shows the picture despite the active overlay plane, with the relevant warning or selection behavior corrected.
由索引模型根据 Issue 内容生成。
描述
Is there an existing issue for this?
- I have searched the existing issues
Is your issue described in the documentation?
- I have read the documentation
Is your issue present in the latest beta/pre-release?
This issue is present in the latest pre-release
Describe the Bug
The stream stays black (but sound works) in 4 to 7 out of 10 tries when connecting with Moonlight to a Steam Deck (started as root via flatpak run --system from a Decky plugin, handheld, internal display) since 2026.906 when GAMESCOPE_COMPOSITE_FORCE is set to 0. When set to 1 (using DISPLAY=:0 xprop -root -f GAMESCOPE_COMPOSITE_FORCE 32c -set GAMESCOPE_COMPOSITE_FORCE 1) or using 2026.516, the stream works as expected. Switching that flag while streaming has no effect until you restart the stream. The logs show Warning: Couldn't get drm fb for plane [0]: Invalid argument with 60 entries per second for 13 seconds, but my session continued for another 9 seconds after that and the picture stayed black the whole time.
To reproduce, start a Sunshine instance with version >= 906 in Game Mode with GAMESCOPE_COMPOSITE_FORCE unset or set to 0. As I wrote, this issue only occurs about 4-7 out of 10 tries, and I sometimes got lucky and got 3 working streams in a row (see the log), so you might have to try multiple times.
Expected Behavior
The stream should show a picture all the time.
Additional Context
Note that in the logs I provided, I had to reconnect the stream 3 times for the issue to appear, so the initial logs might look fine. The initial 3 sessions didn't show a single fb warning.
While the stream was black, there have been two active planes on the CRTC - Primary (obj 73, zpos 3) and Overlay
(obj 95, zpos 10), both 1280x800 ARGB8888, both with active AMD color pipeline
(DEGAMMA sRGB, SHAPER, LUT3D, BLEND sRGB). When the stream worked normally, there was just the primary plane, XRGB2101010, Pipeline Default. Rotation (rotate-270) and size were the same in both instances. I can provide the drm_info snapshots if needed.
I also tried the latest pre-release (2026.929.125923), which is affected as well. I had to set system_tray = disabled there though, as otherwise Sunshine would exit right after startup because no system tray is available in game mode on the Steam Deck.
Issue #5659 is possibly related, as it shows similar symptoms (overlay planes disturbing kmsgrab)
My analysis (not verified):
- according to my research the
[0]in the warning message isn't the number of the plane, but of the framebuffer id, meaning that the plane Sunshine chose when starting the stream (kmsgrab.cpp#L1539-L1542) didn't have any framebuffer in the affected frames. kmsgrab.cpptakes the first non-cursor plane with framebuffer and afterward only reads this plane. When there are two planes, the composited image is never read. Which plane Sunshine chooses isn't logged.- plane selection and
refresh()are unchanged between 516 and 914 - 906 brought code changes as well as a runtime change fdo 24.08 -> KDE 6.10, GL 24.08 ->
25.08 at the same time, and there are no intermediate builds on flathub, so I can't bisect this further. However, I can test with AppImages if that helps. - ruled out: privileged DRM/EGL worker (#5706/#5709) - was introduced in 914, but 906 is already affected
Side note for 914: card.fb() (fb() and drmModeGetFB2_privileged/drmModeGetFB_privileged) runs in the worker thread, but the warning prints errno of the calling thread (thread-local) - the error text (EINVAL/EAGAIN) is meaningless. This doesn't explain the black image though, as the black image is already present in 906.
Host Operating System
Linux
Operating System Version
SteamOS 3.8.28 (Build 20260922.1), Kernel 6.18.50-valve2, GameScope 3.16.23.6,
Architecture
amd64/x86_64
Package
Linux - flathub/flatpak
GPU Type
AMD
GPU Model
„AMD Custom GPU 0405" (Van Gogh) / Steam Deck LCD
GPU Driver/Mesa Version
26.2.2 (Flatpak GL.default//25.08, 2026.906+), 26.1.8 (//24.08, 2026.516)
Capture Method
KMS (Linux)
Apps
Log output
Online logs
https://gist.github.com/causa-prima/1c03a3b11e5b050044466fd433ace31c
- 主要语言
- C++
- 星标
- 43k
- 派生
- 2.4k
- PR 合并指标
- 30 天内没有已合并 PR
环境准备
- 没有 Dockerfile 或 Docker Compose 文件
- 没有 Pull Request 模板
- 阅读贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
LizardByte/Sunshine 的其他 Issue
-
Linux keyboard backend has no mapping for VK_ABNT_C1 (ABNT2 dedicated `/ ?` key) — key is silently dropped可能已有人在做 关联的 PR 仍在进行中或已合并。 未关闭
难度 2/5 1-3 小时 新手友好度 78/100
LizardByte/Sunshine#6051 · 2 条评论 ·
-
PIN pairing fails with "Missing CSRF token" - web UI never fetches/attaches the token可能重新可做 关联的 PR 已关闭且未合并。 未关闭
难度 2/5 1-3 小时 新手友好度 72/100
LizardByte/Sunshine#5467 · 2 条评论 ·
-
Virtual HID Driver License notifications appearing even though Enable Gamepad Input is unchecked未关闭
难度 3/5 1-2 天 新手友好度 65/100
LizardByte/Sunshine#6222 · 1 条评论 ·
-
难度 4/5 3-5 天 新手友好度 47/100
LizardByte/Sunshine#6208 ·
-
难度 4/5 3-5 天 新手友好度 45/100
LizardByte/Sunshine#6202 · 1 条评论 ·
查看 LizardByte/Sunshine 的全部 Issue
相似的 Issue
-
难度 1/5 1 小时以内 新手友好度 90/100
维护者通常 2 天内回复
-
bug data-types
难度 2/5 1-3 小时 新手友好度 76/100
ClickHouse/clickhouse-cpp#645 ·
维护者通常 1 天内回复
-
bug compatibility difficulty:easy prio:normal
难度 2/5 1-3 小时 新手友好度 74/100
NatronGitHub/openfx-misc#524 ·
维护者通常 1 天内回复
-
documentation enhancement help wanted P0
难度 2/5 1-3 小时 新手友好度 68/100
Awesome-Embedded-Learning-Studio/Tutorial_AwesomeModernCPP#359 ·
维护者通常 1 天内回复
-
Type: Bug
难度 2/5 1-3 小时 新手友好度 82/100
openscad/openscad#7360 · 2 条评论 ·
维护者通常 1 天内回复