summaryrefslogtreecommitdiff
path: root/src/modules
diff options
context:
space:
mode:
authorCedric BAIL <cedric@osg.samsung.com>2015-04-24 17:04:58 +0200
committerCedric BAIL <cedric@osg.samsung.com>2015-04-25 10:15:13 +0200
commit1b91101966f61077da11c2f9547644465d559da8 (patch)
tree244dc2761878f06ec6aad5bc361977dcabc2fe02 /src/modules
parent054fed5336903bd676bf2242c7c54823af03bd90 (diff)
evas: fix usage of the same ressource in the GL backend with orient.
When we set orient we actually need to return a new image or it will confuse evas a lot.
Diffstat (limited to 'src/modules')
-rw-r--r--src/modules/evas/engines/gl_generic/evas_engine.c16
1 files changed, 14 insertions, 2 deletions
diff --git a/src/modules/evas/engines/gl_generic/evas_engine.c b/src/modules/evas/engines/gl_generic/evas_engine.c
index 6ef0d50..952dee2 100644
--- a/src/modules/evas/engines/gl_generic/evas_engine.c
+++ b/src/modules/evas/engines/gl_generic/evas_engine.c
@@ -899,6 +899,7 @@ eng_image_orient_set(void *data, void *image, Evas_Image_Orient orient)
899{ 899{
900 Render_Engine_GL_Generic *re = data; 900 Render_Engine_GL_Generic *re = data;
901 Evas_GL_Image *im; 901 Evas_GL_Image *im;
902 Evas_GL_Image *im_new;
902 903
903 if (!image) return NULL; 904 if (!image) return NULL;
904 im = image; 905 im = image;
@@ -906,8 +907,19 @@ eng_image_orient_set(void *data, void *image, Evas_Image_Orient orient)
906 907
907 re->window_use(re->software.ob); 908 re->window_use(re->software.ob);
908 909
909 im->orient = orient; 910 evas_gl_common_image_update(im->gc, im);
910 return im; 911
912 im_new = evas_gl_common_image_new(im->gc, im->w, im->h, im->alpha, im->cs.space);
913 if (!im_new) return im;
914
915 *im_new = *im;
916
917 im_new->tex->references++;
918 im_new->tex->pt->references++;
919 im_new->orient = orient;
920
921 evas_gl_common_image_free(im);
922 return im_new;
911} 923}
912 924
913static Evas_Image_Orient 925static Evas_Image_Orient