diff options
author | Fredrik Höglund <[email protected]> | 2011-12-20 17:17:02 +0100 |
---|---|---|
committer | Kristian Høgsberg <[email protected]> | 2011-12-20 22:11:17 -0500 |
commit | 655f2c1d6593064b83f64a527798f48cd300fa16 (patch) | |
tree | 7772ebc5b5ce0fff5f8fc7b012a7e283537188ab /src/egl/drivers/dri2/egl_dri2.c | |
parent | 3a2e71874b630fe5d7ec36bbbd69a6dacab7cd15 (diff) |
egl_dri2/x11: Add support for eglSwapInterval
Diffstat (limited to 'src/egl/drivers/dri2/egl_dri2.c')
-rw-r--r-- | src/egl/drivers/dri2/egl_dri2.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/egl/drivers/dri2/egl_dri2.c b/src/egl/drivers/dri2/egl_dri2.c index 4c9ece351af..47de978404d 100644 --- a/src/egl/drivers/dri2/egl_dri2.c +++ b/src/egl/drivers/dri2/egl_dri2.c @@ -259,9 +259,15 @@ dri2_add_config(_EGLDisplay *disp, const __DRIconfig *dri_config, int id, return NULL; } - if (double_buffer) + if (double_buffer) { surface_type &= ~EGL_PIXMAP_BIT; + if (dri2_dpy->swap_available) { + conf->base.MinSwapInterval = 0; + conf->base.MaxSwapInterval = 1000; /* XXX arbitrary value */ + } + } + conf->base.SurfaceType |= surface_type; return conf; |