summaryrefslogtreecommitdiff
path: root/src/egl/main/eglglobals.h
diff options
context:
space:
mode:
authorBrian Paul <brian.paul@tungstengraphics.com>2005-12-10 17:54:00 +0000
committerBrian Paul <brian.paul@tungstengraphics.com>2005-12-10 17:54:00 +0000
commit48822796339cb4a55714dc3f1abbe379562ec538 (patch)
tree83a6ab54af6a26242b0176f82d67c7c0e66ff776 /src/egl/main/eglglobals.h
parentb04dd5c58763039a564c50b5e3c0bbc9755e7f72 (diff)
Some initial per-thread support.
Rename eglShowSurfaceMESA to eglShowScreenSurfaceMESA.
Diffstat (limited to 'src/egl/main/eglglobals.h')
-rw-r--r--src/egl/main/eglglobals.h23
1 files changed, 19 insertions, 4 deletions
diff --git a/src/egl/main/eglglobals.h b/src/egl/main/eglglobals.h
index 1a6f12d174..44b4626c58 100644
--- a/src/egl/main/eglglobals.h
+++ b/src/egl/main/eglglobals.h
@@ -5,6 +5,19 @@
#include "eglhash.h"
+/**
+ * Per-thread info
+ */
+struct _egl_thread_info
+{
+ EGLint LastError;
+ _EGLContext *CurrentContext;
+};
+
+
+/**
+ * Global library data
+ */
struct _egl_global
{
EGLBoolean Initialized;
@@ -15,10 +28,8 @@ struct _egl_global
EGLScreenMESA FreeScreenHandle;
- EGLint LastError;
-
- /* XXX this should be per-thread someday */
- _EGLContext *CurrentContext;
+ /* XXX temporary */
+ _EGLThreadInfo ThreadInfo;
};
@@ -33,6 +44,10 @@ extern void
_eglDestroyGlobals(void);
+extern _EGLThreadInfo *
+_eglGetCurrentThread(void);
+
+
extern void
_eglError(EGLint errCode, const char *msg);