summaryrefslogtreecommitdiffstats
path: root/src/egl/main/egldriver.c
diff options
context:
space:
mode:
authorBrian Paul <[email protected]>2006-01-30 00:10:55 +0000
committerBrian Paul <[email protected]>2006-01-30 00:10:55 +0000
commitb2006a40eb22899d38cd31691640555228e36975 (patch)
tree4a54cd2f8b638936f7f24d842ab34106a6094a80 /src/egl/main/egldriver.c
parentdaf3093f28353b27d277da4406324fbc41676a5b (diff)
some initial EGL 1.2 work
Diffstat (limited to 'src/egl/main/egldriver.c')
-rw-r--r--src/egl/main/egldriver.c21
1 files changed, 19 insertions, 2 deletions
diff --git a/src/egl/main/egldriver.c b/src/egl/main/egldriver.c
index fd7e00778e1..bda06dd827d 100644
--- a/src/egl/main/egldriver.c
+++ b/src/egl/main/egldriver.c
@@ -181,7 +181,7 @@ _eglInitDriverFallbacks(_EGLDriver *drv)
drv->API.WaitGL = _eglWaitGL;
drv->API.WaitNative = _eglWaitNative;
- /* EGL_MESA_screen */
+#ifdef EGL_MESA_screen_surface
drv->API.ChooseModeMESA = _eglChooseModeMESA;
drv->API.GetModesMESA = _eglGetModesMESA;
drv->API.GetModeAttribMESA = _eglGetModeAttribMESA;
@@ -193,6 +193,11 @@ _eglInitDriverFallbacks(_EGLDriver *drv)
drv->API.QueryScreenSurfaceMESA = _eglQueryScreenSurfaceMESA;
drv->API.QueryScreenModeMESA = _eglQueryScreenModeMESA;
drv->API.QueryModeStringMESA = _eglQueryModeStringMESA;
+#endif /* EGL_MESA_screen_surface */
+
+#ifdef EGL_VERSION_1_2
+ drv->API.CreatePbufferFromClientBuffer = _eglCreatePbufferFromClientBuffer;
+#endif /* EGL_VERSION_1_2 */
}
@@ -227,6 +232,11 @@ _eglQueryString(_EGLDriver *drv, EGLDisplay dpy, EGLint name)
case EGL_EXTENSIONS:
_eglUpdateExtensionsString(drv);
return drv->Extensions.String;
+#ifdef EGL_VERSION_1_2
+ case EGL_CLIENT_APIS:
+ /* XXX need to initialize somewhere */
+ return drv->ClientAPIs;
+#endif
default:
_eglError(EGL_BAD_PARAMETER, "eglQueryString");
return NULL;
@@ -250,6 +260,13 @@ _eglWaitNative(_EGLDriver *drv, EGLDisplay dpy, EGLint engine)
/* just a placeholder */
(void) drv;
(void) dpy;
- (void) engine;
+ switch (engine) {
+ case EGL_CORE_NATIVE_ENGINE:
+ break;
+ default:
+ _eglError(EGL_BAD_PARAMETER, "eglWaitNative(engine)");
+ return EGL_FALSE;
+ }
+
return EGL_TRUE;
}