From: raster Date: Mon, 14 May 2012 06:56:22 +0000 (+0000) Subject: Fix pixman rendering support if you set alpha flag AFTER X-Git-Tag: 2.0_alpha~50^2~147 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=042754b5e0e8955b2e3f91c39c66f16487bdec51;p=framework%2Fuifw%2Fevas.git Fix pixman rendering support if you set alpha flag AFTER setting image size for custom image data. git-svn-id: svn+ssh://svn.enlightenment.org/var/svn/e/trunk/evas@70987 7cbeb6ba-43b4-40fd-8cce-4c39aea84d33 --- diff --git a/ChangeLog b/ChangeLog index f6ddb7a..c9ced49 100644 --- a/ChangeLog +++ b/ChangeLog @@ -731,3 +731,9 @@ * Add CServe2 and image cache2 that makes use of it. Several changes in the buffer and software engines to use the right cache if CServe2 is requested for the application. + +2012-05-14 Carsten Haitzler (The Rasterman) + + * Fix pixman rendering support if you set alpha flag AFTER + setting image size for custom image data. + diff --git a/src/lib/engines/common/evas_image_main.c b/src/lib/engines/common/evas_image_main.c index f8053a8..b6735dc 100644 --- a/src/lib/engines/common/evas_image_main.c +++ b/src/lib/engines/common/evas_image_main.c @@ -777,6 +777,16 @@ evas_common_image_colorspace_dirty(RGBA_Image *im) { im->cs.dirty = 1; evas_common_rgba_image_scalecache_dirty(&im->cache_entry); +#ifdef HAVE_PIXMAN +# ifdef PIXMAN_IMAGE + if (im->pixman.im) + { + pixman_image_unref(im->pixman.im); + im->pixman.im = NULL; + } + _evas_common_rgba_image_post_surface((Image_Entry *)im); +# endif +#endif } EAPI void diff --git a/src/modules/engines/software_generic/evas_engine.c b/src/modules/engines/software_generic/evas_engine.c index 3c7eb8d..a123cd5 100644 --- a/src/modules/engines/software_generic/evas_engine.c +++ b/src/modules/engines/software_generic/evas_engine.c @@ -566,9 +566,8 @@ eng_image_alpha_set(void *data __UNUSED__, void *image, int has_alpha) return im; } im = (RGBA_Image *) evas_cache_image_alone(&im->cache_entry); - evas_common_image_colorspace_dirty(im); - im->cache_entry.flags.alpha = has_alpha ? 1 : 0; + evas_common_image_colorspace_dirty(im); return im; }