From a95be71ec183ef87cdd2665d20691cf3fc9e38de Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Gr=C3=A4=C3=9Flin?= Date: Tue, 19 Jul 2016 08:16:54 +0200 Subject: [PATCH] [plugins/hwcomposer] Use an RGBA_8888 format for rendering surface Summary: When sharing surface and config used by the compositor scene with QtQuick's OpenGL context an RGBA surface makes Qt way more happy. Reviewers: #kwin, #plasma_on_wayland Subscribers: plasma-devel, kwin Tags: #plasma_on_wayland, #kwin Differential Revision: https://phabricator.kde.org/D2232 --- plugins/platforms/hwcomposer/egl_hwcomposer_backend.cpp | 2 +- plugins/platforms/hwcomposer/hwcomposer_backend.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/plugins/platforms/hwcomposer/egl_hwcomposer_backend.cpp b/plugins/platforms/hwcomposer/egl_hwcomposer_backend.cpp index a1a9d5ef93..8ce61871b1 100644 --- a/plugins/platforms/hwcomposer/egl_hwcomposer_backend.cpp +++ b/plugins/platforms/hwcomposer/egl_hwcomposer_backend.cpp @@ -75,7 +75,7 @@ bool EglHwcomposerBackend::initBufferConfigs() EGL_RED_SIZE, 8, EGL_GREEN_SIZE, 8, EGL_BLUE_SIZE, 8, - EGL_ALPHA_SIZE, 0, + EGL_ALPHA_SIZE, 8, EGL_RENDERABLE_TYPE, EGL_OPENGL_ES2_BIT, EGL_NONE, }; diff --git a/plugins/platforms/hwcomposer/hwcomposer_backend.cpp b/plugins/platforms/hwcomposer/hwcomposer_backend.cpp index 1a59c78eb8..9305d39613 100644 --- a/plugins/platforms/hwcomposer/hwcomposer_backend.cpp +++ b/plugins/platforms/hwcomposer/hwcomposer_backend.cpp @@ -391,7 +391,7 @@ static void initLayer(hwc_layer_1_t *layer, const hwc_rect_t &rect) } HwcomposerWindow::HwcomposerWindow(HwcomposerBackend *backend) - : HWComposerNativeWindow(backend->size().width(), backend->size().height(), HAL_PIXEL_FORMAT_RGB_888) + : HWComposerNativeWindow(backend->size().width(), backend->size().height(), HAL_PIXEL_FORMAT_RGBA_8888) , m_backend(backend) { setBufferCount(3);