1 /* $XFree86: xc/lib/GL/dri/xf86dristr.h,v 1.10 2002/10/30 12:51:25 alanh Exp $ */
2 /**************************************************************************
4 Copyright 1998-1999 Precision Insight, Inc., Cedar Park, Texas.
5 Copyright 2000 VA Linux Systems, Inc.
8 Permission is hereby granted, free of charge, to any person obtaining a
9 copy of this software and associated documentation files (the
10 "Software"), to deal in the Software without restriction, including
11 without limitation the rights to use, copy, modify, merge, publish,
12 distribute, sub license, and/or sell copies of the Software, and to
13 permit persons to whom the Software is furnished to do so, subject to
14 the following conditions:
16 The above copyright notice and this permission notice (including the
17 next paragraph) shall be included in all copies or substantial portions
20 THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
21 OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
22 MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.
23 IN NO EVENT SHALL PRECISION INSIGHT AND/OR ITS SUPPLIERS BE LIABLE FOR
24 ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
25 TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
26 SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
28 **************************************************************************/
32 * Kevin E. Martin <martin@valinux.com>
33 * Jens Owen <jens@tungstengraphics.com>
34 * Rickard E. (Rik) Fiath <faith@valinux.com>
38 #ifndef _XF86DRISTR_H_
39 #define _XF86DRISTR_H_
43 #define XF86DRINAME "XFree86-DRI"
45 /* The DRI version number. This was originally set to be the same as the
46 * XFree86 version number. However, this version is really independent of
47 * the XFree86 version.
51 * 4.0.1: Patch to bump clipstamp when windows are destroyed, 28 May 02
52 * 4.1.0: Add transition from single to multi in DRMInfo rec, 24 Jun 02
54 #define XF86DRI_MAJOR_VERSION 4
55 #define XF86DRI_MINOR_VERSION 1
56 #define XF86DRI_PATCH_VERSION 0
58 typedef struct _XF86DRIQueryVersion
60 CARD8 reqType
; /* always DRIReqCode */
61 CARD8 driReqType
; /* always X_DRIQueryVersion */
63 } xXF86DRIQueryVersionReq
;
65 #define sz_xXF86DRIQueryVersionReq 4
69 BYTE type
; /* X_Reply */
71 CARD16 sequenceNumber B16
;
73 CARD16 majorVersion B16
; /* major version of DRI protocol */
74 CARD16 minorVersion B16
; /* minor version of DRI protocol */
75 CARD32 patchVersion B32
; /* patch version of DRI protocol */
80 } xXF86DRIQueryVersionReply
;
82 #define sz_xXF86DRIQueryVersionReply 32
84 typedef struct _XF86DRIQueryDirectRenderingCapable
86 CARD8 reqType
; /* always DRIReqCode */
87 CARD8 driReqType
; /* X_DRIQueryDirectRenderingCapable */
90 } xXF86DRIQueryDirectRenderingCapableReq
;
92 #define sz_xXF86DRIQueryDirectRenderingCapableReq 8
96 BYTE type
; /* X_Reply */
98 CARD16 sequenceNumber B16
;
109 } xXF86DRIQueryDirectRenderingCapableReply
;
111 #define sz_xXF86DRIQueryDirectRenderingCapableReply 32
113 typedef struct _XF86DRIOpenConnection
115 CARD8 reqType
; /* always DRIReqCode */
116 CARD8 driReqType
; /* always X_DRIOpenConnection */
119 } xXF86DRIOpenConnectionReq
;
121 #define sz_xXF86DRIOpenConnectionReq 8
125 BYTE type
; /* X_Reply */
127 CARD16 sequenceNumber B16
;
129 CARD32 hSAREALow B32
;
130 CARD32 hSAREAHigh B32
;
131 CARD32 busIdStringLength B32
;
135 } xXF86DRIOpenConnectionReply
;
137 #define sz_xXF86DRIOpenConnectionReply 32
139 typedef struct _XF86DRIAuthConnection
141 CARD8 reqType
; /* always DRIReqCode */
142 CARD8 driReqType
; /* always X_DRICloseConnection */
146 } xXF86DRIAuthConnectionReq
;
148 #define sz_xXF86DRIAuthConnectionReq 12
154 CARD16 sequenceNumber B16
;
156 CARD32 authenticated B32
;
162 } xXF86DRIAuthConnectionReply
;
164 #define zx_xXF86DRIAuthConnectionReply 32
166 typedef struct _XF86DRICloseConnection
168 CARD8 reqType
; /* always DRIReqCode */
169 CARD8 driReqType
; /* always X_DRICloseConnection */
172 } xXF86DRICloseConnectionReq
;
174 #define sz_xXF86DRICloseConnectionReq 8
176 typedef struct _XF86DRIGetClientDriverName
178 CARD8 reqType
; /* always DRIReqCode */
179 CARD8 driReqType
; /* always X_DRIGetClientDriverName */
182 } xXF86DRIGetClientDriverNameReq
;
184 #define sz_xXF86DRIGetClientDriverNameReq 8
188 BYTE type
; /* X_Reply */
190 CARD16 sequenceNumber B16
;
192 CARD32 ddxDriverMajorVersion B32
;
193 CARD32 ddxDriverMinorVersion B32
;
194 CARD32 ddxDriverPatchVersion B32
;
195 CARD32 clientDriverNameLength B32
;
198 } xXF86DRIGetClientDriverNameReply
;
200 #define sz_xXF86DRIGetClientDriverNameReply 32
202 typedef struct _XF86DRICreateContext
204 CARD8 reqType
; /* always DRIReqCode */
205 CARD8 driReqType
; /* always X_DRICreateContext */
210 } xXF86DRICreateContextReq
;
212 #define sz_xXF86DRICreateContextReq 16
216 BYTE type
; /* X_Reply */
218 CARD16 sequenceNumber B16
;
220 CARD32 hHWContext B32
;
226 } xXF86DRICreateContextReply
;
228 #define sz_xXF86DRICreateContextReply 32
230 typedef struct _XF86DRIDestroyContext
232 CARD8 reqType
; /* always DRIReqCode */
233 CARD8 driReqType
; /* always X_DRIDestroyContext */
237 } xXF86DRIDestroyContextReq
;
239 #define sz_xXF86DRIDestroyContextReq 12
241 typedef struct _XF86DRICreateDrawable
243 CARD8 reqType
; /* always DRIReqCode */
244 CARD8 driReqType
; /* always X_DRICreateDrawable */
248 } xXF86DRICreateDrawableReq
;
250 #define sz_xXF86DRICreateDrawableReq 12
254 BYTE type
; /* X_Reply */
256 CARD16 sequenceNumber B16
;
258 CARD32 hHWDrawable B32
;
264 } xXF86DRICreateDrawableReply
;
266 #define sz_xXF86DRICreateDrawableReply 32
268 typedef struct _XF86DRIDestroyDrawable
270 CARD8 reqType
; /* always DRIReqCode */
271 CARD8 driReqType
; /* always X_DRIDestroyDrawable */
275 } xXF86DRIDestroyDrawableReq
;
277 #define sz_xXF86DRIDestroyDrawableReq 12
279 typedef struct _XF86DRIGetDrawableInfo
281 CARD8 reqType
; /* always DRIReqCode */
282 CARD8 driReqType
; /* always X_DRIGetDrawableInfo */
286 } xXF86DRIGetDrawableInfoReq
;
288 #define sz_xXF86DRIGetDrawableInfoReq 12
292 BYTE type
; /* X_Reply */
294 CARD16 sequenceNumber B16
;
296 CARD32 drawableTableIndex B32
;
297 CARD32 drawableTableStamp B32
;
300 INT16 drawableWidth B16
;
301 INT16 drawableHeight B16
;
302 CARD32 numClipRects B32
;
305 CARD32 numBackClipRects B32
;
306 } xXF86DRIGetDrawableInfoReply
;
308 #define sz_xXF86DRIGetDrawableInfoReply 36
310 typedef struct _XF86DRIGetDeviceInfo
312 CARD8 reqType
; /* always DRIReqCode */
313 CARD8 driReqType
; /* always X_DRIGetDeviceInfo */
316 } xXF86DRIGetDeviceInfoReq
;
318 #define sz_xXF86DRIGetDeviceInfoReq 8
322 BYTE type
; /* X_Reply */
324 CARD16 sequenceNumber B16
;
326 CARD32 hFrameBufferLow B32
;
327 CARD32 hFrameBufferHigh B32
;
328 CARD32 framebufferOrigin B32
;
329 CARD32 framebufferSize B32
;
330 CARD32 framebufferStride B32
;
331 CARD32 devPrivateSize B32
;
332 } xXF86DRIGetDeviceInfoReply
;
334 #define sz_xXF86DRIGetDeviceInfoReply 32
336 typedef struct _XF86DRIOpenFullScreen
338 CARD8 reqType
; /* always DRIReqCode */
339 CARD8 driReqType
; /* always X_DRIOpenFullScreen */
343 } xXF86DRIOpenFullScreenReq
;
345 #define sz_xXF86DRIOpenFullScreenReq 12
351 CARD16 sequenceNumber B16
;
353 CARD32 isFullScreen B32
;
359 } xXF86DRIOpenFullScreenReply
;
361 #define sz_xXF86DRIOpenFullScreenReply 32
363 typedef struct _XF86DRICloseFullScreen
365 CARD8 reqType
; /* always DRIReqCode */
366 CARD8 driReqType
; /* always X_DRICloseFullScreen */
370 } xXF86DRICloseFullScreenReq
;
372 #define sz_xXF86DRICloseFullScreenReq 12
378 CARD16 sequenceNumber B16
;
386 } xXF86DRICloseFullScreenReply
;
388 #define sz_xXF86DRICloseFullScreenReply 32
390 #endif /* _XF86DRISTR_H_ */