diff options
author | Jinhyung Jo <jinhyung.jo@samsung.com> | 2016-12-26 14:06:32 +0900 |
---|---|---|
committer | Jinhyung Jo <jinhyung.jo@samsung.com> | 2016-12-26 14:06:48 +0900 |
commit | 43bd93f8c54f96b08570f1f26be9fc73c3b89bd5 (patch) | |
tree | 3b8870ad79b0c16cf290f5581a05b0316972c5f9 | |
parent | 5be1103314628f5dcb6f6f7d4fb20f4dd3ab43a8 (diff) | |
parent | 10cbad9bfe346f80c276180f2fd9f844a8b08916 (diff) | |
download | emulator-yagl-accepted/tizen_3.0.m2_tv.tar.gz emulator-yagl-accepted/tizen_3.0.m2_tv.tar.bz2 emulator-yagl-accepted/tizen_3.0.m2_tv.zip |
Merge branch 'tizen' into tizen_3.0submit/tizen_3.0/20161226.051154submit/tizen_3.0.m2/20170104.093748accepted/tizen/3.0/wearable/20161227.005915accepted/tizen/3.0/tv/20161227.005858accepted/tizen/3.0/mobile/20161227.005840accepted/tizen/3.0/ivi/20161227.005929accepted/tizen/3.0/common/20161227.101852accepted/tizen/3.0.m2/wearable/20170104.100940accepted/tizen/3.0.m2/tv/20170104.100401accepted/tizen/3.0.m2/mobile/20170104.100209tizen_3.0_tvtizen_3.0.m2accepted/tizen_3.0.m2_wearableaccepted/tizen_3.0.m2_tvaccepted/tizen_3.0.m2_mobile
Change-Id: Id7b30cfd9d0e13841b3c299c7803d324acd65824
Signed-off-by: Jinhyung Jo <jinhyung.jo@samsung.com>
-rw-r--r-- | GLES_common/yagl_gles_texture.c | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/GLES_common/yagl_gles_texture.c b/GLES_common/yagl_gles_texture.c index ff5f608..19382f4 100644 --- a/GLES_common/yagl_gles_texture.c +++ b/GLES_common/yagl_gles_texture.c @@ -248,8 +248,18 @@ void yagl_gles_texture_set_image(struct yagl_gles_texture *texture, texture->binding = NULL; } + /* + * FIXME We still need to update the host binding when using external + * textures even if that same image is already set. E.g. consider the bellow + * scenario: + * glBindTexture(GL_TEXTURE_EXTERNAL_OES, tex); + * glBindTexture(GL_TEXTURE_2D, 0); + * glEGLImageTargetTexture2DOES(GL_TEXTURE_EXTERNAL_OES, img); + * External textures are handled as GL_TEXTURE_2D thus the corresponding + * host binding will be zero in this case. + */ if (texture->image == image) { - return; + goto bind; } yagl_gles_image_acquire(image); @@ -263,6 +273,7 @@ void yagl_gles_texture_set_image(struct yagl_gles_texture *texture, texture->global_name = image->tex_global_name; texture->image = image; +bind: yagl_host_glBindTexture(texture->target == GL_TEXTURE_EXTERNAL_OES ? GL_TEXTURE_2D : texture->target, texture->global_name); } |