Clone of mesa.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623
  1. /* $XFree86: xc/lib/GL/dri/XF86dri.c,v 1.13 2002/10/30 12:51:25 alanh Exp $ */
  2. /**************************************************************************
  3. Copyright 1998-1999 Precision Insight, Inc., Cedar Park, Texas.
  4. Copyright 2000 VA Linux Systems, Inc.
  5. All Rights Reserved.
  6. Permission is hereby granted, free of charge, to any person obtaining a
  7. copy of this software and associated documentation files (the
  8. "Software"), to deal in the Software without restriction, including
  9. without limitation the rights to use, copy, modify, merge, publish,
  10. distribute, sub license, and/or sell copies of the Software, and to
  11. permit persons to whom the Software is furnished to do so, subject to
  12. the following conditions:
  13. The above copyright notice and this permission notice (including the
  14. next paragraph) shall be included in all copies or substantial portions
  15. of the Software.
  16. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
  17. OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
  18. MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.
  19. IN NO EVENT SHALL PRECISION INSIGHT AND/OR ITS SUPPLIERS BE LIABLE FOR
  20. ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
  21. TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
  22. SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
  23. **************************************************************************/
  24. /*
  25. * Authors:
  26. * Kevin E. Martin <martin@valinux.com>
  27. * Jens Owen <jens@tungstengraphics.com>
  28. * Rickard E. (Rik) Faith <faith@valinux.com>
  29. *
  30. */
  31. /* THIS IS NOT AN X CONSORTIUM STANDARD */
  32. #ifdef GLX_DIRECT_RENDERING
  33. #define NEED_REPLIES
  34. #include <X11/Xlibint.h>
  35. #include <X11/extensions/Xext.h>
  36. #include <X11/extensions/extutil.h>
  37. #include "glheader.h"
  38. #include "xf86dristr.h"
  39. static XExtensionInfo _xf86dri_info_data;
  40. static XExtensionInfo *xf86dri_info = &_xf86dri_info_data;
  41. static char xf86dri_extension_name[] = XF86DRINAME;
  42. #define XF86DRICheckExtension(dpy,i,val) \
  43. XextCheckExtension (dpy, i, xf86dri_extension_name, val)
  44. /*****************************************************************************
  45. * *
  46. * private utility routines *
  47. * *
  48. *****************************************************************************/
  49. static int close_display(Display *dpy, XExtCodes *extCodes);
  50. static /* const */ XExtensionHooks xf86dri_extension_hooks = {
  51. NULL, /* create_gc */
  52. NULL, /* copy_gc */
  53. NULL, /* flush_gc */
  54. NULL, /* free_gc */
  55. NULL, /* create_font */
  56. NULL, /* free_font */
  57. close_display, /* close_display */
  58. NULL, /* wire_to_event */
  59. NULL, /* event_to_wire */
  60. NULL, /* error */
  61. NULL, /* error_string */
  62. };
  63. static XEXT_GENERATE_FIND_DISPLAY (find_display, xf86dri_info,
  64. xf86dri_extension_name,
  65. &xf86dri_extension_hooks,
  66. 0, NULL)
  67. static XEXT_GENERATE_CLOSE_DISPLAY (close_display, xf86dri_info)
  68. /*****************************************************************************
  69. * *
  70. * public XFree86-DRI Extension routines *
  71. * *
  72. *****************************************************************************/
  73. #if 0
  74. #include <stdio.h>
  75. #define TRACE(msg) fprintf(stderr,"XF86DRI%s\n", msg);
  76. #else
  77. #define TRACE(msg)
  78. #endif
  79. PUBLIC Bool XF86DRIQueryExtension (dpy, event_basep, error_basep)
  80. Display *dpy;
  81. int *event_basep, *error_basep;
  82. {
  83. XExtDisplayInfo *info = find_display (dpy);
  84. TRACE("QueryExtension...");
  85. if (XextHasExtension(info)) {
  86. *event_basep = info->codes->first_event;
  87. *error_basep = info->codes->first_error;
  88. TRACE("QueryExtension... return True");
  89. return True;
  90. } else {
  91. TRACE("QueryExtension... return False");
  92. return False;
  93. }
  94. }
  95. PUBLIC Bool XF86DRIQueryVersion(dpy, majorVersion, minorVersion, patchVersion)
  96. Display* dpy;
  97. int* majorVersion;
  98. int* minorVersion;
  99. int* patchVersion;
  100. {
  101. XExtDisplayInfo *info = find_display (dpy);
  102. xXF86DRIQueryVersionReply rep;
  103. xXF86DRIQueryVersionReq *req;
  104. TRACE("QueryVersion...");
  105. XF86DRICheckExtension (dpy, info, False);
  106. LockDisplay(dpy);
  107. GetReq(XF86DRIQueryVersion, req);
  108. req->reqType = info->codes->major_opcode;
  109. req->driReqType = X_XF86DRIQueryVersion;
  110. if (!_XReply(dpy, (xReply *)&rep, 0, xFalse)) {
  111. UnlockDisplay(dpy);
  112. SyncHandle();
  113. TRACE("QueryVersion... return False");
  114. return False;
  115. }
  116. *majorVersion = rep.majorVersion;
  117. *minorVersion = rep.minorVersion;
  118. *patchVersion = rep.patchVersion;
  119. UnlockDisplay(dpy);
  120. SyncHandle();
  121. TRACE("QueryVersion... return True");
  122. return True;
  123. }
  124. PUBLIC Bool XF86DRIQueryDirectRenderingCapable(dpy, screen, isCapable)
  125. Display* dpy;
  126. int screen;
  127. Bool* isCapable;
  128. {
  129. XExtDisplayInfo *info = find_display (dpy);
  130. xXF86DRIQueryDirectRenderingCapableReply rep;
  131. xXF86DRIQueryDirectRenderingCapableReq *req;
  132. TRACE("QueryDirectRenderingCapable...");
  133. XF86DRICheckExtension (dpy, info, False);
  134. LockDisplay(dpy);
  135. GetReq(XF86DRIQueryDirectRenderingCapable, req);
  136. req->reqType = info->codes->major_opcode;
  137. req->driReqType = X_XF86DRIQueryDirectRenderingCapable;
  138. req->screen = screen;
  139. if (!_XReply(dpy, (xReply *)&rep, 0, xFalse)) {
  140. UnlockDisplay(dpy);
  141. SyncHandle();
  142. TRACE("QueryDirectRenderingCapable... return False");
  143. return False;
  144. }
  145. *isCapable = rep.isCapable;
  146. UnlockDisplay(dpy);
  147. SyncHandle();
  148. TRACE("QueryDirectRenderingCapable... return True");
  149. return True;
  150. }
  151. PUBLIC Bool XF86DRIOpenConnection(dpy, screen, hSAREA, busIdString)
  152. Display* dpy;
  153. int screen;
  154. drm_handle_t * hSAREA;
  155. char **busIdString;
  156. {
  157. XExtDisplayInfo *info = find_display (dpy);
  158. xXF86DRIOpenConnectionReply rep;
  159. xXF86DRIOpenConnectionReq *req;
  160. TRACE("OpenConnection...");
  161. XF86DRICheckExtension (dpy, info, False);
  162. LockDisplay(dpy);
  163. GetReq(XF86DRIOpenConnection, req);
  164. req->reqType = info->codes->major_opcode;
  165. req->driReqType = X_XF86DRIOpenConnection;
  166. req->screen = screen;
  167. if (!_XReply(dpy, (xReply *)&rep, 0, xFalse)) {
  168. UnlockDisplay(dpy);
  169. SyncHandle();
  170. TRACE("OpenConnection... return False");
  171. return False;
  172. }
  173. *hSAREA = rep.hSAREALow;
  174. if (sizeof(drm_handle_t) == 8) {
  175. int shift = 32; /* var to prevent warning on next line */
  176. *hSAREA |= ((drm_handle_t) rep.hSAREAHigh) << shift;
  177. }
  178. if (rep.length) {
  179. if (!(*busIdString = (char *)Xcalloc(rep.busIdStringLength + 1, 1))) {
  180. _XEatData(dpy, ((rep.busIdStringLength+3) & ~3));
  181. UnlockDisplay(dpy);
  182. SyncHandle();
  183. TRACE("OpenConnection... return False");
  184. return False;
  185. }
  186. _XReadPad(dpy, *busIdString, rep.busIdStringLength);
  187. } else {
  188. *busIdString = NULL;
  189. }
  190. UnlockDisplay(dpy);
  191. SyncHandle();
  192. TRACE("OpenConnection... return True");
  193. return True;
  194. }
  195. PUBLIC Bool XF86DRIAuthConnection(dpy, screen, magic)
  196. Display* dpy;
  197. int screen;
  198. drm_magic_t magic;
  199. {
  200. XExtDisplayInfo *info = find_display (dpy);
  201. xXF86DRIAuthConnectionReq *req;
  202. xXF86DRIAuthConnectionReply rep;
  203. TRACE("AuthConnection...");
  204. XF86DRICheckExtension (dpy, info, False);
  205. LockDisplay(dpy);
  206. GetReq(XF86DRIAuthConnection, req);
  207. req->reqType = info->codes->major_opcode;
  208. req->driReqType = X_XF86DRIAuthConnection;
  209. req->screen = screen;
  210. req->magic = magic;
  211. rep.authenticated = 0;
  212. if (!_XReply(dpy, (xReply *)&rep, 0, xFalse) || !rep.authenticated) {
  213. UnlockDisplay(dpy);
  214. SyncHandle();
  215. TRACE("AuthConnection... return False");
  216. return False;
  217. }
  218. UnlockDisplay(dpy);
  219. SyncHandle();
  220. TRACE("AuthConnection... return True");
  221. return True;
  222. }
  223. PUBLIC Bool XF86DRICloseConnection(dpy, screen)
  224. Display* dpy;
  225. int screen;
  226. {
  227. XExtDisplayInfo *info = find_display (dpy);
  228. xXF86DRICloseConnectionReq *req;
  229. TRACE("CloseConnection...");
  230. XF86DRICheckExtension (dpy, info, False);
  231. LockDisplay(dpy);
  232. GetReq(XF86DRICloseConnection, req);
  233. req->reqType = info->codes->major_opcode;
  234. req->driReqType = X_XF86DRICloseConnection;
  235. req->screen = screen;
  236. UnlockDisplay(dpy);
  237. SyncHandle();
  238. TRACE("CloseConnection... return True");
  239. return True;
  240. }
  241. PUBLIC Bool XF86DRIGetClientDriverName(dpy, screen, ddxDriverMajorVersion,
  242. ddxDriverMinorVersion, ddxDriverPatchVersion, clientDriverName)
  243. Display* dpy;
  244. int screen;
  245. int* ddxDriverMajorVersion;
  246. int* ddxDriverMinorVersion;
  247. int* ddxDriverPatchVersion;
  248. char** clientDriverName;
  249. {
  250. XExtDisplayInfo *info = find_display (dpy);
  251. xXF86DRIGetClientDriverNameReply rep;
  252. xXF86DRIGetClientDriverNameReq *req;
  253. TRACE("GetClientDriverName...");
  254. XF86DRICheckExtension (dpy, info, False);
  255. LockDisplay(dpy);
  256. GetReq(XF86DRIGetClientDriverName, req);
  257. req->reqType = info->codes->major_opcode;
  258. req->driReqType = X_XF86DRIGetClientDriverName;
  259. req->screen = screen;
  260. if (!_XReply(dpy, (xReply *)&rep, 0, xFalse)) {
  261. UnlockDisplay(dpy);
  262. SyncHandle();
  263. TRACE("GetClientDriverName... return False");
  264. return False;
  265. }
  266. *ddxDriverMajorVersion = rep.ddxDriverMajorVersion;
  267. *ddxDriverMinorVersion = rep.ddxDriverMinorVersion;
  268. *ddxDriverPatchVersion = rep.ddxDriverPatchVersion;
  269. if (rep.length) {
  270. if (!(*clientDriverName = (char *)Xcalloc(rep.clientDriverNameLength + 1, 1))) {
  271. _XEatData(dpy, ((rep.clientDriverNameLength+3) & ~3));
  272. UnlockDisplay(dpy);
  273. SyncHandle();
  274. TRACE("GetClientDriverName... return False");
  275. return False;
  276. }
  277. _XReadPad(dpy, *clientDriverName, rep.clientDriverNameLength);
  278. } else {
  279. *clientDriverName = NULL;
  280. }
  281. UnlockDisplay(dpy);
  282. SyncHandle();
  283. TRACE("GetClientDriverName... return True");
  284. return True;
  285. }
  286. PUBLIC Bool XF86DRICreateContextWithConfig(dpy, screen, configID, context,
  287. hHWContext)
  288. Display* dpy;
  289. int screen;
  290. int configID;
  291. XID* context;
  292. drm_context_t * hHWContext;
  293. {
  294. XExtDisplayInfo *info = find_display (dpy);
  295. xXF86DRICreateContextReply rep;
  296. xXF86DRICreateContextReq *req;
  297. TRACE("CreateContext...");
  298. XF86DRICheckExtension (dpy, info, False);
  299. LockDisplay(dpy);
  300. GetReq(XF86DRICreateContext, req);
  301. req->reqType = info->codes->major_opcode;
  302. req->driReqType = X_XF86DRICreateContext;
  303. req->visual = configID;
  304. req->screen = screen;
  305. *context = XAllocID(dpy);
  306. req->context = *context;
  307. if (!_XReply(dpy, (xReply *)&rep, 0, xFalse)) {
  308. UnlockDisplay(dpy);
  309. SyncHandle();
  310. TRACE("CreateContext... return False");
  311. return False;
  312. }
  313. *hHWContext = rep.hHWContext;
  314. UnlockDisplay(dpy);
  315. SyncHandle();
  316. TRACE("CreateContext... return True");
  317. return True;
  318. }
  319. PUBLIC Bool XF86DRICreateContext(dpy, screen, visual, context, hHWContext)
  320. Display* dpy;
  321. int screen;
  322. Visual* visual;
  323. XID* context;
  324. drm_context_t * hHWContext;
  325. {
  326. return XF86DRICreateContextWithConfig( dpy, screen, visual->visualid,
  327. context, hHWContext );
  328. }
  329. PUBLIC GLboolean XF86DRIDestroyContext( __DRInativeDisplay * ndpy, int screen,
  330. __DRIid context )
  331. {
  332. Display * const dpy = (Display *) ndpy;
  333. XExtDisplayInfo *info = find_display (dpy);
  334. xXF86DRIDestroyContextReq *req;
  335. TRACE("DestroyContext...");
  336. XF86DRICheckExtension (dpy, info, False);
  337. LockDisplay(dpy);
  338. GetReq(XF86DRIDestroyContext, req);
  339. req->reqType = info->codes->major_opcode;
  340. req->driReqType = X_XF86DRIDestroyContext;
  341. req->screen = screen;
  342. req->context = context;
  343. UnlockDisplay(dpy);
  344. SyncHandle();
  345. TRACE("DestroyContext... return True");
  346. return True;
  347. }
  348. PUBLIC GLboolean XF86DRICreateDrawable( __DRInativeDisplay * ndpy, int screen,
  349. __DRIid drawable, drm_drawable_t * hHWDrawable )
  350. {
  351. Display * const dpy = (Display *) ndpy;
  352. XExtDisplayInfo *info = find_display (dpy);
  353. xXF86DRICreateDrawableReply rep;
  354. xXF86DRICreateDrawableReq *req;
  355. TRACE("CreateDrawable...");
  356. XF86DRICheckExtension (dpy, info, False);
  357. LockDisplay(dpy);
  358. GetReq(XF86DRICreateDrawable, req);
  359. req->reqType = info->codes->major_opcode;
  360. req->driReqType = X_XF86DRICreateDrawable;
  361. req->screen = screen;
  362. req->drawable = drawable;
  363. if (!_XReply(dpy, (xReply *)&rep, 0, xFalse)) {
  364. UnlockDisplay(dpy);
  365. SyncHandle();
  366. TRACE("CreateDrawable... return False");
  367. return False;
  368. }
  369. *hHWDrawable = rep.hHWDrawable;
  370. UnlockDisplay(dpy);
  371. SyncHandle();
  372. TRACE("CreateDrawable... return True");
  373. return True;
  374. }
  375. PUBLIC GLboolean XF86DRIDestroyDrawable( __DRInativeDisplay * ndpy, int screen,
  376. __DRIid drawable )
  377. {
  378. Display * const dpy = (Display *) ndpy;
  379. XExtDisplayInfo *info = find_display (dpy);
  380. xXF86DRIDestroyDrawableReq *req;
  381. TRACE("DestroyDrawable...");
  382. XF86DRICheckExtension (dpy, info, False);
  383. LockDisplay(dpy);
  384. GetReq(XF86DRIDestroyDrawable, req);
  385. req->reqType = info->codes->major_opcode;
  386. req->driReqType = X_XF86DRIDestroyDrawable;
  387. req->screen = screen;
  388. req->drawable = drawable;
  389. UnlockDisplay(dpy);
  390. SyncHandle();
  391. TRACE("DestroyDrawable... return True");
  392. return True;
  393. }
  394. PUBLIC Bool XF86DRIGetDrawableInfo(Display* dpy, int screen, Drawable drawable,
  395. unsigned int* index, unsigned int* stamp,
  396. int* X, int* Y, int* W, int* H,
  397. int* numClipRects, drm_clip_rect_t ** pClipRects,
  398. int* backX, int* backY,
  399. int* numBackClipRects, drm_clip_rect_t ** pBackClipRects )
  400. {
  401. XExtDisplayInfo *info = find_display (dpy);
  402. xXF86DRIGetDrawableInfoReply rep;
  403. xXF86DRIGetDrawableInfoReq *req;
  404. int total_rects;
  405. TRACE("GetDrawableInfo...");
  406. XF86DRICheckExtension (dpy, info, False);
  407. LockDisplay(dpy);
  408. GetReq(XF86DRIGetDrawableInfo, req);
  409. req->reqType = info->codes->major_opcode;
  410. req->driReqType = X_XF86DRIGetDrawableInfo;
  411. req->screen = screen;
  412. req->drawable = drawable;
  413. if (!_XReply(dpy, (xReply *)&rep, 1, xFalse))
  414. {
  415. UnlockDisplay(dpy);
  416. SyncHandle();
  417. TRACE("GetDrawableInfo... return False");
  418. return False;
  419. }
  420. *index = rep.drawableTableIndex;
  421. *stamp = rep.drawableTableStamp;
  422. *X = (int)rep.drawableX;
  423. *Y = (int)rep.drawableY;
  424. *W = (int)rep.drawableWidth;
  425. *H = (int)rep.drawableHeight;
  426. *numClipRects = rep.numClipRects;
  427. total_rects = *numClipRects;
  428. *backX = rep.backX;
  429. *backY = rep.backY;
  430. *numBackClipRects = rep.numBackClipRects;
  431. total_rects += *numBackClipRects;
  432. #if 0
  433. /* Because of the fix in Xserver/GL/dri/xf86dri.c, this check breaks
  434. * backwards compatibility (Because of the >> 2 shift) but the fix
  435. * enables multi-threaded apps to work.
  436. */
  437. if (rep.length != ((((SIZEOF(xXF86DRIGetDrawableInfoReply) -
  438. SIZEOF(xGenericReply) +
  439. total_rects * sizeof(drm_clip_rect_t)) + 3) & ~3) >> 2)) {
  440. _XEatData(dpy, rep.length);
  441. UnlockDisplay(dpy);
  442. SyncHandle();
  443. TRACE("GetDrawableInfo... return False");
  444. return False;
  445. }
  446. #endif
  447. if (*numClipRects) {
  448. int len = sizeof(drm_clip_rect_t) * (*numClipRects);
  449. *pClipRects = (drm_clip_rect_t *)Xcalloc(len, 1);
  450. if (*pClipRects)
  451. _XRead(dpy, (char*)*pClipRects, len);
  452. } else {
  453. *pClipRects = NULL;
  454. }
  455. if (*numBackClipRects) {
  456. int len = sizeof(drm_clip_rect_t) * (*numBackClipRects);
  457. *pBackClipRects = (drm_clip_rect_t *)Xcalloc(len, 1);
  458. if (*pBackClipRects)
  459. _XRead(dpy, (char*)*pBackClipRects, len);
  460. } else {
  461. *pBackClipRects = NULL;
  462. }
  463. UnlockDisplay(dpy);
  464. SyncHandle();
  465. TRACE("GetDrawableInfo... return True");
  466. return True;
  467. }
  468. PUBLIC Bool XF86DRIGetDeviceInfo(dpy, screen, hFrameBuffer,
  469. fbOrigin, fbSize, fbStride, devPrivateSize, pDevPrivate)
  470. Display* dpy;
  471. int screen;
  472. drm_handle_t * hFrameBuffer;
  473. int* fbOrigin;
  474. int* fbSize;
  475. int* fbStride;
  476. int* devPrivateSize;
  477. void** pDevPrivate;
  478. {
  479. XExtDisplayInfo *info = find_display (dpy);
  480. xXF86DRIGetDeviceInfoReply rep;
  481. xXF86DRIGetDeviceInfoReq *req;
  482. TRACE("GetDeviceInfo...");
  483. XF86DRICheckExtension (dpy, info, False);
  484. LockDisplay(dpy);
  485. GetReq(XF86DRIGetDeviceInfo, req);
  486. req->reqType = info->codes->major_opcode;
  487. req->driReqType = X_XF86DRIGetDeviceInfo;
  488. req->screen = screen;
  489. if (!_XReply(dpy, (xReply *)&rep, 0, xFalse)) {
  490. UnlockDisplay(dpy);
  491. SyncHandle();
  492. TRACE("GetDeviceInfo... return False");
  493. return False;
  494. }
  495. *hFrameBuffer = rep.hFrameBufferLow;
  496. if (sizeof(drm_handle_t) == 8) {
  497. int shift = 32; /* var to prevent warning on next line */
  498. *hFrameBuffer |= ((drm_handle_t) rep.hFrameBufferHigh) << shift;
  499. }
  500. *fbOrigin = rep.framebufferOrigin;
  501. *fbSize = rep.framebufferSize;
  502. *fbStride = rep.framebufferStride;
  503. *devPrivateSize = rep.devPrivateSize;
  504. if (rep.length) {
  505. if (!(*pDevPrivate = (void *)Xcalloc(rep.devPrivateSize, 1))) {
  506. _XEatData(dpy, ((rep.devPrivateSize+3) & ~3));
  507. UnlockDisplay(dpy);
  508. SyncHandle();
  509. TRACE("GetDeviceInfo... return False");
  510. return False;
  511. }
  512. _XRead(dpy, (char*)*pDevPrivate, rep.devPrivateSize);
  513. } else {
  514. *pDevPrivate = NULL;
  515. }
  516. UnlockDisplay(dpy);
  517. SyncHandle();
  518. TRACE("GetDeviceInfo... return True");
  519. return True;
  520. }
  521. PUBLIC Bool XF86DRIOpenFullScreen(dpy, screen, drawable)
  522. Display* dpy;
  523. int screen;
  524. Drawable drawable;
  525. {
  526. /* This function and the underlying X protocol are deprecated.
  527. */
  528. (void) dpy;
  529. (void) screen;
  530. (void) drawable;
  531. return False;
  532. }
  533. PUBLIC Bool XF86DRICloseFullScreen(dpy, screen, drawable)
  534. Display* dpy;
  535. int screen;
  536. Drawable drawable;
  537. {
  538. /* This function and the underlying X protocol are deprecated.
  539. */
  540. (void) dpy;
  541. (void) screen;
  542. (void) drawable;
  543. return True;
  544. }
  545. #endif /* GLX_DIRECT_RENDERING */