Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2025-03-13 09:29:36

0001 /******************************************************************************
0002  *
0003  * Copyright (c) 1994, 1995  Hewlett-Packard Company
0004  *
0005  * Permission is hereby granted, free of charge, to any person obtaining
0006  * a copy of this software and associated documentation files (the
0007  * "Software"), to deal in the Software without restriction, including
0008  * without limitation the rights to use, copy, modify, merge, publish,
0009  * distribute, sublicense, and/or sell copies of the Software, and to
0010  * permit persons to whom the Software is furnished to do so, subject to
0011  * the following conditions:
0012  *
0013  * The above copyright notice and this permission notice shall be included
0014  * in all copies or substantial portions of the Software.
0015  *
0016  * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
0017  * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
0018  * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
0019  * IN NO EVENT SHALL HEWLETT-PACKARD COMPANY BE LIABLE FOR ANY CLAIM,
0020  * DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
0021  * OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR
0022  * THE USE OR OTHER DEALINGS IN THE SOFTWARE.
0023  *
0024  * Except as contained in this notice, the name of the Hewlett-Packard
0025  * Company shall not be used in advertising or otherwise to promote the
0026  * sale, use or other dealings in this Software without prior written
0027  * authorization from the Hewlett-Packard Company.
0028  *
0029  *     Header file for Xlib-related DBE
0030  *
0031  *****************************************************************************/
0032 
0033 #ifndef DBE_PROTO_H
0034 #define DBE_PROTO_H
0035 
0036 #include <X11/extensions/dbe.h>
0037 
0038 /* Request values used in (S)ProcDbeDispatch() */
0039 #define X_DbeGetVersion                 0
0040 #define X_DbeAllocateBackBufferName     1
0041 #define X_DbeDeallocateBackBufferName   2
0042 #define X_DbeSwapBuffers                3
0043 #define X_DbeBeginIdiom                 4
0044 #define X_DbeEndIdiom                   5
0045 #define X_DbeGetVisualInfo              6
0046 #define X_DbeGetBackBufferAttributes    7
0047 
0048 typedef CARD8  xDbeSwapAction;
0049 typedef CARD32 xDbeBackBuffer;
0050 
0051 /* TYPEDEFS */
0052 
0053 /* Protocol data types */
0054 
0055 typedef struct
0056 {
0057     CARD32      window B32; /* window      */
0058     xDbeSwapAction  swapAction; /* swap action */
0059     CARD8       pad1;       /* unused      */
0060     CARD16      pad2 B16;
0061 
0062 } xDbeSwapInfo;
0063 
0064 typedef struct
0065 {
0066     CARD32  visualID B32;   /* associated visual      */
0067     CARD8   depth;      /* depth of visual        */
0068     CARD8   perfLevel;  /* performance level hint */
0069     CARD16  pad1 B16;
0070 
0071 } xDbeVisInfo;
0072 #define sz_xDbeVisInfo  8
0073 
0074 typedef struct
0075 {
0076     CARD32  n B32;  /* number of visual info items in list  */
0077 
0078 } xDbeScreenVisInfo;    /* followed by n xDbeVisInfo items */
0079 
0080 typedef struct
0081 {
0082     CARD32  window B32; /* window */
0083 
0084 } xDbeBufferAttributes;
0085 
0086 
0087 /* Requests and replies */
0088 
0089 typedef struct
0090 {
0091     CARD8   reqType;    /* major-opcode: always codes->major_opcode */
0092     CARD8   dbeReqType; /* minor-opcode: always X_DbeGetVersion (0) */
0093     CARD16  length B16; /* request length: (2)                      */
0094     CARD8   majorVersion;   /* client-major-version                     */
0095     CARD8   minorVersion;   /* client-minor-version                     */
0096     CARD16  unused B16; /* unused                                   */
0097 
0098 } xDbeGetVersionReq;
0099 #define sz_xDbeGetVersionReq    8
0100 
0101 typedef struct
0102 {
0103     BYTE    type;           /* Reply: X_Reply (1)   */
0104     CARD8   unused;         /* unused               */
0105     CARD16  sequenceNumber B16; /* sequence number      */
0106     CARD32  length B32;     /* reply length: (0)    */
0107     CARD8   majorVersion;       /* server-major-version */
0108     CARD8   minorVersion;       /* server-minor-version */
0109     CARD16  pad1 B16;       /* unused               */
0110     CARD32  pad2 B32;
0111     CARD32  pad3 B32;
0112     CARD32  pad4 B32;
0113     CARD32  pad5 B32;
0114     CARD32  pad6 B32;
0115 
0116 } xDbeGetVersionReply;
0117 #define sz_xDbeGetVersionReply  32
0118 
0119 typedef struct
0120 {
0121     CARD8       reqType;    /* major-opcode: codes->major_opcode */
0122     CARD8       dbeReqType; /* X_DbeAllocateBackBufferName (1)   */
0123     CARD16      length B16; /* request length: (4)               */
0124     CARD32      window B32; /* window                            */
0125     xDbeBackBuffer  buffer B32; /* back buffer name                  */
0126     xDbeSwapAction  swapAction; /* swap action hint                  */
0127     CARD8       pad1;       /* unused                            */
0128     CARD16      pad2 B16;
0129 
0130 } xDbeAllocateBackBufferNameReq;
0131 #define sz_xDbeAllocateBackBufferNameReq    16
0132 
0133 typedef struct
0134 {
0135     CARD8       reqType;    /* major-opcode: codes->major_opcode */
0136     CARD8       dbeReqType; /* X_DbeDeallocateBackBufferName (2) */
0137     CARD16      length B16; /* request length: (2)               */
0138     xDbeBackBuffer  buffer B32; /* back buffer name                  */
0139 
0140 } xDbeDeallocateBackBufferNameReq;
0141 #define sz_xDbeDeallocateBackBufferNameReq  8
0142 
0143 typedef struct
0144 {
0145     CARD8   reqType;    /* major-opcode: always codes->major_opcode  */
0146     CARD8   dbeReqType; /* minor-opcode: always X_DbeSwapBuffers (3) */
0147     CARD16  length B16; /* request length: (2+2n)                    */
0148     CARD32  n B32;      /* n, number of window/swap action pairs     */
0149 
0150 } xDbeSwapBuffersReq;       /* followed by n window/swap action pairs    */
0151 #define sz_xDbeSwapBuffersReq   8
0152 
0153 typedef struct
0154 {
0155     CARD8   reqType;    /* major-opcode: always codes->major_opcode */
0156     CARD8   dbeReqType; /* minor-opcode: always X_DbeBeginIdom (4)  */
0157     CARD16  length B16; /* request length: (1)                      */
0158 
0159 } xDbeBeginIdiomReq;
0160 #define sz_xDbeBeginIdiomReq    4
0161 
0162 typedef struct
0163 {
0164     CARD8   reqType;    /* major-opcode: always codes->major_opcode */
0165     CARD8   dbeReqType; /* minor-opcode: always X_DbeEndIdom (5)    */
0166     CARD16  length B16; /* request length: (1)                      */
0167 
0168 } xDbeEndIdiomReq;
0169 #define sz_xDbeEndIdiomReq  4
0170 
0171 typedef struct
0172 {
0173     CARD8   reqType;    /* always codes->major_opcode     */
0174     CARD8   dbeReqType; /* always X_DbeGetVisualInfo (6)  */
0175     CARD16  length B16; /* request length: (2+n)          */
0176     CARD32  n B32;      /* n, number of drawables in list */
0177 
0178 } xDbeGetVisualInfoReq;     /* followed by n drawables        */
0179 #define sz_xDbeGetVisualInfoReq 8
0180 
0181 typedef struct
0182 {
0183     BYTE    type;           /* Reply: X_Reply (1)                */
0184     CARD8   unused;         /* unused                            */
0185     CARD16  sequenceNumber B16; /* sequence number                   */
0186     CARD32  length B32;     /* reply length                      */
0187     CARD32  m;          /* m, number of visual infos in list */
0188     CARD32  pad1 B32;       /* unused                            */
0189     CARD32  pad2 B32;
0190     CARD32  pad3 B32;
0191     CARD32  pad4 B32;
0192     CARD32  pad5 B32;
0193 
0194 } xDbeGetVisualInfoReply;       /* followed by m visual infos        */
0195 #define sz_xDbeGetVisualInfoReply   32
0196 
0197 typedef struct
0198 {
0199     CARD8       reqType;    /* always codes->major_opcode       */
0200     CARD8       dbeReqType; /* X_DbeGetBackBufferAttributes (7) */
0201     CARD16      length B16; /* request length: (2)              */
0202     xDbeBackBuffer  buffer B32; /* back buffer name                 */
0203 
0204 } xDbeGetBackBufferAttributesReq;
0205 #define sz_xDbeGetBackBufferAttributesReq   8
0206 
0207 typedef struct
0208 {
0209     BYTE    type;           /* Reply: X_Reply (1) */
0210     CARD8   unused;         /* unused             */
0211     CARD16  sequenceNumber B16; /* sequence number    */
0212     CARD32  length B32;     /* reply length: (0)  */
0213     CARD32  attributes;     /* attributes         */
0214     CARD32  pad1 B32;       /* unused             */
0215     CARD32  pad2 B32;
0216     CARD32  pad3 B32;
0217     CARD32  pad4 B32;
0218     CARD32  pad5 B32;
0219 
0220 } xDbeGetBackBufferAttributesReply;
0221 #define sz_xDbeGetBackBufferAttributesReply 32
0222 
0223 #endif /* DBE_PROTO_H */
0224