summaryrefslogtreecommitdiff
path: root/src/modules/evas/engines/gl_common/evas_gl_texture.c
diff options
context:
space:
mode:
authorOleksandr Shcherbina <o.shcherbina@samsung.com>2015-07-28 22:33:49 +0200
committerCedric BAIL <cedric@osg.samsung.com>2015-07-28 22:33:52 +0200
commit1f758ad96d0bf0b2250da4b8c28f9ecf89bc7ca1 (patch)
tree52cdb2cdbce573aef9f0853c80a2f0d33481b6da /src/modules/evas/engines/gl_common/evas_gl_texture.c
parent7745189b0aa990d58f6f0959fe4d1d4407dc11ac (diff)
evas: fix size of borders in case need generate texture without atlases
Summary: Set size of texture unit without 2 pixels for borders in case use it without atlses. Just one case if texture for 3D use repeat mode and non-normalized tuxture coordinates Reviewers: Hermet, cedric Subscribers: cedric Differential Revision: https://phab.enlightenment.org/D2805 Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
Diffstat (limited to '')
-rw-r--r--src/modules/evas/engines/gl_common/evas_gl_texture.c17
1 files changed, 14 insertions, 3 deletions
diff --git a/src/modules/evas/engines/gl_common/evas_gl_texture.c b/src/modules/evas/engines/gl_common/evas_gl_texture.c
index b54f650842..f6d41dafa3 100644
--- a/src/modules/evas/engines/gl_common/evas_gl_texture.c
+++ b/src/modules/evas/engines/gl_common/evas_gl_texture.c
@@ -526,9 +526,20 @@ evas_gl_common_texture_new(Evas_Engine_GL_Context *gc, RGBA_Image *im, Eina_Bool
526 case EVAS_COLORSPACE_ETC1_ALPHA: 526 case EVAS_COLORSPACE_ETC1_ALPHA:
527 return evas_gl_common_texture_rgb_a_pair_new(gc, im); 527 return evas_gl_common_texture_rgb_a_pair_new(gc, im);
528 default: 528 default:
529 // One pixel gap and two pixels for duplicated borders 529 if (disable_atlas)
530 w = im->cache_entry.w + 3; 530 {
531 h = im->cache_entry.h + 3; 531 /*Just one pixel gap. Generate texture unit without pixels for
532 borders in case using this for evas_canvas3d in repeat mode of the
533 texture unit*/
534 w = im->cache_entry.w + 1;
535 h = im->cache_entry.h + 1;
536 }
537 else
538 {
539 /*One pixel gap and two pixels for duplicated borders*/
540 w = im->cache_entry.w + 3;
541 h = im->cache_entry.h + 3;
542 }
532 break; 543 break;
533 } 544 }
534 545