evas gl: fix invalid image size. 02/190402/1
authorHermet Park <hermetpark@gmail.com>
Mon, 1 Oct 2018 12:06:36 +0000 (21:06 +0900)
committerHermet Park <hermetpark@gmail.com>
Mon, 1 Oct 2018 12:11:31 +0000 (21:11 +0900)
Summary:
When we reset of texture for a valid object,
this object cache size become -1 x -1 with null texture.

Later, we reset a new texture of the object,
Its texture size could be -1 x -1.
That brings to incorrect result drawing.

Can't see any points of using cache size there.

This bug was introduced by 9e01cf2698d5b24f440d696fd57d469cdc5a6b5f

@fix

Reviewers: #committers, raster

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D7077

Change-Id: I210e31954ce347efa96197370dc63fc51a149f02

src/modules/evas/engines/gl_common/evas_gl_image.c

index 20c6670..4012485 100755 (executable)
@@ -765,12 +765,8 @@ evas_gl_common_image_update(Evas_Engine_GL_Context *gc, Evas_GL_Image *im)
    if (!im->im) return;
 
    ie = &im->im->cache_entry;
-   if (!im->tex)
-     {
-        if (ie->preload) return;
-//        im->w = ie->w;
-//      im->h = ie->h;
-     }
+   if (!im->tex && ie->preload) return;
+
    evas_gl_common_image_alloc_ensure(im);
    // alloc ensure can change im->im, so only get the local variable later.
    ie = &im->im->cache_entry;