#include "eglcurrent.h"
#include "eglglobals.h"
-
/* This should be kept in sync with _eglInitThreadInfo() */
#define _EGL_THREAD_INFO_INITIALIZER \
- { EGL_SUCCESS, NULL, 0 }
+ { EGL_SUCCESS, NULL, 0, NULL, NULL, NULL }
/* a fallback thread info to guarantee that every thread always has one */
static _EGLThreadInfo dummy_thread = _EGL_THREAD_INFO_INITIALIZER;
EGLint LastError;
_EGLContext *CurrentContext;
EGLenum CurrentAPI;
+ EGLLabelKHR Label;
+
+ /**
+ * The name of the EGL function that's being called at the moment. This is
+ * used to report the function name to the EGL_KHR_debug callback.
+ */
+ const char *CurrentFuncName;
+ EGLLabelKHR CurrentObjectLabel;
};
EGLBoolean IsLinked;
EGLint RefCount;
+ EGLLabelKHR Label;
+
/* used to link resources of the same type */
_EGLResource *Next;
};
/* lists of resources */
_EGLResource *ResourceLists[_EGL_NUM_RESOURCES];
+
+ EGLLabelKHR Label;
};
" EGL_EXT_platform_wayland"
" EGL_EXT_platform_x11"
" EGL_KHR_client_get_all_proc_addresses"
- " EGL_MESA_platform_gbm"
+ " EGL_MESA_platform_gbm",
+
+ NULL, /* debugCallback */
+ _EGL_DEBUG_BIT_CRITICAL | _EGL_DEBUG_BIT_ERROR, /* debugTypesEnabled */
};
#include "egltypedefs.h"
+enum
+{
+ _EGL_DEBUG_BIT_CRITICAL = 0x1,
+ _EGL_DEBUG_BIT_ERROR = 0x2,
+ _EGL_DEBUG_BIT_WARN = 0x4,
+ _EGL_DEBUG_BIT_INFO = 0x8,
+};
/**
* Global library data
void (*AtExitCalls[10])(void);
const char *ClientExtensionString;
+
+ EGLDEBUGPROCKHR debugCallback;
+ unsigned int debugTypesEnabled;
};