There is no point in having them when we distribute eglext.h.
As for unofficial extensions, there is a chance that we might remove some of
them evetually. Keeping the #ifdef's for now should make that easier.
}
-#ifdef EGL_KHR_reusable_sync
-
-
static INLINE _EGLDriver *
_eglCheckSync(_EGLDisplay *disp, _EGLSync *s, const char *msg)
{
}
-#endif /* EGL_KHR_reusable_sync */
-
-
#ifdef EGL_MESA_screen_surface
EGLBoolean EGLAPIENTRY
eglWaitGL(void)
{
-#ifdef EGL_VERSION_1_2
_EGLThreadInfo *t = _eglGetCurrentThread();
EGLint api_index = t->CurrentAPIIndex;
EGLint es_index = _eglConvertApiToIndex(EGL_OPENGL_ES_API);
ret = eglWaitClient();
t->CurrentAPIIndex = api_index;
return ret;
-#else
- return eglWaitClient();
-#endif
}
#ifdef EGL_MESA_drm_display
{ "eglGetDRMDisplayMESA", (_EGLProc) eglGetDRMDisplayMESA },
#endif
-#ifdef EGL_KHR_image_base
{ "eglCreateImageKHR", (_EGLProc) eglCreateImageKHR },
{ "eglDestroyImageKHR", (_EGLProc) eglDestroyImageKHR },
-#endif /* EGL_KHR_image_base */
#ifdef EGL_NOK_swap_region
{ "eglSwapBuffersRegionNOK", (_EGLProc) eglSwapBuffersRegionNOK },
#endif
** EGL 1.2
**/
-#ifdef EGL_VERSION_1_2
-
-
/**
* Specify the client API to use for subsequent calls including:
* eglCreateContext()
}
-#endif /* EGL_VERSION_1_2 */
-
-
-#ifdef EGL_KHR_image_base
-
-
EGLImageKHR EGLAPIENTRY
eglCreateImageKHR(EGLDisplay dpy, EGLContext ctx, EGLenum target,
EGLClientBuffer buffer, const EGLint *attr_list)
}
-#endif /* EGL_KHR_image_base */
-
-
-#ifdef EGL_KHR_reusable_sync
-
-
EGLSyncKHR EGLAPIENTRY
eglCreateSyncKHR(EGLDisplay dpy, EGLenum type, const EGLint *attrib_list)
{
}
-#endif /* EGL_KHR_reusable_sync */
-
-
#ifdef EGL_NOK_swap_region
EGLBoolean EGLAPIENTRY
#endif /* EGL_MESA_screen_surface */
-#ifdef EGL_VERSION_1_2
typedef _EGLSurface *(*CreatePbufferFromClientBuffer_t)(_EGLDriver *drv, _EGLDisplay *dpy, EGLenum buftype, EGLClientBuffer buffer, _EGLConfig *config, const EGLint *attrib_list);
-#endif /* EGL_VERSION_1_2 */
-#ifdef EGL_KHR_image_base
typedef _EGLImage *(*CreateImageKHR_t)(_EGLDriver *drv, _EGLDisplay *dpy, _EGLContext *ctx, EGLenum target, EGLClientBuffer buffer, const EGLint *attr_list);
typedef EGLBoolean (*DestroyImageKHR_t)(_EGLDriver *drv, _EGLDisplay *dpy, _EGLImage *image);
-#endif /* EGL_KHR_image_base */
-#ifdef EGL_KHR_reusable_sync
typedef _EGLSync *(*CreateSyncKHR_t)(_EGLDriver *drv, _EGLDisplay *dpy, EGLenum type, const EGLint *attrib_list);
typedef EGLBoolean (*DestroySyncKHR_t)(_EGLDriver *drv, _EGLDisplay *dpy, _EGLSync *sync);
typedef EGLint (*ClientWaitSyncKHR_t)(_EGLDriver *drv, _EGLDisplay *dpy, _EGLSync *sync, EGLint flags, EGLTimeKHR timeout);
typedef EGLBoolean (*SignalSyncKHR_t)(_EGLDriver *drv, _EGLDisplay *dpy, _EGLSync *sync, EGLenum mode);
typedef EGLBoolean (*GetSyncAttribKHR_t)(_EGLDriver *drv, _EGLDisplay *dpy, _EGLSync *sync, EGLint attribute, EGLint *value);
-#endif /* EGL_KHR_reusable_sync */
#ifdef EGL_NOK_swap_region
QueryModeStringMESA_t QueryModeStringMESA;
#endif /* EGL_MESA_screen_surface */
-#ifdef EGL_VERSION_1_2
CreatePbufferFromClientBuffer_t CreatePbufferFromClientBuffer;
-#endif
-#ifdef EGL_KHR_image_base
CreateImageKHR_t CreateImageKHR;
DestroyImageKHR_t DestroyImageKHR;
-#endif /* EGL_KHR_image_base */
-#ifdef EGL_KHR_reusable_sync
CreateSyncKHR_t CreateSyncKHR;
DestroySyncKHR_t DestroySyncKHR;
ClientWaitSyncKHR_t ClientWaitSyncKHR;
SignalSyncKHR_t SignalSyncKHR;
GetSyncAttribKHR_t GetSyncAttribKHR;
-#endif /* EGL_KHR_reusable_sync */
#ifdef EGL_NOK_swap_region
SwapBuffersRegionNOK_t SwapBuffersRegionNOK;
}
-#ifdef EGL_VERSION_1_2
static EGLint
_eglQueryContextRenderBuffer(_EGLContext *ctx)
{
rb = surf->RenderBuffer;
return rb;
}
-#endif /* EGL_VERSION_1_2 */
EGLBoolean
case EGL_CONTEXT_CLIENT_VERSION:
*value = c->ClientVersion;
break;
-#ifdef EGL_VERSION_1_2
case EGL_CONTEXT_CLIENT_TYPE:
*value = c->ClientAPI;
break;
case EGL_RENDER_BUFFER:
*value = _eglQueryContextRenderBuffer(c);
break;
-#endif /* EGL_VERSION_1_2 */
default:
return _eglError(EGL_BAD_ATTRIBUTE, "eglQueryContext");
}
return _eglError(EGL_BAD_MATCH, "eglMakeCurrent");
switch (ctx->ClientAPI) {
-#ifdef EGL_VERSION_1_4
/* OpenGL and OpenGL ES are conflicting */
case EGL_OPENGL_ES_API:
conflict_api = EGL_OPENGL_API;
case EGL_OPENGL_API:
conflict_api = EGL_OPENGL_ES_API;
break;
-#endif
default:
conflict_api = -1;
break;
drv->API.QueryModeStringMESA = _eglQueryModeStringMESA;
#endif /* EGL_MESA_screen_surface */
-#ifdef EGL_KHR_image_base
drv->API.CreateImageKHR = NULL;
drv->API.DestroyImageKHR = NULL;
-#endif /* EGL_KHR_image_base */
-#ifdef EGL_KHR_reusable_sync
drv->API.CreateSyncKHR = NULL;
drv->API.DestroySyncKHR = NULL;
drv->API.ClientWaitSyncKHR = NULL;
drv->API.SignalSyncKHR = NULL;
drv->API.GetSyncAttribKHR = _eglGetSyncAttribKHR;
-#endif /* EGL_KHR_reusable_sync */
#ifdef EGL_MESA_drm_image
drv->API.CreateDRMImageMESA = NULL;
#include "egllog.h"
-#ifdef EGL_KHR_image_base
-
-
/**
* Parse the list of image attributes and return the proper error code.
*/
return EGL_TRUE;
}
-
-
-#endif /* EGL_KHR_image_base */
#include "egllog.h"
-#ifdef EGL_KHR_reusable_sync
-
-
/**
* Parse the list of sync attributes and return the proper error code.
*/
return EGL_TRUE;
}
-
-
-#endif /* EGL_KHR_reusable_sync */
#include "egldisplay.h"
-#ifdef EGL_KHR_reusable_sync
-
-
/**
* "Base" class for device driver syncs.
*/
}
-#endif /* EGL_KHR_reusable_sync */
-
-
#endif /* EGLSYNC_INCLUDED */
_EGL_DRIVER_STANDARD_TYPECASTS(egl_g3d)
_EGL_DRIVER_TYPECAST(egl_g3d_image, _EGLImage, obj)
-#ifdef EGL_KHR_reusable_sync
-
struct egl_g3d_sync {
_EGLSync base;
};
_EGL_DRIVER_TYPECAST(egl_g3d_sync, _EGLSync, obj)
-#endif /* EGL_KHR_reusable_sync */
-
#ifdef EGL_MESA_screen_surface
struct egl_g3d_screen {
#endif
-#ifdef EGL_KHR_reusable_sync
drv->API.CreateSyncKHR = egl_g3d_create_sync;
drv->API.DestroySyncKHR = egl_g3d_destroy_sync;
drv->API.ClientWaitSyncKHR = egl_g3d_client_wait_sync;
drv->API.SignalSyncKHR = egl_g3d_signal_sync;
-#endif
#ifdef EGL_MESA_screen_surface
drv->API.CreateScreenSurfaceMESA = egl_g3d_create_screen_surface;
#include "egl_g3d.h"
#include "egl_g3d_sync.h"
-#ifdef EGL_KHR_reusable_sync
-
/**
* Wait for the conditional variable.
*/
return EGL_TRUE;
}
-
-#endif /* EGL_KHR_reusable_sync */
#include "egl_g3d.h"
-#ifdef EGL_KHR_reusable_sync
-
_EGLSync *
egl_g3d_create_sync(_EGLDriver *drv, _EGLDisplay *dpy,
EGLenum type, const EGLint *attrib_list);
egl_g3d_signal_sync(_EGLDriver *drv, _EGLDisplay *dpy, _EGLSync *sync,
EGLenum mode);
-#endif /* EGL_KHR_reusable_sync */
-
#endif /* _EGL_G3D_SYNC_H_ */