From 957abce4fb20b1ed92241a286cd8b57d896b6817 Mon Sep 17 00:00:00 2001 From: Javon Prince Date: Wed, 30 Apr 2014 12:06:42 +0100 Subject: [PATCH] EGL: Ignore EGL_ALPHA_SIZE = 8 in eglChooseConfig on desktop environment Change-Id: I62e4fb28ac285796f25492036b18ad843b29e8b9 Signed-off-by: Javon Prince --- .../tizen/internal/common/gl/egl-implementation.cpp | 18 ++++++++---------- 1 file changed, 8 insertions(+), 10 deletions(-) diff --git a/adaptors/tizen/internal/common/gl/egl-implementation.cpp b/adaptors/tizen/internal/common/gl/egl-implementation.cpp index 08ea55e..65cfb6e 100644 --- a/adaptors/tizen/internal/common/gl/egl-implementation.cpp +++ b/adaptors/tizen/internal/common/gl/egl-implementation.cpp @@ -372,16 +372,14 @@ void EglImplementation::ChooseConfig( bool isWindowType, ColorDepth depth ) configAttribs.PushBack( EGL_BLUE_SIZE ); configAttribs.PushBack( 8 ); - if(depth == COLOR_DEPTH_32) - { - configAttribs.PushBack( EGL_ALPHA_SIZE ); - configAttribs.PushBack( 8 ); - } - else - { - configAttribs.PushBack( EGL_ALPHA_SIZE ); - configAttribs.PushBack( 0 ); - } + configAttribs.PushBack( EGL_ALPHA_SIZE ); +#ifdef _ARCH_ARM_ + configAttribs.PushBack( (depth == COLOR_DEPTH_32) ? 8 : 0 ); +#else + // There is a bug in the desktop emulator + // setting EGL_ALPHA_SIZE to 8 results in eglChooseConfig failing + configAttribs.PushBack( 0 ); +#endif // _ARCH_ARM_ configAttribs.PushBack( EGL_DEPTH_SIZE ); configAttribs.PushBack( 24 ); -- 2.7.4