Waffle supports the following OpenGL platforms.
Waffle supports creating and managing contexts from the API's below in a platform-independent manner. Of course, the set of supported API's, and the available contexts that can be created for each, are dependent on the native OpenGL platform. For details on the relationship among native system, OpenGL API, and context creation, see the manual page for waffle_config(3).
For selected platforms (currently only Linux), Waffle allows clients to access the backing native objects of each Waffle object. For example, if you create a waffle_window on the X/EGL platform, then you can retrieve the Xlib Display, Xlib Window, EGLDisplay, and EGLSurface. Here is a small example for X/EGL:
// Assume we've initialized the Waffle with X/EGL. struct waffle_window *window = waffle_window_create(...); struct waffle_x11_egl_window *n_window = waffle_window_get_native(window)->x11_egl; Display *xlib_dpy = n_window->display.xlib_display; EGLDisplay *egl_dpy = n_window->display.egl_display; Window xlib_window = n_window->xlib_window; EGLSurface egl_surface = n_window->egl_surface;
This feature allows clients to implement behvaior, such as input and window manager hints, that is outside of Waffle's scope. Piglit currently uses this feature to implement input for X windows.
In the future, Waffle will also support the inverse direction. It will allow clients to create Waffle objects from pre-existing native objects.