From fef73012cfe59525b9697ca814bc72c4fdb8e803 Mon Sep 17 00:00:00 2001 From: "jutty.lee" Date: Fri, 28 Oct 2016 11:31:27 +0900 Subject: evas/gl_common: Move inline function(_tex_sub_2d(), _comp_text_sub_2d()) Move inline function _tex_sub_2d(), _comp_tex_sub_2d() from evas_gl_common.h to evas_gl_texture.c --- src/modules/evas/engines/gl_common/evas_gl_common.h | 20 -------------------- src/modules/evas/engines/gl_common/evas_gl_texture.c | 16 ++++++++++++++++ 2 files changed, 16 insertions(+), 20 deletions(-) diff --git a/src/modules/evas/engines/gl_common/evas_gl_common.h b/src/modules/evas/engines/gl_common/evas_gl_common.h index a77a2a5032..1c2fa65419 100644 --- a/src/modules/evas/engines/gl_common/evas_gl_common.h +++ b/src/modules/evas/engines/gl_common/evas_gl_common.h @@ -893,26 +893,6 @@ __evas_gl_errdyn(int err, const char *file, const char *func, int line, const ch Eina_Bool evas_gl_common_module_open(void); void evas_gl_common_module_close(void); -#ifndef EVAS_GL_NO_HEADERS - -static inline void -_tex_sub_2d(Evas_Engine_GL_Context *gc, int x, int y, int w, int h, int fmt, int type, const void *pix) -{ - if ((w > gc->shared->info.max_texture_size) || - (h > gc->shared->info.max_texture_size)) return; - glTexSubImage2D(GL_TEXTURE_2D, 0, x, y, w, h, fmt, type, pix); -} - -static inline void -_comp_tex_sub_2d(Evas_Engine_GL_Context *gc, int x, int y, int w, int h, int fmt, int imgsize, const void *pix) -{ - if ((w > gc->shared->info.max_texture_size) || - (h > gc->shared->info.max_texture_size)) return; - glCompressedTexSubImage2D(GL_TEXTURE_2D, 0, x, y, w, h, fmt, imgsize, pix); -} - -#endif - #include "evas_gl_3d_common.h" #undef EAPI 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 903a60b214..ac0b162cfd 100644 --- a/src/modules/evas/engines/gl_common/evas_gl_texture.c +++ b/src/modules/evas/engines/gl_common/evas_gl_texture.c @@ -97,6 +97,22 @@ static const struct { { MATCH_ANY, MATCH_ANY, EVAS_COLORSPACE_RGBA_S3TC_DXT5, &s3tc_rgba_dxt45_fmt, &s3tc_rgba_dxt45_fmt } }; +static void +_tex_sub_2d(Evas_Engine_GL_Context *gc, int x, int y, int w, int h, int fmt, int type, const void *pix) +{ + if ((w > gc->shared->info.max_texture_size) || + (h > gc->shared->info.max_texture_size)) return; + glTexSubImage2D(GL_TEXTURE_2D, 0, x, y, w, h, fmt, type, pix); +} + +static void +_comp_tex_sub_2d(Evas_Engine_GL_Context *gc, int x, int y, int w, int h, int fmt, int imgsize, const void *pix) +{ + if ((w > gc->shared->info.max_texture_size) || + (h > gc->shared->info.max_texture_size)) return; + glCompressedTexSubImage2D(GL_TEXTURE_2D, 0, x, y, w, h, fmt, imgsize, pix); +} + #ifdef GL_TEXTURE_INTERNAL_FORMAT # ifndef GL_GLES static const GLenum matching_rgb[] = { GL_RGB4, GL_RGB8, GL_RGB12, GL_RGB16, 0x0 }; -- cgit v1.2.1