1 /**************************************************************************
3 Copyright 1998-1999 Precision Insight, Inc., Cedar Park, Texas.
4 Copyright 2000 VA Linux Systems, Inc.
7 Permission is hereby granted, free of charge, to any person obtaining a
8 copy of this software and associated documentation files (the
9 "Software"), to deal in the Software without restriction, including
10 without limitation the rights to use, copy, modify, merge, publish,
11 distribute, sub license, and/or sell copies of the Software, and to
12 permit persons to whom the Software is furnished to do so, subject to
13 the following conditions:
15 The above copyright notice and this permission notice (including the
16 next paragraph) shall be included in all copies or substantial portions
19 THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
20 OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
21 MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.
22 IN NO EVENT SHALL PRECISION INSIGHT AND/OR ITS SUPPLIERS BE LIABLE FOR
23 ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
24 TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
25 SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
27 **************************************************************************/
31 * Kevin E. Martin <martin@valinux.com>
32 * Jens Owen <jens@tungstengraphics.com>
33 * Rickard E. (Rik) Fiath <faith@valinux.com>
37 #ifndef _XF86DRISTR_H_
38 #define _XF86DRISTR_H_
42 #define XF86DRINAME "XFree86-DRI"
44 /* The DRI version number. This was originally set to be the same of the
45 * XFree86 version number. However, this version is really indepedent of
46 * the XFree86 version.
50 * 4.0.1: Patch to bump clipstamp when windows are destroyed, 28 May 02
51 * 4.1.0: Add transition from single to multi in DRMInfo rec, 24 Jun 02
53 #define XF86DRI_MAJOR_VERSION 4
54 #define XF86DRI_MINOR_VERSION 1
55 #define XF86DRI_PATCH_VERSION 0
57 typedef struct _XF86DRIQueryVersion
59 CARD8 reqType
; /* always DRIReqCode */
60 CARD8 driReqType
; /* always X_DRIQueryVersion */
62 } xXF86DRIQueryVersionReq
;
63 #define sz_xXF86DRIQueryVersionReq 4
67 BYTE type
; /* X_Reply */
69 CARD16 sequenceNumber B16
;
71 CARD16 majorVersion B16
; /* major version of DRI protocol */
72 CARD16 minorVersion B16
; /* minor version of DRI protocol */
73 CARD32 patchVersion B32
; /* patch version of DRI protocol */
78 } xXF86DRIQueryVersionReply
;
79 #define sz_xXF86DRIQueryVersionReply 32
81 typedef struct _XF86DRIQueryDirectRenderingCapable
83 CARD8 reqType
; /* always DRIReqCode */
84 CARD8 driReqType
; /* X_DRIQueryDirectRenderingCapable */
87 } xXF86DRIQueryDirectRenderingCapableReq
;
88 #define sz_xXF86DRIQueryDirectRenderingCapableReq 8
92 BYTE type
; /* X_Reply */
94 CARD16 sequenceNumber B16
;
105 } xXF86DRIQueryDirectRenderingCapableReply
;
106 #define sz_xXF86DRIQueryDirectRenderingCapableReply 32
108 typedef struct _XF86DRIOpenConnection
110 CARD8 reqType
; /* always DRIReqCode */
111 CARD8 driReqType
; /* always X_DRIOpenConnection */
114 } xXF86DRIOpenConnectionReq
;
115 #define sz_xXF86DRIOpenConnectionReq 8
119 BYTE type
; /* X_Reply */
121 CARD16 sequenceNumber B16
;
123 CARD32 hSAREALow B32
;
124 CARD32 hSAREAHigh B32
;
125 CARD32 busIdStringLength B32
;
129 } xXF86DRIOpenConnectionReply
;
130 #define sz_xXF86DRIOpenConnectionReply 32
132 typedef struct _XF86DRIAuthConnection
134 CARD8 reqType
; /* always DRIReqCode */
135 CARD8 driReqType
; /* always X_DRICloseConnection */
139 } xXF86DRIAuthConnectionReq
;
140 #define sz_xXF86DRIAuthConnectionReq 12
146 CARD16 sequenceNumber B16
;
148 CARD32 authenticated B32
;
154 } xXF86DRIAuthConnectionReply
;
155 #define zx_xXF86DRIAuthConnectionReply 32
157 typedef struct _XF86DRICloseConnection
159 CARD8 reqType
; /* always DRIReqCode */
160 CARD8 driReqType
; /* always X_DRICloseConnection */
163 } xXF86DRICloseConnectionReq
;
164 #define sz_xXF86DRICloseConnectionReq 8
166 typedef struct _XF86DRIGetClientDriverName
168 CARD8 reqType
; /* always DRIReqCode */
169 CARD8 driReqType
; /* always X_DRIGetClientDriverName */
172 } xXF86DRIGetClientDriverNameReq
;
173 #define sz_xXF86DRIGetClientDriverNameReq 8
177 BYTE type
; /* X_Reply */
179 CARD16 sequenceNumber B16
;
181 CARD32 ddxDriverMajorVersion B32
;
182 CARD32 ddxDriverMinorVersion B32
;
183 CARD32 ddxDriverPatchVersion B32
;
184 CARD32 clientDriverNameLength B32
;
187 } xXF86DRIGetClientDriverNameReply
;
188 #define sz_xXF86DRIGetClientDriverNameReply 32
190 typedef struct _XF86DRICreateContext
192 CARD8 reqType
; /* always DRIReqCode */
193 CARD8 driReqType
; /* always X_DRICreateContext */
198 } xXF86DRICreateContextReq
;
199 #define sz_xXF86DRICreateContextReq 16
203 BYTE type
; /* X_Reply */
205 CARD16 sequenceNumber B16
;
207 CARD32 hHWContext B32
;
213 } xXF86DRICreateContextReply
;
214 #define sz_xXF86DRICreateContextReply 32
216 typedef struct _XF86DRIDestroyContext
218 CARD8 reqType
; /* always DRIReqCode */
219 CARD8 driReqType
; /* always X_DRIDestroyContext */
223 } xXF86DRIDestroyContextReq
;
224 #define sz_xXF86DRIDestroyContextReq 12
226 typedef struct _XF86DRICreateDrawable
228 CARD8 reqType
; /* always DRIReqCode */
229 CARD8 driReqType
; /* always X_DRICreateDrawable */
233 } xXF86DRICreateDrawableReq
;
234 #define sz_xXF86DRICreateDrawableReq 12
238 BYTE type
; /* X_Reply */
240 CARD16 sequenceNumber B16
;
242 CARD32 hHWDrawable B32
;
248 } xXF86DRICreateDrawableReply
;
249 #define sz_xXF86DRICreateDrawableReply 32
251 typedef struct _XF86DRIDestroyDrawable
253 CARD8 reqType
; /* always DRIReqCode */
254 CARD8 driReqType
; /* always X_DRIDestroyDrawable */
258 } xXF86DRIDestroyDrawableReq
;
259 #define sz_xXF86DRIDestroyDrawableReq 12
261 typedef struct _XF86DRIGetDrawableInfo
263 CARD8 reqType
; /* always DRIReqCode */
264 CARD8 driReqType
; /* always X_DRIGetDrawableInfo */
268 } xXF86DRIGetDrawableInfoReq
;
269 #define sz_xXF86DRIGetDrawableInfoReq 12
273 BYTE type
; /* X_Reply */
275 CARD16 sequenceNumber B16
;
277 CARD32 drawableTableIndex B32
;
278 CARD32 drawableTableStamp B32
;
281 INT16 drawableWidth B16
;
282 INT16 drawableHeight B16
;
283 CARD32 numClipRects B32
;
286 CARD32 numBackClipRects B32
;
287 } xXF86DRIGetDrawableInfoReply
;
289 #define sz_xXF86DRIGetDrawableInfoReply 36
292 typedef struct _XF86DRIGetDeviceInfo
294 CARD8 reqType
; /* always DRIReqCode */
295 CARD8 driReqType
; /* always X_DRIGetDeviceInfo */
298 } xXF86DRIGetDeviceInfoReq
;
299 #define sz_xXF86DRIGetDeviceInfoReq 8
303 BYTE type
; /* X_Reply */
305 CARD16 sequenceNumber B16
;
307 CARD32 hFrameBufferLow B32
;
308 CARD32 hFrameBufferHigh B32
;
309 CARD32 framebufferOrigin B32
;
310 CARD32 framebufferSize B32
;
311 CARD32 framebufferStride B32
;
312 CARD32 devPrivateSize B32
;
313 } xXF86DRIGetDeviceInfoReply
;
314 #define sz_xXF86DRIGetDeviceInfoReply 32
316 typedef struct _XF86DRIOpenFullScreen
318 CARD8 reqType
; /* always DRIReqCode */
319 CARD8 driReqType
; /* always X_DRIOpenFullScreen */
323 } xXF86DRIOpenFullScreenReq
;
324 #define sz_xXF86DRIOpenFullScreenReq 12
330 CARD16 sequenceNumber B16
;
332 CARD32 isFullScreen B32
;
338 } xXF86DRIOpenFullScreenReply
;
339 #define sz_xXF86DRIOpenFullScreenReply 32
341 typedef struct _XF86DRICloseFullScreen
343 CARD8 reqType
; /* always DRIReqCode */
344 CARD8 driReqType
; /* always X_DRICloseFullScreen */
348 } xXF86DRICloseFullScreenReq
;
349 #define sz_xXF86DRICloseFullScreenReq 12
355 CARD16 sequenceNumber B16
;
363 } xXF86DRICloseFullScreenReply
;
364 #define sz_xXF86DRICloseFullScreenReply 32
367 #endif /* _XF86DRISTR_H_ */