diff options
| author | 2026-04-25 14:28:02 -0400 | |
|---|---|---|
| committer | 2026-04-25 14:46:39 -0400 | |
| commit | 0848d6c89defb95966deeecd1c61352deccbeaec (patch) | |
| tree | 21a2e74fcabb85c02fda8959badc08b0f7de0261 /hosts/iroha/gentoo/patches/gui-wm/gamescope/1826.diff | |
| parent | ef40a5119a77280863c21ba67397818514714ccc (diff) | |
| download | dotfiles-0848d6c89defb95966deeecd1c61352deccbeaec.tar.gz dotfiles-0848d6c89defb95966deeecd1c61352deccbeaec.tar.bz2 dotfiles-0848d6c89defb95966deeecd1c61352deccbeaec.zip | |
New CPU + Cleanup
Diffstat (limited to 'hosts/iroha/gentoo/patches/gui-wm/gamescope/1826.diff')
| -rw-r--r-- | hosts/iroha/gentoo/patches/gui-wm/gamescope/1826.diff | 84 |
1 files changed, 0 insertions, 84 deletions
diff --git a/hosts/iroha/gentoo/patches/gui-wm/gamescope/1826.diff b/hosts/iroha/gentoo/patches/gui-wm/gamescope/1826.diff deleted file mode 100644 index 69c85e8..0000000 --- a/hosts/iroha/gentoo/patches/gui-wm/gamescope/1826.diff +++ /dev/null @@ -1,84 +0,0 @@ -diff --git a/src/Backends/WaylandBackend.cpp b/src/Backends/WaylandBackend.cpp -index 7e68a44fb..65e35f525 100644 ---- a/src/Backends/WaylandBackend.cpp -+++ b/src/Backends/WaylandBackend.cpp -@@ -2002,24 +2002,32 @@ namespace gamescope - // Prefer opaque for composition on the Wayland backend. - - uint32_t u8BitFormat = DRM_FORMAT_INVALID; -- if ( SupportsFormat( DRM_FORMAT_XRGB8888 ) ) -- u8BitFormat = DRM_FORMAT_XRGB8888; -- else if ( SupportsFormat( DRM_FORMAT_XBGR8888 ) ) -- u8BitFormat = DRM_FORMAT_XBGR8888; -- else if ( SupportsFormat( DRM_FORMAT_ARGB8888 ) ) -- u8BitFormat = DRM_FORMAT_ARGB8888; -- else if ( SupportsFormat( DRM_FORMAT_ABGR8888 ) ) -- u8BitFormat = DRM_FORMAT_ABGR8888; -+ for (int i = 0; i < 2 && u8BitFormat == DRM_FORMAT_INVALID; i++) -+ { -+ bool invalidOnly = i == 0; -+ if ( SupportsFormat( DRM_FORMAT_XRGB8888, invalidOnly ) ) -+ u8BitFormat = DRM_FORMAT_XRGB8888; -+ else if ( SupportsFormat( DRM_FORMAT_XBGR8888, invalidOnly ) ) -+ u8BitFormat = DRM_FORMAT_XBGR8888; -+ else if ( SupportsFormat( DRM_FORMAT_ARGB8888, invalidOnly ) ) -+ u8BitFormat = DRM_FORMAT_ARGB8888; -+ else if ( SupportsFormat( DRM_FORMAT_ABGR8888, invalidOnly ) ) -+ u8BitFormat = DRM_FORMAT_ABGR8888; -+ } - - uint32_t u10BitFormat = DRM_FORMAT_INVALID; -- if ( SupportsFormat( DRM_FORMAT_XBGR2101010 ) ) -- u10BitFormat = DRM_FORMAT_XBGR2101010; -- else if ( SupportsFormat( DRM_FORMAT_XRGB2101010 ) ) -- u10BitFormat = DRM_FORMAT_XRGB2101010; -- else if ( SupportsFormat( DRM_FORMAT_ABGR2101010 ) ) -- u10BitFormat = DRM_FORMAT_ABGR2101010; -- else if ( SupportsFormat( DRM_FORMAT_ARGB2101010 ) ) -- u10BitFormat = DRM_FORMAT_ARGB2101010; -+ for (int i = 0; i < 2 && u10BitFormat == DRM_FORMAT_INVALID; i++) -+ { -+ bool invalidOnly = i == 0; -+ if ( SupportsFormat( DRM_FORMAT_XBGR2101010, invalidOnly ) ) -+ u10BitFormat = DRM_FORMAT_XBGR2101010; -+ else if ( SupportsFormat( DRM_FORMAT_XRGB2101010, invalidOnly ) ) -+ u10BitFormat = DRM_FORMAT_XRGB2101010; -+ else if ( SupportsFormat( DRM_FORMAT_ABGR2101010, invalidOnly ) ) -+ u10BitFormat = DRM_FORMAT_ABGR2101010; -+ else if ( SupportsFormat( DRM_FORMAT_ARGB2101010, invalidOnly ) ) -+ u10BitFormat = DRM_FORMAT_ARGB2101010; -+ } - - assert( u8BitFormat != DRM_FORMAT_INVALID ); - -diff --git a/src/backend.h b/src/backend.h -index 29219dbc8..2767546cd 100644 ---- a/src/backend.h -+++ b/src/backend.h -@@ -309,9 +309,11 @@ namespace gamescope - - virtual bool UsesModifiers() const = 0; - virtual std::span<const uint64_t> GetSupportedModifiers( uint32_t uDrmFormat ) const = 0; -- inline bool SupportsFormat( uint32_t uDrmFormat ) const -+ inline bool SupportsFormat( uint32_t uDrmFormat, bool invalidOnly ) const - { -- return Algorithm::Contains( this->GetSupportedModifiers( uDrmFormat ), DRM_FORMAT_MOD_INVALID ); -+ if ( invalidOnly ) -+ return Algorithm::Contains( this->GetSupportedModifiers( uDrmFormat ), DRM_FORMAT_MOD_INVALID ); -+ return !this->GetSupportedModifiers( uDrmFormat ).empty(); - } - - virtual IBackendConnector *GetCurrentConnector() = 0; -diff --git a/src/rendervulkan.cpp b/src/rendervulkan.cpp -index b8412b8fd..f41ef4c9b 100644 ---- a/src/rendervulkan.cpp -+++ b/src/rendervulkan.cpp -@@ -2814,7 +2814,7 @@ bool vulkan_init_format(VkFormat format, uint32_t drmFormat) - } - else - { -- if ( GetBackend()->UsesModifiers() && !GetBackend()->SupportsFormat( drmFormat ) ) -+ if ( GetBackend()->UsesModifiers() && !GetBackend()->SupportsFormat( drmFormat, true ) ) - return false; - - wlr_drm_format_set_add( &sampledDRMFormats, drmFormat, DRM_FORMAT_MOD_INVALID ); |