swaywm / sway

i3-compatible Wayland compositor
https://swaywm.org
MIT License
14.71k stars 1.11k forks source link

1.10 black screen on output switch when fullscreen #8434

Open stacyharper opened 1 week ago

stacyharper commented 1 week ago

This is a new issue from: sway version 1.10

Taking this very simple kanshi config:

profile left {
    output DP-1 enable
    output HDMI-A-1 disable
}

profile right {
    output DP-1 disable
    output HDMI-A-1 enable
}

If a toplevel surface is fullscreened while switching, then the surface will be the only one visible to the other output. If you toggle the fullscreen mode on the toplevel, the output become blank. You can fullscreen the surface again and it will re-appears.

The only way to fix the issue is to switch back to the previous ouput (disconnecting the hdmi cable if you kanshi config toggle automatically), un-fullscreen the surface, re-connect the video cable, then re-fullscreen the surface if needed.

sway logs:

sway.log

Here I did:

emersion commented 1 week ago

Your bug report is missing debug logs. Please add a link to the full debug log file.

sway -d >sway.log 2>&1
stacyharper commented 1 week ago

I added a log file, and what I did

Galicarnax commented 1 week ago

Having a similar issue after upgrade to 1.10. In my case, I have laptop and external monitor. Enabling fullscreen in external monitor simply freezes the picture until fullscreen disabled. The picture is frozen only in external monitor, on laptop display everything is Ok (e.g., mouse is moving). Also, when toggling fullscreen for a window in laptop display, no issues (window goes fullscreen).

emersion commented 1 week ago

Does WLR_SCENE_DISABLE_DIRECT_SCANOUT=1 help? (Weird, it should fallback to rendering in that case…)

00:00:25.496 [DEBUG] [wlr] [backend/drm/fb.c:147] Failed to get DMA-BUF from buffer
00:00:25.496 [DEBUG] [wlr] [backend/drm/drm.c:734] connector DP-1: Failed to import buffer for scan-out
stacyharper commented 1 week ago

Does WLR_SCENE_DISABLE_DIRECT_SCANOUT=1 help? (Weird, it should fallback to rendering in that case…)

nak, I still reproduce the issue with this