#define _EVASGL_EXT_BEGIN(name)
#define _EVASGL_EXT_END()
#define _EVASGL_EXT_DRVNAME(name)
+#define _EVASGL_EXT_DRVNAME_PRIVATE(name)
#define _EVASGL_EXT_DRVNAME_DESKTOP(deskname)
#define _EVASGL_EXT_FUNCTION_BEGIN(ret, name, param) \
ret (*gl_ext_sym_##name) param = NULL; \
#undef _EVASGL_EXT_BEGIN
#undef _EVASGL_EXT_END
#undef _EVASGL_EXT_DRVNAME
+#undef _EVASGL_EXT_DRVNAME_PRIVATE
#undef _EVASGL_EXT_DRVNAME_DESKTOP
#undef _EVASGL_EXT_FUNCTION_BEGIN
#undef _EVASGL_EXT_FUNCTION_END
int _gles1_ext_support_##name = 0;
#define _EVASGL_EXT_END()
#define _EVASGL_EXT_DRVNAME(name)
+#define _EVASGL_EXT_DRVNAME_PRIVATE(name) \
+ int _gl_ext_support_func_##name = 0; \
+ int _gles1_ext_support_func_##name = 0;
#define _EVASGL_EXT_DRVNAME_DESKTOP(deskname)
#define _EVASGL_EXT_FUNCTION_BEGIN(ret, name, param)
#define _EVASGL_EXT_FUNCTION_END()
#undef _EVASGL_EXT_BEGIN
#undef _EVASGL_EXT_END
#undef _EVASGL_EXT_DRVNAME
+#undef _EVASGL_EXT_DRVNAME_PRIVATE
#undef _EVASGL_EXT_DRVNAME_DESKTOP
#undef _EVASGL_EXT_FUNCTION_BEGIN
#undef _EVASGL_EXT_FUNCTION_END
#define _EVASGL_EXT_DRVNAME(name) \
if (_EVASGL_EXT_CHECK_SUPPORT(#name)) *ext_support = 1;
+#define _EVASGL_EXT_DRVNAME_PRIVATE(name) \
+ if (_EVASGL_EXT_CHECK_SUPPORT(#name)) { *ext_support = 1; _gl_ext_support_func_##name = 1; }
+
#define _EVASGL_EXT_DRVNAME_DESKTOP(deskname) \
if (_EVASGL_EXT_CHECK_SUPPORT(deskname)) *ext_support = 1;
#undef _EVASGL_EXT_BEGIN
#undef _EVASGL_EXT_END
#undef _EVASGL_EXT_DRVNAME
+#undef _EVASGL_EXT_DRVNAME_PRIVATE
#undef _EVASGL_EXT_DRVNAME_DESKTOP
#undef _EVASGL_EXT_FUNCTION_BEGIN
#undef _EVASGL_EXT_FUNCTION_END
#undef _EVASGL_EXT_FUNCTION_DRVFUNC_PROCADDR
#undef GETPROCADDR
+ /////////////////////////////////////////////////////////////////////////////////////////////////////
+
+ _gl_ext_string[0] = 0x00; //NULL;
+ _gl_ext_string_official[0] = 0x00;
/////////////////////////////////////////////////////////////////////////////////////////////////////
// Extension HEADER
#define _EVASGL_EXT_END()
#define _EVASGL_EXT_CHECK_SUPPORT(name)
#define _EVASGL_EXT_DISCARD_SUPPORT()
+#define _EVASGL_EXT_DRVNAME_PRINT(name) \
+ { \
+ strncat(_gl_ext_string, name" ", MAX_EXTENSION_STRING_BUFFER); \
+ if ((strncmp(name, "GL", 2) == 0) && (strstr(_gl_ext_string_official, name) == NULL)) \
+ strncat(_gl_ext_string_official, name" ", MAX_EXTENSION_STRING_BUFFER); \
+ }
#define _EVASGL_EXT_DRVNAME(name) \
- if (_curext_supported) \
- { \
- strncat(_gl_ext_string, #name" ", MAX_EXTENSION_STRING_BUFFER); \
- strncat(_gl_ext_string_official, #name" ", MAX_EXTENSION_STRING_BUFFER); \
- }
+ if (_curext_supported) \
+ _EVASGL_EXT_DRVNAME_PRINT(#name)
+#define _EVASGL_EXT_DRVNAME_PRIVATE(name) \
+ if (_curext_supported && _gl_ext_support_func_##name) \
+ _EVASGL_EXT_DRVNAME_PRINT(#name)
#define _EVASGL_EXT_DRVNAME_DESKTOP(deskname)
#define _EVASGL_EXT_FUNCTION_BEGIN(ret, name, param)
#define _EVASGL_EXT_FUNCTION_END()
#undef _EVASGL_EXT_DISCARD_SUPPORT
#undef _EVASGL_EXT_BEGIN
#undef _EVASGL_EXT_END
+#undef _EVASGL_EXT_DRVNAME_PRINT
#undef _EVASGL_EXT_DRVNAME
#undef _EVASGL_EXT_DRVNAME_DESKTOP
+#undef _EVASGL_EXT_DRVNAME_PRIVATE
#undef _EVASGL_EXT_FUNCTION_BEGIN
#undef _EVASGL_EXT_FUNCTION_END
#undef _EVASGL_EXT_FUNCTION_DISABLE_FOR_GLES1_BEGIN
#define _EVASGL_EXT_END() \
}
#define _EVASGL_EXT_DRVNAME(name)
+#define _EVASGL_EXT_DRVNAME_PRIVATE(name)
#define _EVASGL_EXT_DRVNAME_DESKTOP(deskname)
#define _EVASGL_EXT_FUNCTION_BEGIN(ret, name, param) \
ORD(name);
#undef _EVASGL_EXT_BEGIN
#undef _EVASGL_EXT_END
#undef _EVASGL_EXT_DRVNAME
+#undef _EVASGL_EXT_DRVNAME_PRIVATE
#undef _EVASGL_EXT_DRVNAME_DESKTOP
#undef _EVASGL_EXT_FUNCTION_BEGIN
#undef _EVASGL_EXT_FUNCTION_END
#define _EVASGL_EXT_DRVNAME(name) \
if (_EVASGL_EXT_CHECK_SUPPORT(#name)) *ext_support = 1;
+#define _EVASGL_EXT_DRVNAME_PRIVATE(name) \
+ if (_EVASGL_EXT_CHECK_SUPPORT(#name)) { *ext_support = 1; _gles1_ext_support_func_##name = 1; }
#define _EVASGL_EXT_DRVNAME_DESKTOP(deskname) \
if (_EVASGL_EXT_CHECK_SUPPORT(deskname)) *ext_support = 1;
#undef _EVASGL_EXT_BEGIN
#undef _EVASGL_EXT_END
#undef _EVASGL_EXT_DRVNAME
+#undef _EVASGL_EXT_DRVNAME_PRIVATE
#undef _EVASGL_EXT_DRVNAME_DESKTOP
#undef _EVASGL_EXT_FUNCTION_BEGIN
#undef _EVASGL_EXT_FUNCTION_END
#define _EVASGL_EXT_END()
#define _EVASGL_EXT_CHECK_SUPPORT(name)
#define _EVASGL_EXT_DISCARD_SUPPORT()
-#define _EVASGL_EXT_DRVNAME(name) if (_curext_supported) strcat(_gles1_ext_string, #name" ");
+#define _EVASGL_EXT_DRVNAME_PRINT(name) \
+ { \
+ if ((strncmp(name, "GL", 2) == 0) && (strstr(_gles1_ext_string, name) == NULL)) \
+ strcat(_gles1_ext_string, name" "); \
+ }
+#define _EVASGL_EXT_DRVNAME(name) \
+ if (_curext_supported) \
+ _EVASGL_EXT_DRVNAME_PRINT(#name)
+#define _EVASGL_EXT_DRVNAME_PRIVATE(name) \
+ if (_curext_supported && _gles1_ext_support_func_##name) \
+ _EVASGL_EXT_DRVNAME_PRINT(#name)
#define _EVASGL_EXT_DRVNAME_DESKTOP(deskname)
#define _EVASGL_EXT_FUNCTION_BEGIN(ret, name, param)
#define _EVASGL_EXT_FUNCTION_END()
#undef _EVASGL_EXT_DISCARD_SUPPORT
#undef _EVASGL_EXT_BEGIN
#undef _EVASGL_EXT_END
+#undef _EVASGL_EXT_DRVNAME_PRINT
#undef _EVASGL_EXT_DRVNAME
+#undef _EVASGL_EXT_DRVNAME_PRIVATE
#undef _EVASGL_EXT_DRVNAME_DESKTOP
#undef _EVASGL_EXT_FUNCTION_BEGIN
#undef _EVASGL_EXT_FUNCTION_END
#define _EVASGL_EXT_END() \
}
#define _EVASGL_EXT_DRVNAME(name)
+#define _EVASGL_EXT_DRVNAME_PRIVATE(name)
#define _EVASGL_EXT_DRVNAME_DESKTOP(deskname)
#define _EVASGL_EXT_FUNCTION_BEGIN(ret, name, param) \
ORD(name);
#undef _EVASGL_EXT_BEGIN
#undef _EVASGL_EXT_END
#undef _EVASGL_EXT_DRVNAME
+#undef _EVASGL_EXT_DRVNAME_PRIVATE
#undef _EVASGL_EXT_DRVNAME_DESKTOP
#undef _EVASGL_EXT_FUNCTION_BEGIN
#undef _EVASGL_EXT_FUNCTION_END
// Driver extensions to wrap (name : SPEC extension name)
#define _EVASGL_EXT_DRVNAME(name)
+#define _EVASGL_EXT_DRVNAME_PRIVATE(name)
#define _EVASGL_EXT_DRVNAME_DESKTOP(deskname)
// These functions will be exported to 'EVAS extension function'.
#endif
//////////////////////////////////////////////////////////////////////////////////////////////////
+#ifndef _EVASGL_EXT_DRVNAME_PRIVATE
+#define _EVASGL_EXT_DRVNAME_PRIVATE(name) _EVASGL_EXT_DRVNAME(name)
+#define _EVASGL_EXT_DRVNAME_PRIVATE_DEFINED
+#endif
+
#ifndef _EVASGL_EXT_FUNCTION_PRIVATE_BEGIN
#define _EVASGL_EXT_FUNCTION_PRIVATE_BEGIN(ret, name, param) _EVASGL_EXT_FUNCTION_BEGIN(ret, name, param)
#define _EVASGL_EXT_FUNCTION_PRIVATE_BEGIN_DEFINED
_EVASGL_EXT_END()
_EVASGL_EXT_BEGIN(multisampled_render_to_texture)
- _EVASGL_EXT_DRVNAME(GL_IMG_multisampled_render_to_texture)
- _EVASGL_EXT_DRVNAME(GL_EXT_multisampled_render_to_texture)
+ _EVASGL_EXT_DRVNAME_PRIVATE(GL_IMG_multisampled_render_to_texture)
+ _EVASGL_EXT_DRVNAME_PRIVATE(GL_EXT_multisampled_render_to_texture)
_EVASGL_EXT_FUNCTION_PRIVATE_BEGIN(void, glRenderbufferStorageMultisample, (GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height))
_EVASGL_EXT_FUNCTION_DRVFUNC_PROCADDR("glRenderbufferStorageMultisample")
// ----------------------------------------------------------
_EVASGL_EXT_BEGIN(framebuffer_blit)
-_EVASGL_EXT_DRVNAME(GL_NV_framebuffer_blit)
-_EVASGL_EXT_DRVNAME(GL_ANGLE_framebuffer_blit)
+_EVASGL_EXT_DRVNAME_PRIVATE(GL_NV_framebuffer_blit)
+_EVASGL_EXT_DRVNAME_PRIVATE(GL_ANGLE_framebuffer_blit)
_EVASGL_EXT_FUNCTION_WHITELIST("glBlitFramebuffer")
_EVASGL_EXT_FUNCTION_WHITELIST("glBlitFramebufferNV")
_EVASGL_EXT_BEGIN(EGL_KHR_fence_sync)
/* 3 aliasses for EGL_KHR_fence_sync */
- _EVASGL_EXT_DRVNAME(EGL_KHR_fence_sync)
- _EVASGL_EXT_DRVNAME(GL_OES_EGL_sync)
- _EVASGL_EXT_DRVNAME(VG_KHR_EGL_sync)
+ _EVASGL_EXT_DRVNAME_PRIVATE(EGL_KHR_fence_sync)
+ _EVASGL_EXT_DRVNAME_PRIVATE(GL_OES_EGL_sync)
+ _EVASGL_EXT_DRVNAME_PRIVATE(VG_KHR_EGL_sync)
_EVASGL_EXT_FUNCTION_PRIVATE_BEGIN(void *, eglCreateSyncKHR, (EGLDisplay dpy, EGLenum type, const EGLint *attrib_list))
_EVASGL_EXT_FUNCTION_DRVFUNC_PROCADDR("eglCreateSyncKHR")
#undef _EVASGL_EXT_FUNCTION_PRIVATE_END_DEFINED
#endif
+#ifdef _EVASGL_EXT_DRVNAME_PRIVATE_DEFINED
+#undef _EVASGL_EXT_DRVNAME_PRIVATE
+#undef _EVASGL_EXT_DRVNAME_PRIVATE_DEFINED
+#endif
+
#ifdef _EVASGL_EXT_USE_DEFAULT_DEFINE
#undef _EVASGL_EXT_CHECK_SUPPORT
#undef _EVASGL_EXT_DISCARD_SUPPORT
#undef _EVASGL_EXT_BEGIN
#undef _EVASGL_EXT_END
#undef _EVASGL_EXT_DRVNAME
+#undef _EVASGL_EXT_DRVNAME_PRIVATE
#undef _EVASGL_EXT_FUNCTION_BEGIN
#undef _EVASGL_EXT_FUNCTION_END
#undef _EVASGL_EXT_FUNCTION_PRIVATE_BEGIN