int trace_ctx_force_flag = 0;
int trace_state_flag = 0;
int debug_nofp = 0;
+FILE *trace_fp = NULL;
// Symbol definition for real
#define _COREGL_SYMBOL(IS_EXTENSION, RET_TYPE, FUNC_NAME, PARAM_LIST) RET_TYPE (*_sym_##FUNC_NAME) PARAM_LIST;
tstate = (GLThreadState *)calloc(1, sizeof(GLThreadState));
tstate->thread_id = get_current_thread();
- tstate->binded_api = EGL_NONE;
+ tstate->binded_api = EGL_OPENGL_ES_API;
set_current_thread_state(&ctx_list_access_mutex, tstate);
break;
}
+ {
+ const char *output_file = NULL;
+ output_file = get_env_setting("COREGL_LOG_FILE");
+ if (strlen(output_file) > 0)
+ {
+ trace_fp = fopen(output_file, "w");
+ }
+ if (trace_fp == NULL)
+ trace_fp = stderr;
+ }
+
#ifdef COREGL_TRACE_APICALL_INFO
trace_api_flag = atoi(get_env_setting("COREGL_TRACE_API"));
#endif
tv_last = tv_now;
}
- LOG("\n");
- LOG("\E[0;40;34m========================================================================================================================\E[0m\n");
- LOG("\E[0;32;1m State info \E[1;37;1m: GlueCTX = %p\E[0m\n", ctx);
- LOG("\E[0;40;34m========================================================================================================================\E[0m\n");
+ TRACE("\n");
+ TRACE("\E[0;40;34m========================================================================================================================\E[0m\n");
+ TRACE("\E[0;32;1m State info \E[1;37;1m: GlueCTX = %p\E[0m\n", ctx);
+ TRACE("\E[0;40;34m========================================================================================================================\E[0m\n");
#define PRINTF_CHAR_GLenum "%10d"
#define PRINTF_CHAR_GLboolean "%10d"
TYPE valuedata[SIZE]; \
TYPE *value = NULL; \
value = valuedata; GET_STMT; value = valuedata; \
- LOG("\E[0;37;1m %-30.30s : (\E[0m ", #NAME); \
+ TRACE("\E[0;37;1m %-30.30s : (\E[0m ", #NAME); \
for (int i = 0; i < SIZE; i++) \
{ \
if (i > 0) { \
if (i % 4 == 0) \
- LOG("\n %-30.30s ", "");\
+ TRACE("\n %-30.30s ", "");\
else \
- LOG(", "); \
+ TRACE(", "); \
} \
- LOG(PRINTF_CHAR(TYPE), ctx->NAME[i]); \
- LOG("["PRINTF_CHAR(TYPE)"]", value[i]); \
+ TRACE(PRINTF_CHAR(TYPE), ctx->NAME[i]); \
+ TRACE("["PRINTF_CHAR(TYPE)"]", value[i]); \
} \
- LOG(" \E[0;37;1m)\E[0m\n"); \
+ TRACE(" \E[0;37;1m)\E[0m\n"); \
}
# include "coregl_fastpath_state.h"
#undef GLUE_STATE
#undef INITIAL_CTX
- LOG("\E[0;40;34m========================================================================================================================\E[0m\n");
- LOG("\n");
+ TRACE("\E[0;40;34m========================================================================================================================\E[0m\n");
+ TRACE("\n");
+
+ TRACE_END();
finish:
return;
#include <stdlib.h>
#include <string.h>
#include <sys/time.h>
+#include <execinfo.h>
#ifdef COREGL_TRACE_CONTEXT_INFO
tstate = get_current_thread_state();
- LOG("\n");
- LOG("\E[40;34m========================================================================================================================\E[0m\n");
- LOG("\E[40;32;1m Context info \E[1;37;1m: %s\E[0m\n", ment);
- LOG("\E[40;34m========================================================================================================================\E[0m\n");
+ TRACE("\n");
+ TRACE("\E[40;34m========================================================================================================================\E[0m\n");
+ TRACE("\E[40;32;1m Context info \E[1;37;1m: %s\E[0m\n", ment);
+ TRACE("\E[40;34m========================================================================================================================\E[0m\n");
// Thread State List
{
GLThreadState *cur_tstate = (GLThreadState *)current->value;
- LOG(" %c Thread [%12d] : Surf <D=[%12p] R=[%12p]>",
- (tstate == cur_tstate) ? '*' : ' ',
- cur_tstate->thread_id,
- cur_tstate->rsurf_draw,
- cur_tstate->rsurf_read);
+ TRACE(" %c Thread [%12d] : Surf <D=[%12p] R=[%12p]>",
+ (tstate == cur_tstate) ? '*' : ' ',
+ cur_tstate->thread_id,
+ cur_tstate->rsurf_draw,
+ cur_tstate->rsurf_read);
if (cur_tstate->cstate != NULL)
{
- LOG(" GlueCTX=[%12p] RealCTX=[%12p]\E[0m\n",
- cur_tstate->cstate->data,
- cur_tstate->cstate);
+ TRACE(" GlueCTX=[%12p] RealCTX=[%12p]\E[0m\n",
+ cur_tstate->cstate->data,
+ cur_tstate->cstate);
}
else
{
- LOG(" (NOT BINDED TO THREAD)\E[0m\n");
+ TRACE(" (NOT BINDED TO THREAD)\E[0m\n");
}
// Binded Context State List
if (cur_tstate->cstate == cur_cstate)
{
- LOG(" -> RealCTX [%12p] : EGLDPY=[%12p] EGLCTX=[%12p] <[%2d] GlueCTXs>\E[0m\n",
- cur_cstate,
- cur_cstate->rdpy,
- cur_cstate->rctx,
- cur_cstate->ref_count);
+ TRACE(" -> RealCTX [%12p] : EGLDPY=[%12p] EGLCTX=[%12p] <[%2d] GlueCTXs>\E[0m\n",
+ cur_cstate,
+ cur_cstate->rdpy,
+ cur_cstate->rctx,
+ cur_cstate->ref_count);
// Binded Glue Context List
{
if (cur_gctx->cstate == cur_cstate)
{
- LOG(" -%c GlueCTX [%12p] : EGLDPY=[%12p] TID=[%12d] <MC count [%10d]>",
- (cur_cstate->data == cur_gctx) ? '>' : '-',
- cur_gctx,
- cur_gctx->rdpy,
- cur_gctx->thread_id,
- cur_gctx->used_count);
-
- LOG(" <Ref [%2d]>\E[0m\n", cur_gctx->ref_count);
+ TRACE(" -%c GlueCTX [%12p] : EGLDPY=[%12p] TID=[%12d] <MC count [%10d]>",
+ (cur_cstate->data == cur_gctx) ? '>' : '-',
+ cur_gctx,
+ cur_gctx->rdpy,
+ cur_gctx->thread_id,
+ cur_gctx->used_count);
+
+ TRACE(" <Ref [%2d]>\E[0m\n", cur_gctx->ref_count);
}
current = current->next;
}
}
- LOG("\E[40;33m........................................................................................................................\E[0m\n");
+ TRACE("\E[40;33m........................................................................................................................\E[0m\n");
// Not-binded Context State List
{
if (isbinded == 0)
{
- LOG(" RealCTX [%12p] : EGLDPY=[%12p] EGLCTX=[%12p] <[%2d] GlueCTXs>\E[0m\n",
- cur_cstate,
- cur_cstate->rdpy,
- cur_cstate->rctx,
- cur_cstate->ref_count);
+ TRACE(" RealCTX [%12p] : EGLDPY=[%12p] EGLCTX=[%12p] <[%2d] GlueCTXs>\E[0m\n",
+ cur_cstate,
+ cur_cstate->rdpy,
+ cur_cstate->rctx,
+ cur_cstate->ref_count);
// Binded Glue Context List
{
if (cur_gctx->cstate == cur_cstate)
{
- LOG(" -%c GlueCTX [%12p] : EGLDPY=[%12p] TID=[%12d] <MC count [%10d]>",
- (cur_cstate->data == cur_gctx) ? '>' : '-',
- cur_gctx,
- cur_gctx->rdpy,
- cur_gctx->thread_id,
- cur_gctx->used_count);
-
- LOG(" <Ref [%2d]>\E[0m\n", cur_gctx->ref_count);
+ TRACE(" -%c GlueCTX [%12p] : EGLDPY=[%12p] TID=[%12d] <MC count [%10d]>",
+ (cur_cstate->data == cur_gctx) ? '>' : '-',
+ cur_gctx,
+ cur_gctx->rdpy,
+ cur_gctx->thread_id,
+ cur_gctx->used_count);
+
+ TRACE(" <Ref [%2d]>\E[0m\n", cur_gctx->ref_count);
}
current = current->next;
}
- LOG("\E[40;33m........................................................................................................................\E[0m\n");
+ TRACE("\E[40;33m........................................................................................................................\E[0m\n");
// Not-binded Glue Context List
{
if (cur_gctx->cstate == NULL)
{
- LOG(" GlueCTX [%12p] : EGLDPY=[%12p] TID=[%12d] <MC count [%10d]>",
- cur_gctx,
- cur_gctx->rdpy,
- cur_gctx->thread_id,
- cur_gctx->used_count);
+ TRACE(" GlueCTX [%12p] : EGLDPY=[%12p] TID=[%12d] <MC count [%10d]>",
+ cur_gctx,
+ cur_gctx->rdpy,
+ cur_gctx->thread_id,
+ cur_gctx->used_count);
- LOG(" <Ref [%2d]>\E[0m\n", cur_gctx->ref_count);
+ TRACE(" <Ref [%2d]>\E[0m\n", cur_gctx->ref_count);
}
current = current->next;
}
}
- LOG("\E[40;34m========================================================================================================================\E[0m\n");
- LOG("\n");
+ TRACE("\E[40;34m========================================================================================================================\E[0m\n");
+ TRACE("\n");
+
+ TRACE_END();
goto finish;
GLThreadState *tstate = NULL;
_COREGL_FAST_FUNC_BEGIN();
- if (api_opt == COREGL_UNKNOWN_PATH) goto finish;
+ if (api_opt == COREGL_UNKNOWN_PATH)
+ {
+ ERR("\E[0;31;1mERROR : Invalid library link! (CoreGL path option is invalid)\E[0m\n");
+ goto finish;
+ }
ret = _sym_eglBindAPI(api);
GLThreadState *tstate = NULL;
_COREGL_FAST_FUNC_BEGIN();
- if (api_opt == COREGL_UNKNOWN_PATH) goto finish;
+ if (api_opt == COREGL_UNKNOWN_PATH)
+ {
+ ERR("\E[0;31;1mERROR : Invalid library link! (CoreGL path option is invalid)\E[0m\n");
+ goto finish;
+ }
ret = _sym_eglQueryAPI();
fpgl_eglCreateContext(EGLDisplay dpy, EGLConfig config, EGLContext share_context, const EGLint* attrib_list)
{
GLGlueContext *gctx = NULL;
+ GLThreadState *tstate = NULL;
GLContextState *cstate = NULL;
GLContextState *cstate_new = NULL;
GL_Shared_Object_State *sostate_new = NULL;
EGL_packed_option *real_ctx_option = NULL;
EGL_packed_sharable_option *real_ctx_sharable_option = NULL;
+ // Special eject condition for binding API
+ tstate = get_current_thread_state();
+ if (tstate != NULL && tstate->binded_api != EGL_OPENGL_ES_API)
+ {
+ return _sym_eglCreateContext(dpy, config, share_context, attrib_list);
+ }
+
_COREGL_FAST_FUNC_BEGIN();
real_ctx_option = (EGL_packed_option *)calloc(1, sizeof(EGL_packed_option));
gctx = (GLGlueContext *)ctx;
- if (gctx != NULL)
+ if (gctx != NULL && gctx != EGL_NO_CONTEXT)
{
GLContextState *cstate = NULL;
+
if (gctx->magic != MAGIC_GLFAST)
{
- ERR("Magic Check Failed!!!\n");
- ret = EGL_FALSE;
+ ret = _sym_eglDestroyContext(dpy, ctx);
goto finish;
}
+
cstate = gctx->cstate;
AST(cstate != NULL);
GLGlueContext *gctx = NULL;
gctx = (GLGlueContext *)ctx;
- AST(gctx->cstate != NULL);
- real_ctx = gctx->cstate->rctx;
+ if (gctx->magic != MAGIC_GLFAST)
+ {
+ real_ctx = ctx;
+ }
+ else
+ {
+ AST(gctx->cstate != NULL);
+ real_ctx = gctx->cstate->rctx;
+ }
}
_COREGL_FAST_FUNC_SYMCALL_BEGIN();
{
EGLBoolean ret = EGL_FALSE;
EGLDisplay dpy = EGL_NO_DISPLAY;
+ GLThreadState *tstate = NULL;
+
+ tstate = get_current_thread_state();
+
+ // Special eject condition for binding API
+ if (tstate != NULL && tstate->binded_api != EGL_OPENGL_ES_API)
+ {
+ return _sym_eglReleaseThread();
+ }
_COREGL_FAST_FUNC_BEGIN();
GLThreadState *tstate = NULL;
GLContextState *cstate = NULL;
+ tstate = get_current_thread_state();
+
+ // Special eject condition for binding API
+ if (tstate != NULL && tstate->binded_api != EGL_OPENGL_ES_API)
+ {
+ return _sym_eglMakeCurrent(dpy, draw, read, ctx);
+ }
+
_COREGL_FAST_FUNC_BEGIN();
gctx = (GLGlueContext *)ctx;
- tstate = get_current_thread_state();
if (tstate == NULL)
{
AST(init_new_thread_state() == 1);
// Setup initial Viewport & Scissor
if (gctx->surface_attached == 0 && draw != EGL_NO_SURFACE)
{
- EGLint width;
- EGLint height;
- _sym_eglQuerySurface(dpy, draw, EGL_WIDTH, &width);
- _sym_eglQuerySurface(dpy, draw, EGL_HEIGHT, &height);
+ EGLint box_buffer[4];
+ EGLint width = 0;
+ EGLint height = 0;
+
+ _sym_glGetIntegerv(GL_VIEWPORT, box_buffer);
+ width = box_buffer[2];
+ height = box_buffer[3];
gctx->_clear_flag1 |= FLAG_BIT_0;
gctx->gl_viewport[0] = 0;
gctx->gl_viewport[2] = width;
gctx->gl_viewport[3] = height;
+ _sym_glGetIntegerv(GL_SCISSOR_BOX, box_buffer);
+ width = box_buffer[2];
+ height = box_buffer[3];
+
gctx->_misc_flag2 |= FLAG_BIT_0;
gctx->gl_scissor_box[0] = 0;
gctx->gl_scissor_box[1] = 0;
GLGlueContext *ret = NULL;
GLThreadState *tstate = NULL;
- _COREGL_FAST_FUNC_BEGIN();
-
tstate = get_current_thread_state();
+ // Special eject condition for binding API
+ if (tstate != NULL && tstate->binded_api != EGL_OPENGL_ES_API)
+ {
+ return _sym_eglGetCurrentContext();
+ }
+
+ _COREGL_FAST_FUNC_BEGIN();
+
if (tstate != NULL)
{
if (tstate->cstate != NULL)
{
ret = (GLGlueContext *)tstate->cstate->data;
+ AST(ret->magic == MAGIC_GLFAST);
}
}
goto finish;
EGLSurface ret = EGL_NO_SURFACE;
GLThreadState *tstate = NULL;
+ tstate = get_current_thread_state();
+
+ // Special eject condition for binding API
+ if (tstate != NULL && tstate->binded_api != EGL_OPENGL_ES_API)
+ {
+ return _sym_eglGetCurrentSurface(readdraw);
+ }
+
_COREGL_FAST_FUNC_BEGIN();
tstate = get_current_thread_state();
# define LOG(...) \
fprintf(stderr, __VA_ARGS__)
+# define TRACE(...) \
+ fprintf(trace_fp, __VA_ARGS__)
+
+# define TRACE_END() \
+ fflush(trace_fp)
+
#ifdef COREGL_DEBUG
# define AST(expr) \
if (!(expr)) { fprintf(stderr, "\E[0;31;1m%s(%d) error. '"#expr"'\E[0m\n", __func__, __LINE__); }
#define _COREGL_WRAP_FUNC_BEGIN() \
static void *trace_hint = NULL; \
- trace_hint = _COREGL_TRACE_API_BEGIN(__func__, trace_hint, 1);
+ if (trace_api_flag == 1) \
+ trace_hint = _COREGL_TRACE_API_BEGIN(__func__, trace_hint, 1);
#define _COREGL_WRAP_FUNC_END() \
- _COREGL_TRACE_API_END(__func__, trace_hint, 1);
+ if (trace_api_flag == 1) \
+ _COREGL_TRACE_API_END(__func__, trace_hint, 1);
typedef enum _CoreGL_Opt_Flag
{
extern int trace_ctx_force_flag;
extern int trace_state_flag;
extern int debug_nofp;
+extern FILE *trace_fp;
// Environment functions
extern const char *get_env_setting(const char *name);
GLThreadState *tstate = NULL;
struct timeval elapsed_time = TIMEVAL_INIT;
- ftd = (Trace_Data *)hint;
-
AST(gettimeofday(&t, NULL) == 0);
+ ftd = (Trace_Data *)hint;
+
if (ftd == NULL)
{
tstate = get_current_thread_state();
}
- LOG("\n");
- LOG("\E[40;34m========================================================================================================================\E[0m\n");
- LOG("\E[40;32;1m API call info \E[1;37;1m: Thread ID = %d [Swaps per Second(P) = %7.2f]\E[0m\n", tstate->thread_id, swaps_per_sec);
- LOG("\E[40;34m========================================================================================================================\E[0m\n");
+ TRACE("\n");
+ TRACE("\E[40;34m========================================================================================================================\E[0m\n");
+ TRACE("\E[40;32;1m API call info \E[1;37;1m: Thread ID = %d [Swaps per Second(P) = %7.2f]\E[0m\n", tstate->thread_id, swaps_per_sec);
+ TRACE("\E[40;34m========================================================================================================================\E[0m\n");
// highlighted
for (i = 0; i < MAX_TRACE_TABLE_SIZE; i++)
if (elapsed_time_per_call_period >= 0.01 || current->call_count - current->last_call_count > 1000)
{
- LOG("\E[40;37;1m %-42.42s : %10d call(s), %10.2f ms, %9.3f ms/API, %9.3f ms/API(P) \E[0m\n",
- current->name, current->call_count, elapsed_time, elapsed_time_per_call, elapsed_time_per_call_period);
+ TRACE("\E[40;37;1m %-42.42s : %10d call(s), %10.2f ms, %9.3f ms/API, %9.3f ms/API(P) \E[0m\n",
+ current->name, current->call_count, elapsed_time, elapsed_time_per_call, elapsed_time_per_call_period);
current->traced = 1;
}
}
{
int fp_env = 0;
fp_env = atoi(get_env_setting("COREGL_TRACE_API_ALL"));
- if (fp_env == 0)
+ if (fp_env == 1)
{
// other
for (i = 0; i < MAX_TRACE_TABLE_SIZE; i++)
double elapsed_time = _get_timeval(current->elapsed_time);
double elapsed_time_per_call = elapsed_time / current->call_count;
- LOG(" %-42.42s : %10d call(s), %10.2f ms, %9.3f ms/API\n",
- current->name, current->call_count, elapsed_time, elapsed_time_per_call);
+ TRACE(" %-42.42s : %10d call(s), %10.2f ms, %9.3f ms/API\n",
+ current->name, current->call_count, elapsed_time, elapsed_time_per_call);
}
current = current->next;
}
}
}
- LOG("\E[40;34m========================================================================================================================\E[0m\n");
+ TRACE("\E[40;34m========================================================================================================================\E[0m\n");
- LOG("\E[40;36;1m %-42.42s : %13.2f ms[%6.2f%%], %13.2f ms(P)[%6.2f%%]\E[0m\n",
- "TOTAL elapsed Time",
- total_elapsed_time,
- 100.0,
- total_elapsed_time_period,
- 100.0);
+ TRACE("\E[40;36;1m %-42.42s : %13.2f ms[%6.2f%%], %13.2f ms(P)[%6.2f%%]\E[0m\n",
+ "TOTAL elapsed Time",
+ total_elapsed_time,
+ 100.0,
+ total_elapsed_time_period,
+ 100.0);
- LOG("\E[40;36;1m %-42.42s : %13.2f ms[%6.2f%%], %13.2f ms(P)[%6.2f%%]\E[0m\n",
- "OpenGL elapsed Time",
- total_opengl_elapsed_time,
- total_opengl_elapsed_time * 100.0 / total_elapsed_time,
- total_opengl_elapsed_time_period,
- total_opengl_elapsed_time_period * 100.0 / total_elapsed_time_period);
+ TRACE("\E[40;36;1m %-42.42s : %13.2f ms[%6.2f%%], %13.2f ms(P)[%6.2f%%]\E[0m\n",
+ "OpenGL elapsed Time",
+ total_opengl_elapsed_time,
+ total_opengl_elapsed_time * 100.0 / total_elapsed_time,
+ total_opengl_elapsed_time_period,
+ total_opengl_elapsed_time_period * 100.0 / total_elapsed_time_period);
- LOG("\E[40;36;1m %-42.42s : %13.2f ms[%6.2f%%], %13.2f ms(P)[%6.2f%%]\E[0m\n",
- "Out of OpenGL elapsed time",
- total_other_elapsed_time,
- total_other_elapsed_time * 100.0 / total_elapsed_time,
- total_other_elapsed_time_period,
- total_other_elapsed_time_period * 100.0 / total_elapsed_time_period);
+ TRACE("\E[40;36;1m %-42.42s : %13.2f ms[%6.2f%%], %13.2f ms(P)[%6.2f%%]\E[0m\n",
+ "Out of OpenGL elapsed time",
+ total_other_elapsed_time,
+ total_other_elapsed_time * 100.0 / total_elapsed_time,
+ total_other_elapsed_time_period,
+ total_other_elapsed_time_period * 100.0 / total_elapsed_time_period);
- LOG("\E[40;36;1m %-42.42s : %13.2f ms[%6.2f%%], %13.2f ms(P)[%6.2f%%]\E[0m\n",
- "CoreGL API tracing overhead",
- total_elapsed_time - total_opengl_elapsed_time - total_other_elapsed_time,
- (total_elapsed_time - total_opengl_elapsed_time - total_other_elapsed_time) * 100.0 / total_elapsed_time,
- total_elapsed_time_period - total_opengl_elapsed_time_period - total_other_elapsed_time_period,
- (total_elapsed_time_period - total_opengl_elapsed_time_period - total_other_elapsed_time_period) * 100.0 / total_elapsed_time_period);
+ TRACE("\E[40;36;1m %-42.42s : %13.2f ms[%6.2f%%], %13.2f ms(P)[%6.2f%%]\E[0m\n",
+ "CoreGL API tracing overhead",
+ total_elapsed_time - total_opengl_elapsed_time - total_other_elapsed_time,
+ (total_elapsed_time - total_opengl_elapsed_time - total_other_elapsed_time) * 100.0 / total_elapsed_time,
+ total_elapsed_time_period - total_opengl_elapsed_time_period - total_other_elapsed_time_period,
+ (total_elapsed_time_period - total_opengl_elapsed_time_period - total_other_elapsed_time_period) * 100.0 / total_elapsed_time_period);
- LOG("\E[40;34m========================================================================================================================\E[0m\n");
- LOG("\n");
+ TRACE("\E[40;34m========================================================================================================================\E[0m\n");
+ TRACE("\n");
for (i = 0; i < MAX_TRACE_TABLE_SIZE; i++)
{
}
}
+ TRACE_END();
+
goto finish;
finish:
tv_last = tv_now;
}
- LOG("\n");
- LOG("\E[0;40;34m===================================================================================================================\E[0m\n");
- LOG("\E[0;32;1m State info \E[1;37;1m: (CURRENT BINDED CONTEXT)\E[0m\n");
- LOG("\E[0;40;34m===================================================================================================================\E[0m\n");
+ TRACE("\n");
+ TRACE("\E[0;40;34m===================================================================================================================\E[0m\n");
+ TRACE("\E[0;32;1m State info \E[1;37;1m: (CURRENT BINDED CONTEXT)\E[0m\n");
+ TRACE("\E[0;40;34m===================================================================================================================\E[0m\n");
#define PRINTF_CHAR_GLenum "%10d"
#define PRINTF_CHAR_GLboolean "%10d"
TYPE valuedata[SIZE]; \
TYPE *value = NULL; \
value = valuedata; GET_STMT; value = valuedata; \
- LOG("\E[0;37;1m %-30.30s : (\E[0m ", #NAME); \
+ TRACE("\E[0;37;1m %-30.30s : (\E[0m ", #NAME); \
for (int i = 0; i < SIZE; i++) \
{ \
if (i > 0) { \
if (i % 4 == 0) \
- LOG("\n %-30.30s ", "");\
+ TRACE("\n %-30.30s ", "");\
else \
- LOG(", "); \
+ TRACE(", "); \
} \
- LOG("["PRINTF_CHAR(TYPE)"]", value[i]); \
+ TRACE("["PRINTF_CHAR(TYPE)"]", value[i]); \
} \
- LOG(" \E[0;37;1m)\E[0m\n"); \
+ TRACE(" \E[0;37;1m)\E[0m\n"); \
}
# include "coregl_fastpath_state.h"
#undef GLUE_STATE
- LOG("\E[0;40;34m===================================================================================================================\E[0m\n");
- LOG("\n");
+ TRACE("\E[0;40;34m===================================================================================================================\E[0m\n");
+ TRACE("\n");
+
+ TRACE_END();
finish:
return;
EGLint ret = _COREGL_INT_INIT_VALUE;
_COREGL_WRAP_FUNC_BEGIN();
- if (api_opt == COREGL_UNKNOWN_PATH) goto finish;
ret = ovr_eglGetError();
goto finish;
EGLDisplay ret = EGL_NO_DISPLAY;
_COREGL_WRAP_FUNC_BEGIN();
- if (api_opt == COREGL_UNKNOWN_PATH) goto finish;
ret = ovr_eglGetDisplay(display_id);
goto finish;
{
EGLBoolean ret = EGL_FALSE;
_COREGL_WRAP_FUNC_BEGIN();
- if (api_opt == COREGL_UNKNOWN_PATH) goto finish;
ret = ovr_eglInitialize(dpy, major, minor);
goto finish;
EGLBoolean ret = EGL_FALSE;
_COREGL_WRAP_FUNC_BEGIN();
- if (api_opt == COREGL_UNKNOWN_PATH) goto finish;
ret = ovr_eglTerminate(dpy);
goto finish;
EGLBoolean ret = EGL_FALSE;
_COREGL_WRAP_FUNC_BEGIN();
- if (api_opt == COREGL_UNKNOWN_PATH) goto finish;
ret = ovr_eglBindAPI(api);
goto finish;
EGLenum ret = 0;
_COREGL_WRAP_FUNC_BEGIN();
- if (api_opt == COREGL_UNKNOWN_PATH) goto finish;
ret = ovr_eglQueryAPI();
goto finish;
_eng_fn ret = NULL;
_COREGL_WRAP_FUNC_BEGIN();
- if (api_opt == COREGL_UNKNOWN_PATH) goto finish;
ret = ovr_eglGetProcAddress(procname);
goto finish;
const char *ret = NULL;
_COREGL_WRAP_FUNC_BEGIN();
- if (api_opt == COREGL_UNKNOWN_PATH) goto finish;
ret = ovr_eglQueryString(dpy, name);
goto finish;