/* WL-EGL Log Level - 0:unintialized, 1:initialized(no logging), 2:min log, 3:more log */
#define WL_EGL_LOG(lvl, f, x...) { \
- if(wl_egl_log_level == 1) { \
+ if (wl_egl_log_level == 1) { \
} \
- else if(wl_egl_log_level > 1) { \
- if(wl_egl_log_level <= lvl) \
+ else if (wl_egl_log_level > 1) { \
+ if (wl_egl_log_level <= lvl) \
WL_EGL_LOG_PRINT(f, ##x) \
} \
else { \
char *env = getenv("WL_EGL_LOG_LEVEL"); \
- if(env == NULL) \
+ if (env == NULL) \
wl_egl_log_level = 1; \
else \
wl_egl_log_level = atoi(env); \
\
- if(wl_egl_log_level > 1 && wl_egl_log_level <= lvl) \
+ if (wl_egl_log_level > 1 && wl_egl_log_level <= lvl)\
WL_EGL_LOG_PRINT(f, ##x) \
} \
}
#define WL_EGL_LOG_PRINT(fmt, args...) { \
printf("[\x1b[32mWL-EGL\x1b[0m %d:%d|\x1b[32m%s\x1b[0m|%d] " fmt "\n", \
- getpid(), (int)syscall(SYS_gettid), __func__,__LINE__, ##args); \
+ getpid(), (int)syscall(SYS_gettid), __func__, __LINE__, ##args); \
}
#define WL_EGL_ERR(f, x...) { \
int width, int height,
int dx, int dy)
{
- wl_egl_window_rotation rotation;
-
if (egl_window == NULL) {
WL_EGL_ERR("egl_window is NULL");
return;
}
if (egl_window->rotation == rotation) {
- WL_EGL_LOG(2, "rotation(%d) egl_window->rotation(%d) already rotated");
+ WL_EGL_LOG(2, "rotation(%d) egl_window->rotation(%d) already rotated",
+ rotation, egl_window->rotation);
return;
}