From 2a13a292eacb2cfc88238a87fb425eb7c38abc39 Mon Sep 17 00:00:00 2001 From: Bhushan Shah Date: Mon, 23 Oct 2017 13:44:16 +0530 Subject: [PATCH] [platforms/fbdev] Support for RGBA8888 color format Reviewers: #kwin, graesslin Reviewed By: #kwin, graesslin Subscribers: kwin Tags: #kwin Differential Revision: https://phabricator.kde.org/D6798 --- plugins/platforms/fbdev/fb_backend.cpp | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/plugins/platforms/fbdev/fb_backend.cpp b/plugins/platforms/fbdev/fb_backend.cpp index 7955b36030..e2899f0dd2 100644 --- a/plugins/platforms/fbdev/fb_backend.cpp +++ b/plugins/platforms/fbdev/fb_backend.cpp @@ -194,6 +194,17 @@ void FramebufferBackend::initImageFormat() m_red.offset == 16) { qCDebug(KWIN_FB) << "Framebuffer format is RGB32"; m_imageFormat = QImage::Format_RGB32; + } else if (m_bitsPerPixel == 32 && + m_red.length == 8 && + m_green.length == 8 && + m_blue.length == 8 && + m_alpha.length == 8 && + m_red.offset == 0 && + m_green.offset == 8 && + m_blue.offset == 16 && + m_alpha.offset == 24) { + qCDebug(KWIN_FB) << "Framebuffer format is RGBA8888"; + m_imageFormat = QImage::Format_RGBA8888; } else if (m_bitsPerPixel == 24 && m_red.length == 8 && m_green.length == 8 &&