summaryrefslogtreecommitdiff
path: root/src/modules/evas/engines/gl_common/evas_gl_image.c
diff options
context:
space:
mode:
authorHermet Park <hermetpark@gmail.com>2018-08-30 13:14:13 +0900
committerHermet Park <hermetpark@gmail.com>2018-08-30 13:14:13 +0900
commit43d8c853aad6e2647a231d2e43579073c74d9112 (patch)
treebbdb64febacaec65d9ac1276ff5da450133a837c /src/modules/evas/engines/gl_common/evas_gl_image.c
parentb41d3752bb38abf876d3955162b484c774299009 (diff)
evas gl: skip twice texture upload.
Summary: While debugging a problem, found a hole that upload texture twice unnecessary. Here is the scenario. Set up two objects with same image resource plus both preloading - obj1, obj2; After image preloading, _evas_cache_image_async_end() will be triggered. => ie->flags.update_data = true; then first obj1 is gonna drawing, Since it doesn't have any texture uploaded yet, it will create a texture and upload texture data as well. along with below sequence. => else if (!im->tex && !ie->load_error) After it, second obj2 is gonna drawing. But actually its texture is already readied after obj1, it doesn't need to upload texture agin. But still ie->flag.update_data == true, it will do dumbly. Reviewers: #committers, devilhorns, raster Subscribers: cedric, #reviewers, #committers, zmike Tags: #efl Differential Revision: https://phab.enlightenment.org/D6902
Diffstat (limited to '')
-rw-r--r--src/modules/evas/engines/gl_common/evas_gl_image.c2
1 files changed, 1 insertions, 1 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 b908d044b4..2716f58387 100644
--- a/src/modules/evas/engines/gl_common/evas_gl_image.c
+++ b/src/modules/evas/engines/gl_common/evas_gl_image.c
@@ -921,7 +921,6 @@ evas_gl_common_image_update(Evas_Engine_GL_Context *gc, Evas_GL_Image *im)
921 evas_gl_common_texture_update(im->tex, im->im); 921 evas_gl_common_texture_update(im->tex, im->im);
922 evas_cache_image_unload_data(ie); 922 evas_cache_image_unload_data(ie);
923 } 923 }
924 ie->flags.updated_data = 0;
925 } 924 }
926 else if (!im->tex && !ie->load_error) 925 else if (!im->tex && !ie->load_error)
927 { 926 {
@@ -940,6 +939,7 @@ evas_gl_common_image_update(Evas_Engine_GL_Context *gc, Evas_GL_Image *im)
940 evas_cache_image_unload_data(ie); 939 evas_cache_image_unload_data(ie);
941 } 940 }
942 } 941 }
942 ie->flags.updated_data = EINA_FALSE;
943 im->dirty = 0; 943 im->dirty = 0;
944 break; 944 break;
945 case EVAS_COLORSPACE_ETC1_ALPHA: 945 case EVAS_COLORSPACE_ETC1_ALPHA: