3
0
mirror of https://github.com/hyprwm/Hyprland.git synced 2025-10-29 11:22:47 +00:00

screencopy: fix missing XBGR2101010 format with screencopy_force_8b (#12125)

Adds missing DRM_FORMAT_XBGR2101010 to screencopy_force_8b that leads to
"no more input formats" Pipewire error for monitors set to 10-bit color
depth/where currentFormat is XBGR2101010.

Fixes implementation of #11623
Fixes hyprwm/xdg-desktop-portal-hyprland#270
Fixes hyprwm/xdg-desktop-portal-hyprland#102
This commit is contained in:
ccos89 2025-10-25 10:57:46 +00:00 committed by GitHub
parent da04afa44e
commit b10b966000
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -3323,7 +3323,7 @@ uint32_t CHyprOpenGLImpl::getPreferredReadFormat(PHLMONITOR pMonitor) {
auto fmt = pMonitor->m_output->state->state().drmFormat;
if (fmt == DRM_FORMAT_BGRA1010102 || fmt == DRM_FORMAT_ARGB2101010 || fmt == DRM_FORMAT_XRGB2101010 || fmt == DRM_FORMAT_BGRX1010102)
if (fmt == DRM_FORMAT_BGRA1010102 || fmt == DRM_FORMAT_ARGB2101010 || fmt == DRM_FORMAT_XRGB2101010 || fmt == DRM_FORMAT_BGRX1010102 || fmt == DRM_FORMAT_XBGR2101010)
return DRM_FORMAT_XRGB8888;
return fmt;