[Evas] texture upload without border when texture offset is zero 78/192278/3
authorSunghyun kim <scholb.kim@samsung.com>
Fri, 2 Nov 2018 02:50:11 +0000 (11:50 +0900)
committerHermet Park <chuneon.park@samsung.com>
Mon, 5 Nov 2018 05:40:09 +0000 (05:40 +0000)
- if application use render texture, it has rendering issue.
- after this fix, texture is uploaded without border when texture offset is zero

Change-Id: Ic5449a5782cf590eec0560111e9047fc39748947

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

index 5094e83..8cfecaf 100755 (executable)
@@ -1262,7 +1262,15 @@ evas_gl_common_texture_upload(Evas_GL_Texture *tex, RGBA_Image *im, unsigned int
      GL_TH(glPixelStorei, GL_UNPACK_ROW_LENGTH, 0);
    GL_TH(glPixelStorei, GL_UNPACK_ALIGNMENT, bytes_count);
 
-   if ((tex->gc->shared->info.tune.atlas.max_memcpy_size > (int)im->cache_entry.w) &&
+
+   if((tex->x == 0) && (tex->y ==0))
+     {
+        _tex_sub_2d(tex->gc, tex->x, tex->y,
+                    im->cache_entry.w, im->cache_entry.h,
+                    fmt, tex->pt->dataformat,
+                    im->image.data);
+     }
+   else if ((tex->gc->shared->info.tune.atlas.max_memcpy_size > (int)im->cache_entry.w) &&
            (tex->gc->shared->info.tune.atlas.max_memcpy_size > (int)im->cache_entry.h))
      {
         int sw, sh, dw, dh;