mirror of
https://github.com/X11Libre/xserver.git
synced 2026-10-04 22:36:10 +00:00
GLX: Enable GLX 1.4 on DRI2
Return the minimum GLX version supported by all screens. Assume that DRI2 screens have all the required features for GLX 1.4. Assume that everyone else can only support GLX 1.2. Reviewed-by: Kristian Høgsberg <krh@redhat.com> Reviewed-by: Jesse Barnes <jbarnes@virtuousgeek.org>
This commit is contained in:
parent
f11a356bce
commit
ad5c0d9efa
6 changed files with 38 additions and 7 deletions
|
|
@ -739,8 +739,8 @@ int __glXDisp_QueryVersion(__GLXclientState *cl, GLbyte *pc)
|
|||
** client if it wants to work with older clients; however, in this
|
||||
** implementation the server just returns its version number.
|
||||
*/
|
||||
reply.majorVersion = SERVER_GLX_MAJOR_VERSION;
|
||||
reply.minorVersion = SERVER_GLX_MINOR_VERSION;
|
||||
reply.majorVersion = glxMajorVersion;
|
||||
reply.minorVersion = glxMinorVersion;
|
||||
reply.length = 0;
|
||||
reply.type = X_Reply;
|
||||
reply.sequenceNumber = client->sequence;
|
||||
|
|
@ -2360,6 +2360,7 @@ int __glXDisp_QueryServerString(__GLXclientState *cl, GLbyte *pc)
|
|||
char *buf;
|
||||
__GLXscreen *pGlxScreen;
|
||||
int err;
|
||||
char ver_str[16];
|
||||
|
||||
if (!validGlxScreen(client, req->screen, &pGlxScreen, &err))
|
||||
return err;
|
||||
|
|
@ -2369,7 +2370,11 @@ int __glXDisp_QueryServerString(__GLXclientState *cl, GLbyte *pc)
|
|||
ptr = pGlxScreen->GLXvendor;
|
||||
break;
|
||||
case GLX_VERSION:
|
||||
ptr = pGlxScreen->GLXversion;
|
||||
/* Return to the server version rather than the screen version
|
||||
* to prevent confusion when they do not match.
|
||||
*/
|
||||
snprintf(ver_str, 16, "%d.%d", glxMajorVersion, glxMinorVersion);
|
||||
ptr = ver_str;
|
||||
break;
|
||||
case GLX_EXTENSIONS:
|
||||
ptr = pGlxScreen->GLXextensions;
|
||||
|
|
|
|||
Loading…
Reference in a new issue