Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2025-01-18 10:14:18

0001 /*
0002 Copyright 1989, 1998  The Open Group
0003 
0004 Permission to use, copy, modify, distribute, and sell this software and its
0005 documentation for any purpose is hereby granted without fee, provided that
0006 the above copyright notice appear in all copies and that both that
0007 copyright notice and this permission notice appear in supporting
0008 documentation.
0009 
0010 The above copyright notice and this permission notice shall be included in
0011 all copies or substantial portions of the Software.
0012 
0013 THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
0014 IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
0015 FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.  IN NO EVENT SHALL THE
0016 OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
0017 AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
0018 CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
0019 
0020 Except as contained in this notice, the name of The Open Group shall not be
0021 used in advertising or otherwise to promote the sale, use or other dealings
0022 in this Software without prior written authorization from The Open Group.
0023  */
0024 
0025 #ifndef _MULTIBUFPROTO_H_
0026 #define _MULTIBUFPROTO_H_
0027 
0028 #include <X11/extensions/multibufconst.h>
0029 
0030 /*
0031  * Protocol requests constants and alignment values
0032  */
0033 
0034 #define Window CARD32
0035 #define Drawable CARD32
0036 #define VisualID CARD32
0037 #define Multibuffer CARD32
0038 
0039 #define X_MbufGetBufferVersion      0
0040 #define X_MbufCreateImageBuffers    1
0041 #define X_MbufDestroyImageBuffers   2
0042 #define X_MbufDisplayImageBuffers   3
0043 #define X_MbufSetMBufferAttributes  4
0044 #define X_MbufGetMBufferAttributes  5
0045 #define X_MbufSetBufferAttributes   6
0046 #define X_MbufGetBufferAttributes   7
0047 #define X_MbufGetBufferInfo     8
0048 #define X_MbufCreateStereoWindow    9
0049 #define X_MbufClearImageBufferArea  10
0050 
0051 
0052 typedef struct xMbufBufferInfo {
0053     CARD32  visualID B32;       /* associated visual */
0054     CARD16  maxBuffers B16;     /* maximum supported buffers */
0055     CARD8   depth;          /* depth of visual (redundant) */
0056     CARD8   unused;
0057 } xMbufBufferInfo;
0058 #define sz_xMbufBufferInfo 8
0059 
0060 typedef struct {
0061     BYTE    type;
0062     BYTE    unused;
0063     CARD16  sequenceNumber B16;
0064     CARD32  buffer B32;         /* affected buffer */
0065     BYTE    state;          /* current status */
0066     CARD8   unused1;
0067     CARD16  unused2 B16;
0068     CARD32  unused3 B32;
0069     CARD32  unused4 B32;
0070     CARD32  unused5 B32;
0071     CARD32  unused6 B32;
0072     CARD32  unused7 B32;
0073 } xMbufClobberNotifyEvent;
0074 
0075 typedef struct {
0076     BYTE    type;
0077     BYTE    unused;
0078     CARD16  sequenceNumber B16;
0079     CARD32  buffer B32;         /* affected buffer */
0080     CARD32  timeStamp B32;      /* update time */
0081     CARD32  unused1 B32;
0082     CARD32  unused2 B32;
0083     CARD32  unused3 B32;
0084     CARD32  unused4 B32;
0085     CARD32  unused5 B32;
0086     CARD32  unused6 B32;
0087 } xMbufUpdateNotifyEvent;
0088 
0089 typedef struct {
0090     CARD8   reqType;        /* always codes->major_opcode */
0091     CARD8   mbufReqType;        /* always X_MbufGetBufferVersion */
0092     CARD16  length B16;
0093 } xMbufGetBufferVersionReq;
0094 #define sz_xMbufGetBufferVersionReq 4
0095 
0096 typedef struct {
0097     BYTE    type;           /* X_Reply */
0098     CARD8   unused;         /* not used */
0099     CARD16  sequenceNumber B16;
0100     CARD32  length B32;
0101     CARD8   majorVersion;   /* major version of Multi-Buffering protocol */
0102     CARD8   minorVersion;   /* minor version of Multi-Buffering protocol */
0103     CARD16  pad1 B16;
0104     CARD32  pad2 B32;
0105     CARD32  pad3 B32;
0106     CARD32  pad4 B32;
0107     CARD32  pad5 B32;
0108     CARD32  pad6 B32;
0109 } xMbufGetBufferVersionReply;
0110 #define sz_xMbufGetBufferVersionReply   32
0111 
0112 typedef struct {
0113     CARD8   reqType;    /* always codes->major_opcode */
0114     CARD8   mbufReqType;    /* always X_MbufCreateImageBuffers */
0115     CARD16  length B16;
0116     CARD32  window B32; /* associated window */
0117     CARD8   updateAction;   /* action at update */
0118     CARD8   updateHint; /* hint as to frequency of updates */
0119     CARD16  unused;
0120 } xMbufCreateImageBuffersReq;   /* followed by buffer ids */
0121 #define sz_xMbufCreateImageBuffersReq   12
0122 
0123 typedef struct {
0124     BYTE    type;           /* X_Reply */
0125     CARD8   unused;         /* not used */
0126     CARD16  sequenceNumber B16;
0127     CARD32  length B32;
0128     CARD16  numberBuffer B16;   /* number successfully allocated */
0129     CARD16  unused1 B16;
0130     CARD32  unused2 B32;
0131     CARD32  unused3 B32;
0132     CARD32  unused4 B32;
0133     CARD32  unused5 B32;
0134     CARD32  unused6 B32;
0135 } xMbufCreateImageBuffersReply;
0136 #define sz_xMbufCreateImageBuffersReply 32
0137 
0138 typedef struct {
0139     CARD8   reqType;    /* always codes->major_opcode */
0140     CARD8   mbufReqType;    /* always X_MbufDestroyImageBuffers */
0141     CARD16  length B16;
0142     CARD32  window B32; /* associated window */
0143 } xMbufDestroyImageBuffersReq;
0144 #define sz_xMbufDestroyImageBuffersReq  8
0145 
0146 typedef struct {
0147     CARD8   reqType;    /* always codes->major_opcode */
0148     CARD8   mbufReqType;    /* always X_MbufDisplayImageBuffers */
0149     CARD16  length B16;
0150     CARD16  minDelay B16;   /* minimum time between last update and now */
0151     CARD16  maxDelay B16;   /* maximum time between last update and now */
0152 } xMbufDisplayImageBuffersReq;  /* followed by list of buffers */
0153 #define sz_xMbufDisplayImageBuffersReq  8
0154 
0155 typedef struct {
0156     CARD8   reqType;    /* always codes->major_opcode */
0157     CARD8   mbufReqType;    /* always X_MbufSetMBufferAttributes */
0158     CARD16  length B16;
0159     CARD32  window B32; /* associated window */
0160     CARD32  valueMask B32;  /* modified entries */
0161 } xMbufSetMBufferAttributesReq; /* followed by values */
0162 #define sz_xMbufSetMBufferAttributesReq 12
0163 
0164 typedef struct {
0165     CARD8   reqType;    /* always codes->major_opcode */
0166     CARD8   mbufReqType;    /* always X_MbufGetMBufferAttributes */
0167     CARD16  length B16;
0168     CARD32  window B32; /* associated window */
0169 } xMbufGetMBufferAttributesReq;
0170 #define sz_xMbufGetMBufferAttributesReq 8
0171 
0172 typedef struct {
0173     BYTE    type;           /* X_Reply */
0174     CARD8   unused;         /* not used */
0175     CARD16  sequenceNumber B16;
0176     CARD32  length B32;
0177     CARD16  displayedBuffer B16;    /* currently visible buffer */
0178     CARD8   updateAction;
0179     CARD8   updateHint;
0180     CARD8   windowMode;
0181     CARD8   unused0;
0182     CARD16  unused1 B16;
0183     CARD32  unused2 B32;
0184     CARD32  unused3 B32;
0185     CARD32  unused4 B32;
0186     CARD32  unused5 B32;
0187 } xMbufGetMBufferAttributesReply;
0188 #define sz_xMbufGetMBufferAttributesReply 32
0189 
0190 typedef struct {
0191     CARD8   reqType;    /* always codes->major_opcode */
0192     CARD8   mbufReqType;    /* always X_MbufSetBufferAttributes */
0193     CARD16  length B16;
0194     CARD32  buffer B32;
0195     CARD32  valueMask B32;
0196 } xMbufSetBufferAttributesReq;  /* followed by values */
0197 #define sz_xMbufSetBufferAttributesReq 12
0198 
0199 typedef struct {
0200     CARD8   reqType;    /* always codes->major_opcode */
0201     CARD8   mbufReqType;    /* always X_MbufGetBufferAttributes */
0202     CARD16  length B16;
0203     CARD32  buffer B32;
0204 } xMbufGetBufferAttributesReq;
0205 #define sz_xMbufGetBufferAttributesReq 8
0206 
0207 typedef struct {
0208     BYTE    type;           /* X_Reply */
0209     CARD8   unused;         /* not used */
0210     CARD16  sequenceNumber B16;
0211     CARD32  length B32;
0212     CARD32  window B32;
0213     CARD32  eventMask B32;
0214     CARD16  bufferIndex B16;
0215     CARD8   side;
0216     CARD8   unused0;
0217     CARD32  unused1 B32;
0218     CARD32  unused2 B32;
0219     CARD32  unused3 B32;
0220 } xMbufGetBufferAttributesReply;
0221 #define sz_xMbufGetBufferAttributesReply 32
0222 
0223 typedef struct {
0224     CARD8   reqType;    /* always codes->major_opcode */
0225     CARD8   mbufReqType;    /* always X_MbufGetBufferInfo */
0226     CARD16  length B16;
0227     Drawable    drawable B32;
0228 } xMbufGetBufferInfoReq;
0229 #define sz_xMbufGetBufferInfoReq 8
0230 
0231 typedef struct {
0232     BYTE    type;           /* X_Reply */
0233     CARD8   unused;         /* not used */
0234     CARD16  sequenceNumber B16;
0235     CARD32  length B32;
0236     CARD16  normalInfo B16;
0237     CARD16  stereoInfo B16;
0238     CARD32  unused1 B32;
0239     CARD32  unused2 B32;
0240     CARD32  unused3 B32;
0241     CARD32  unused4 B32;
0242     CARD32  unused5 B32;
0243 } xMbufGetBufferInfoReply;          /* followed by buffer infos */
0244 #define sz_xMbufGetBufferInfoReply 32
0245 
0246 
0247 typedef struct {
0248     CARD8   reqType;    /* always codes->major_opcode */
0249     CARD8   mbufReqType;    /* always X_MbufCreateStereoWindow */
0250     CARD16  length B16;
0251     CARD8   unused0;
0252     CARD8   unused1;
0253     CARD8   unused2;
0254     CARD8   depth;
0255     Window  wid B32;
0256     Window  parent B32;
0257     Multibuffer left B32;   /* associated buffers */
0258     Multibuffer right B32;
0259     INT16   x B16;
0260     INT16   y B16;
0261     CARD16  width B16;
0262     CARD16  height B16;
0263     CARD16  borderWidth B16;
0264 #if defined(__cplusplus) || defined(c_plusplus)
0265     CARD16  c_class B16;
0266 #else
0267     CARD16  class B16;
0268 #endif
0269     VisualID    visual B32;
0270     CARD32  mask B32;
0271 } xMbufCreateStereoWindowReq;       /* followed by value list */
0272 #define sz_xMbufCreateStereoWindowReq 44
0273 
0274 typedef struct {
0275     CARD8     reqType;        /* always codes->major_opcode */
0276     CARD8     mbufReqType;    /* always X_MbufClearImageBufferArea */
0277     CARD16    length B16;
0278     Multibuffer       buffer B32;
0279     INT16     x B16;
0280     INT16     y B16;
0281     CARD16    width B16;
0282     CARD16    height B16;
0283     CARD8     unused0;
0284     CARD8     unused1;
0285     CARD8     unused2;
0286     BOOL      exposures;
0287 } xMbufClearImageBufferAreaReq;
0288 #define sz_xMbufClearImageBufferAreaReq 20
0289 
0290 #undef Window
0291 #undef Drawable
0292 #undef VisualID
0293 #undef Multibuffer
0294 
0295 #endif /* _MULTIBUFPROTO_H_ */