From 0328076efb5ff6e62152c09e38d0d11f7931d07b Mon Sep 17 00:00:00 2001 From: marha Date: Mon, 10 Dec 2012 08:33:13 +0100 Subject: fontconfig libX11 mesa pixman git update 10 dec 2012 libX11 9833489e6c3829a1e835bc0a11f028fc180809e4 mesa 17f5dc57306b8f5079304701e455bf4b927d3cae pixman 8ca4e144724ba2041bc5ef077ccf6d24e7cf4d1f fontconfig 608c5b590bd3428dfcd30f3d68ee8b7131e2f019 --- mesalib/src/mesa/drivers/dri/common/drisw_util.c | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) (limited to 'mesalib/src/mesa/drivers/dri/common') diff --git a/mesalib/src/mesa/drivers/dri/common/drisw_util.c b/mesalib/src/mesa/drivers/dri/common/drisw_util.c index 8fdb05ec3..cd5a39a37 100644 --- a/mesalib/src/mesa/drivers/dri/common/drisw_util.c +++ b/mesalib/src/mesa/drivers/dri/common/drisw_util.c @@ -126,7 +126,10 @@ driCreateContextAttribs(__DRIscreen *screen, int api, mesa_api = API_OPENGLES2; break; case __DRI_API_OPENGL_CORE: + mesa_api = API_OPENGL_CORE; + break; default: + *error = __DRI_CTX_ERROR_BAD_API; return NULL; } @@ -149,6 +152,19 @@ driCreateContextAttribs(__DRIscreen *screen, int api, } } + /* Mesa does not support the GL_ARB_compatibilty extension or the + * compatibility profile. This means that we treat a API_OPENGL_COMPAT 3.1 as + * API_OPENGL_CORE and reject API_OPENGL_COMPAT 3.2+. + */ + if (mesa_api == API_OPENGL_COMPAT && major_version == 3 && minor_version == 1) + mesa_api = API_OPENGL_CORE; + + if (mesa_api == API_OPENGL_COMPAT + && ((major_version > 3) + || (major_version == 3 && minor_version >= 2))) { + *error = __DRI_CTX_ERROR_BAD_API; + return NULL; + } /* There are no forward-compatible contexts before OpenGL 3.0. The * GLX_ARB_create_context spec says: * -- cgit v1.2.3