diff options
author | ChunEon Park <hermet@hermet.pe.kr> | 2014-06-25 21:46:49 +0900 |
---|---|---|
committer | ChunEon Park <hermet@hermet.pe.kr> | 2014-06-25 21:50:35 +0900 |
commit | d69e4fbe203d9689fcebc9cd6e3d4e799dd2123e (patch) | |
tree | 9f11b024cdbd4311354b627cf59fed54cac829d0 | |
parent | c23ed65a3c379fed6562872953e82701a4125168 (diff) | |
download | efl-d69e4fbe203d9689fcebc9cd6e3d4e799dd2123e.tar.gz |
evas/gl - fix to render grayscale with transparency format in gl backened.
In case of png, grayscale with transparency format (transparency doesn't mean the png has alpha channel)
gl doesn't prepare that format render.
In this case, set it argb8888 to convert the data in the png loader.
@fix
-rw-r--r-- | src/modules/evas/engines/gl_common/evas_gl_image.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/modules/evas/engines/gl_common/evas_gl_image.c b/src/modules/evas/engines/gl_common/evas_gl_image.c index ac2163b6a1..7de58157ab 100644 --- a/src/modules/evas/engines/gl_common/evas_gl_image.c +++ b/src/modules/evas/engines/gl_common/evas_gl_image.c @@ -221,6 +221,13 @@ _evas_gl_common_image(Evas_Engine_GL_Context *gc, RGBA_Image *im_im, Evas_Image_ // ETC2 is backwards compatible with ETC1 but we prefer ETC2 if (cspace == EVAS_COLORSPACE_ETC1 && gc->shared->info.etc2) cspace = EVAS_COLORSPACE_RGB8_ETC2; + + /* Current GL doesn't support grayscale with transparency + let it convert to argb8888 in loader */ + if ((cspace == EVAS_COLORSPACE_GRY8) && + im_im->cache_entry.flags.alpha) + cspace = EVAS_COLORSPACE_ARGB8888; + im_im->cache_entry.space = cspace; } |