xref: /netbsd-src/external/mit/xorg/lib/libxcb/files/dbe.h (revision fea83ee4938f6f630ec4626dba8d28098c73f0cc)
1 /*
2  * This file generated automatically from dbe.xml by c_client.py.
3  * Edit at your peril.
4  */
5 
6 /**
7  * @defgroup XCB_Dbe_API XCB Dbe API
8  * @brief Dbe XCB Protocol Implementation.
9  * @{
10  **/
11 
12 #ifndef __DBE_H
13 #define __DBE_H
14 
15 #include "xcb.h"
16 #include "xproto.h"
17 
18 #ifdef __cplusplus
19 extern "C" {
20 #endif
21 
22 #define XCB_DBE_MAJOR_VERSION 1
23 #define XCB_DBE_MINOR_VERSION 0
24 
25 extern xcb_extension_t xcb_dbe_id;
26 
27 typedef uint32_t xcb_dbe_back_buffer_t;
28 
29 /**
30  * @brief xcb_dbe_back_buffer_iterator_t
31  **/
32 typedef struct xcb_dbe_back_buffer_iterator_t {
33     xcb_dbe_back_buffer_t *data;
34     int                    rem;
35     int                    index;
36 } xcb_dbe_back_buffer_iterator_t;
37 
38 typedef enum xcb_dbe_swap_action_t {
39     XCB_DBE_SWAP_ACTION_UNDEFINED = 0,
40 /**< Discard the buffer. The buffer may be reallocated and end up with random VRAM content. */
41 
42     XCB_DBE_SWAP_ACTION_BACKGROUND = 1,
43 /**< Erase with window background. */
44 
45     XCB_DBE_SWAP_ACTION_UNTOUCHED = 2,
46 /**< Leave untouched. */
47 
48     XCB_DBE_SWAP_ACTION_COPIED = 3
49 /**< Copy the newly displayed front buffer. */
50 
51 } xcb_dbe_swap_action_t;
52 
53 /**
54  * @brief xcb_dbe_swap_info_t
55  **/
56 typedef struct xcb_dbe_swap_info_t {
57     xcb_window_t window;
58     uint8_t      swap_action;
59     uint8_t      pad0[3];
60 } xcb_dbe_swap_info_t;
61 
62 /**
63  * @brief xcb_dbe_swap_info_iterator_t
64  **/
65 typedef struct xcb_dbe_swap_info_iterator_t {
66     xcb_dbe_swap_info_t *data;
67     int                  rem;
68     int                  index;
69 } xcb_dbe_swap_info_iterator_t;
70 
71 /**
72  * @brief xcb_dbe_buffer_attributes_t
73  **/
74 typedef struct xcb_dbe_buffer_attributes_t {
75     xcb_window_t window;
76 } xcb_dbe_buffer_attributes_t;
77 
78 /**
79  * @brief xcb_dbe_buffer_attributes_iterator_t
80  **/
81 typedef struct xcb_dbe_buffer_attributes_iterator_t {
82     xcb_dbe_buffer_attributes_t *data;
83     int                          rem;
84     int                          index;
85 } xcb_dbe_buffer_attributes_iterator_t;
86 
87 /**
88  * @brief xcb_dbe_visual_info_t
89  **/
90 typedef struct xcb_dbe_visual_info_t {
91     xcb_visualid_t visual_id;
92     uint8_t        depth;
93     uint8_t        perf_level;
94     uint8_t        pad0[2];
95 } xcb_dbe_visual_info_t;
96 
97 /**
98  * @brief xcb_dbe_visual_info_iterator_t
99  **/
100 typedef struct xcb_dbe_visual_info_iterator_t {
101     xcb_dbe_visual_info_t *data;
102     int                    rem;
103     int                    index;
104 } xcb_dbe_visual_info_iterator_t;
105 
106 /**
107  * @brief xcb_dbe_visual_infos_t
108  **/
109 typedef struct xcb_dbe_visual_infos_t {
110     uint32_t n_infos;
111 } xcb_dbe_visual_infos_t;
112 
113 /**
114  * @brief xcb_dbe_visual_infos_iterator_t
115  **/
116 typedef struct xcb_dbe_visual_infos_iterator_t {
117     xcb_dbe_visual_infos_t *data;
118     int                     rem;
119     int                     index;
120 } xcb_dbe_visual_infos_iterator_t;
121 
122 /** Opcode for xcb_dbe_bad_buffer. */
123 #define XCB_DBE_BAD_BUFFER 0
124 
125 /**
126  * @brief xcb_dbe_bad_buffer_error_t
127  **/
128 typedef struct xcb_dbe_bad_buffer_error_t {
129     uint8_t               response_type;
130     uint8_t               error_code;
131     uint16_t              sequence;
132     xcb_dbe_back_buffer_t bad_buffer;
133     uint16_t              minor_opcode;
134     uint8_t               major_opcode;
135 } xcb_dbe_bad_buffer_error_t;
136 
137 /**
138  * @brief xcb_dbe_query_version_cookie_t
139  **/
140 typedef struct xcb_dbe_query_version_cookie_t {
141     unsigned int sequence;
142 } xcb_dbe_query_version_cookie_t;
143 
144 /** Opcode for xcb_dbe_query_version. */
145 #define XCB_DBE_QUERY_VERSION 0
146 
147 /**
148  * @brief xcb_dbe_query_version_request_t
149  **/
150 typedef struct xcb_dbe_query_version_request_t {
151     uint8_t  major_opcode;
152     uint8_t  minor_opcode;
153     uint16_t length;
154     uint8_t  major_version;
155     uint8_t  minor_version;
156     uint8_t  pad0[2];
157 } xcb_dbe_query_version_request_t;
158 
159 /**
160  * @brief xcb_dbe_query_version_reply_t
161  **/
162 typedef struct xcb_dbe_query_version_reply_t {
163     uint8_t  response_type;
164     uint8_t  pad0;
165     uint16_t sequence;
166     uint32_t length;
167     uint8_t  major_version;
168     uint8_t  minor_version;
169     uint8_t  pad1[22];
170 } xcb_dbe_query_version_reply_t;
171 
172 /** Opcode for xcb_dbe_allocate_back_buffer. */
173 #define XCB_DBE_ALLOCATE_BACK_BUFFER 1
174 
175 /**
176  * @brief xcb_dbe_allocate_back_buffer_request_t
177  **/
178 typedef struct xcb_dbe_allocate_back_buffer_request_t {
179     uint8_t               major_opcode;
180     uint8_t               minor_opcode;
181     uint16_t              length;
182     xcb_window_t          window;
183     xcb_dbe_back_buffer_t buffer;
184     uint8_t               swap_action;
185     uint8_t               pad0[3];
186 } xcb_dbe_allocate_back_buffer_request_t;
187 
188 /** Opcode for xcb_dbe_deallocate_back_buffer. */
189 #define XCB_DBE_DEALLOCATE_BACK_BUFFER 2
190 
191 /**
192  * @brief xcb_dbe_deallocate_back_buffer_request_t
193  **/
194 typedef struct xcb_dbe_deallocate_back_buffer_request_t {
195     uint8_t               major_opcode;
196     uint8_t               minor_opcode;
197     uint16_t              length;
198     xcb_dbe_back_buffer_t buffer;
199 } xcb_dbe_deallocate_back_buffer_request_t;
200 
201 /** Opcode for xcb_dbe_swap_buffers. */
202 #define XCB_DBE_SWAP_BUFFERS 3
203 
204 /**
205  * @brief xcb_dbe_swap_buffers_request_t
206  **/
207 typedef struct xcb_dbe_swap_buffers_request_t {
208     uint8_t  major_opcode;
209     uint8_t  minor_opcode;
210     uint16_t length;
211     uint32_t n_actions;
212 } xcb_dbe_swap_buffers_request_t;
213 
214 /** Opcode for xcb_dbe_begin_idiom. */
215 #define XCB_DBE_BEGIN_IDIOM 4
216 
217 /**
218  * @brief xcb_dbe_begin_idiom_request_t
219  **/
220 typedef struct xcb_dbe_begin_idiom_request_t {
221     uint8_t  major_opcode;
222     uint8_t  minor_opcode;
223     uint16_t length;
224 } xcb_dbe_begin_idiom_request_t;
225 
226 /** Opcode for xcb_dbe_end_idiom. */
227 #define XCB_DBE_END_IDIOM 5
228 
229 /**
230  * @brief xcb_dbe_end_idiom_request_t
231  **/
232 typedef struct xcb_dbe_end_idiom_request_t {
233     uint8_t  major_opcode;
234     uint8_t  minor_opcode;
235     uint16_t length;
236 } xcb_dbe_end_idiom_request_t;
237 
238 /**
239  * @brief xcb_dbe_get_visual_info_cookie_t
240  **/
241 typedef struct xcb_dbe_get_visual_info_cookie_t {
242     unsigned int sequence;
243 } xcb_dbe_get_visual_info_cookie_t;
244 
245 /** Opcode for xcb_dbe_get_visual_info. */
246 #define XCB_DBE_GET_VISUAL_INFO 6
247 
248 /**
249  * @brief xcb_dbe_get_visual_info_request_t
250  **/
251 typedef struct xcb_dbe_get_visual_info_request_t {
252     uint8_t  major_opcode;
253     uint8_t  minor_opcode;
254     uint16_t length;
255     uint32_t n_drawables;
256 } xcb_dbe_get_visual_info_request_t;
257 
258 /**
259  * @brief xcb_dbe_get_visual_info_reply_t
260  **/
261 typedef struct xcb_dbe_get_visual_info_reply_t {
262     uint8_t  response_type;
263     uint8_t  pad0;
264     uint16_t sequence;
265     uint32_t length;
266     uint32_t n_supported_visuals;
267     uint8_t  pad1[20];
268 } xcb_dbe_get_visual_info_reply_t;
269 
270 /**
271  * @brief xcb_dbe_get_back_buffer_attributes_cookie_t
272  **/
273 typedef struct xcb_dbe_get_back_buffer_attributes_cookie_t {
274     unsigned int sequence;
275 } xcb_dbe_get_back_buffer_attributes_cookie_t;
276 
277 /** Opcode for xcb_dbe_get_back_buffer_attributes. */
278 #define XCB_DBE_GET_BACK_BUFFER_ATTRIBUTES 7
279 
280 /**
281  * @brief xcb_dbe_get_back_buffer_attributes_request_t
282  **/
283 typedef struct xcb_dbe_get_back_buffer_attributes_request_t {
284     uint8_t               major_opcode;
285     uint8_t               minor_opcode;
286     uint16_t              length;
287     xcb_dbe_back_buffer_t buffer;
288 } xcb_dbe_get_back_buffer_attributes_request_t;
289 
290 /**
291  * @brief xcb_dbe_get_back_buffer_attributes_reply_t
292  **/
293 typedef struct xcb_dbe_get_back_buffer_attributes_reply_t {
294     uint8_t                     response_type;
295     uint8_t                     pad0;
296     uint16_t                    sequence;
297     uint32_t                    length;
298     xcb_dbe_buffer_attributes_t attributes;
299     uint8_t                     pad1[20];
300 } xcb_dbe_get_back_buffer_attributes_reply_t;
301 
302 /**
303  * Get the next element of the iterator
304  * @param i Pointer to a xcb_dbe_back_buffer_iterator_t
305  *
306  * Get the next element in the iterator. The member rem is
307  * decreased by one. The member data points to the next
308  * element. The member index is increased by sizeof(xcb_dbe_back_buffer_t)
309  */
310 void
311 xcb_dbe_back_buffer_next (xcb_dbe_back_buffer_iterator_t *i);
312 
313 /**
314  * Return the iterator pointing to the last element
315  * @param i An xcb_dbe_back_buffer_iterator_t
316  * @return  The iterator pointing to the last element
317  *
318  * Set the current element in the iterator to the last element.
319  * The member rem is set to 0. The member data points to the
320  * last element.
321  */
322 xcb_generic_iterator_t
323 xcb_dbe_back_buffer_end (xcb_dbe_back_buffer_iterator_t i);
324 
325 /**
326  * Get the next element of the iterator
327  * @param i Pointer to a xcb_dbe_swap_info_iterator_t
328  *
329  * Get the next element in the iterator. The member rem is
330  * decreased by one. The member data points to the next
331  * element. The member index is increased by sizeof(xcb_dbe_swap_info_t)
332  */
333 void
334 xcb_dbe_swap_info_next (xcb_dbe_swap_info_iterator_t *i);
335 
336 /**
337  * Return the iterator pointing to the last element
338  * @param i An xcb_dbe_swap_info_iterator_t
339  * @return  The iterator pointing to the last element
340  *
341  * Set the current element in the iterator to the last element.
342  * The member rem is set to 0. The member data points to the
343  * last element.
344  */
345 xcb_generic_iterator_t
346 xcb_dbe_swap_info_end (xcb_dbe_swap_info_iterator_t i);
347 
348 /**
349  * Get the next element of the iterator
350  * @param i Pointer to a xcb_dbe_buffer_attributes_iterator_t
351  *
352  * Get the next element in the iterator. The member rem is
353  * decreased by one. The member data points to the next
354  * element. The member index is increased by sizeof(xcb_dbe_buffer_attributes_t)
355  */
356 void
357 xcb_dbe_buffer_attributes_next (xcb_dbe_buffer_attributes_iterator_t *i);
358 
359 /**
360  * Return the iterator pointing to the last element
361  * @param i An xcb_dbe_buffer_attributes_iterator_t
362  * @return  The iterator pointing to the last element
363  *
364  * Set the current element in the iterator to the last element.
365  * The member rem is set to 0. The member data points to the
366  * last element.
367  */
368 xcb_generic_iterator_t
369 xcb_dbe_buffer_attributes_end (xcb_dbe_buffer_attributes_iterator_t i);
370 
371 /**
372  * Get the next element of the iterator
373  * @param i Pointer to a xcb_dbe_visual_info_iterator_t
374  *
375  * Get the next element in the iterator. The member rem is
376  * decreased by one. The member data points to the next
377  * element. The member index is increased by sizeof(xcb_dbe_visual_info_t)
378  */
379 void
380 xcb_dbe_visual_info_next (xcb_dbe_visual_info_iterator_t *i);
381 
382 /**
383  * Return the iterator pointing to the last element
384  * @param i An xcb_dbe_visual_info_iterator_t
385  * @return  The iterator pointing to the last element
386  *
387  * Set the current element in the iterator to the last element.
388  * The member rem is set to 0. The member data points to the
389  * last element.
390  */
391 xcb_generic_iterator_t
392 xcb_dbe_visual_info_end (xcb_dbe_visual_info_iterator_t i);
393 
394 int
395 xcb_dbe_visual_infos_sizeof (const void  *_buffer);
396 
397 xcb_dbe_visual_info_t *
398 xcb_dbe_visual_infos_infos (const xcb_dbe_visual_infos_t *R);
399 
400 int
401 xcb_dbe_visual_infos_infos_length (const xcb_dbe_visual_infos_t *R);
402 
403 xcb_dbe_visual_info_iterator_t
404 xcb_dbe_visual_infos_infos_iterator (const xcb_dbe_visual_infos_t *R);
405 
406 /**
407  * Get the next element of the iterator
408  * @param i Pointer to a xcb_dbe_visual_infos_iterator_t
409  *
410  * Get the next element in the iterator. The member rem is
411  * decreased by one. The member data points to the next
412  * element. The member index is increased by sizeof(xcb_dbe_visual_infos_t)
413  */
414 void
415 xcb_dbe_visual_infos_next (xcb_dbe_visual_infos_iterator_t *i);
416 
417 /**
418  * Return the iterator pointing to the last element
419  * @param i An xcb_dbe_visual_infos_iterator_t
420  * @return  The iterator pointing to the last element
421  *
422  * Set the current element in the iterator to the last element.
423  * The member rem is set to 0. The member data points to the
424  * last element.
425  */
426 xcb_generic_iterator_t
427 xcb_dbe_visual_infos_end (xcb_dbe_visual_infos_iterator_t i);
428 
429 /**
430  * @brief Queries the version of this extension
431  *
432  * @param c The connection
433  * @param major_version The major version of the extension. Check that it is compatible with the XCB_DBE_MAJOR_VERSION that your code is compiled with.
434  * @param minor_version The minor version of the extension. Check that it is compatible with the XCB_DBE_MINOR_VERSION that your code is compiled with.
435  * @return A cookie
436  *
437  * Queries the version of this extension. You must do this before using any functionality it provides.
438  *
439  */
440 xcb_dbe_query_version_cookie_t
441 xcb_dbe_query_version (xcb_connection_t *c,
442                        uint8_t           major_version,
443                        uint8_t           minor_version);
444 
445 /**
446  * @brief Queries the version of this extension
447  *
448  * @param c The connection
449  * @param major_version The major version of the extension. Check that it is compatible with the XCB_DBE_MAJOR_VERSION that your code is compiled with.
450  * @param minor_version The minor version of the extension. Check that it is compatible with the XCB_DBE_MINOR_VERSION that your code is compiled with.
451  * @return A cookie
452  *
453  * Queries the version of this extension. You must do this before using any functionality it provides.
454  *
455  * This form can be used only if the request will cause
456  * a reply to be generated. Any returned error will be
457  * placed in the event queue.
458  */
459 xcb_dbe_query_version_cookie_t
460 xcb_dbe_query_version_unchecked (xcb_connection_t *c,
461                                  uint8_t           major_version,
462                                  uint8_t           minor_version);
463 
464 /**
465  * Return the reply
466  * @param c      The connection
467  * @param cookie The cookie
468  * @param e      The xcb_generic_error_t supplied
469  *
470  * Returns the reply of the request asked by
471  *
472  * The parameter @p e supplied to this function must be NULL if
473  * xcb_dbe_query_version_unchecked(). is used.
474  * Otherwise, it stores the error if any.
475  *
476  * The returned value must be freed by the caller using free().
477  */
478 xcb_dbe_query_version_reply_t *
479 xcb_dbe_query_version_reply (xcb_connection_t                *c,
480                              xcb_dbe_query_version_cookie_t   cookie  /**< */,
481                              xcb_generic_error_t            **e);
482 
483 /**
484  * @brief Allocates a back buffer
485  *
486  * @param c The connection
487  * @param window The window to which to add the back buffer.
488  * @param buffer The buffer id to associate with the back buffer.
489  * @param swap_action The swap action most likely to be used to present this back buffer. This is only a hint, and does not preclude the use of other swap actions.
490  * @return A cookie
491  *
492  * Associates \a buffer with the back buffer of \a window. Multiple ids may be associated with the back buffer, which is created by the first allocate call and destroyed by the last deallocate.
493  *
494  * This form can be used only if the request will not cause
495  * a reply to be generated. Any returned error will be
496  * saved for handling by xcb_request_check().
497  */
498 xcb_void_cookie_t
499 xcb_dbe_allocate_back_buffer_checked (xcb_connection_t      *c,
500                                       xcb_window_t           window,
501                                       xcb_dbe_back_buffer_t  buffer,
502                                       uint8_t                swap_action);
503 
504 /**
505  * @brief Allocates a back buffer
506  *
507  * @param c The connection
508  * @param window The window to which to add the back buffer.
509  * @param buffer The buffer id to associate with the back buffer.
510  * @param swap_action The swap action most likely to be used to present this back buffer. This is only a hint, and does not preclude the use of other swap actions.
511  * @return A cookie
512  *
513  * Associates \a buffer with the back buffer of \a window. Multiple ids may be associated with the back buffer, which is created by the first allocate call and destroyed by the last deallocate.
514  *
515  */
516 xcb_void_cookie_t
517 xcb_dbe_allocate_back_buffer (xcb_connection_t      *c,
518                               xcb_window_t           window,
519                               xcb_dbe_back_buffer_t  buffer,
520                               uint8_t                swap_action);
521 
522 /**
523  * @brief Deallocates a back buffer
524  *
525  * @param c The connection
526  * @param buffer The back buffer to deallocate.
527  * @return A cookie
528  *
529  * Deallocates the given \a buffer. If \a buffer is an invalid id, a `BadBuffer` error is returned. Because a window may have allocated multiple back buffer ids, the back buffer itself is not deleted until all these ids are deallocated by this call.
530  *
531  * This form can be used only if the request will not cause
532  * a reply to be generated. Any returned error will be
533  * saved for handling by xcb_request_check().
534  */
535 xcb_void_cookie_t
536 xcb_dbe_deallocate_back_buffer_checked (xcb_connection_t      *c,
537                                         xcb_dbe_back_buffer_t  buffer);
538 
539 /**
540  * @brief Deallocates a back buffer
541  *
542  * @param c The connection
543  * @param buffer The back buffer to deallocate.
544  * @return A cookie
545  *
546  * Deallocates the given \a buffer. If \a buffer is an invalid id, a `BadBuffer` error is returned. Because a window may have allocated multiple back buffer ids, the back buffer itself is not deleted until all these ids are deallocated by this call.
547  *
548  */
549 xcb_void_cookie_t
550 xcb_dbe_deallocate_back_buffer (xcb_connection_t      *c,
551                                 xcb_dbe_back_buffer_t  buffer);
552 
553 int
554 xcb_dbe_swap_buffers_sizeof (const void  *_buffer);
555 
556 /**
557  * @brief Swaps front and back buffers
558  *
559  * @param c The connection
560  * @param n_actions Number of swap actions in \a actions.
561  * @param actions List of windows on which to swap buffers.
562  * @return A cookie
563  *
564  * Swaps the front and back buffers on the specified windows. The front and back buffers retain their ids, so that the window id continues to refer to the front buffer, while the back buffer id created by this extension continues to refer to the back buffer. Back buffer contents is moved to the front buffer. Back buffer contents after the operation depends on the given swap action. The optimal swap action depends on how each frame is rendered. For example, if the buffer is cleared and fully overwritten on every frame, the "untouched" action, which throws away the buffer contents, would provide the best performance. To eliminate visual artifacts, the swap will occure during the monitor VSync, if the X server supports detecting it.
565  *
566  * This form can be used only if the request will not cause
567  * a reply to be generated. Any returned error will be
568  * saved for handling by xcb_request_check().
569  */
570 xcb_void_cookie_t
571 xcb_dbe_swap_buffers_checked (xcb_connection_t          *c,
572                               uint32_t                   n_actions,
573                               const xcb_dbe_swap_info_t *actions);
574 
575 /**
576  * @brief Swaps front and back buffers
577  *
578  * @param c The connection
579  * @param n_actions Number of swap actions in \a actions.
580  * @param actions List of windows on which to swap buffers.
581  * @return A cookie
582  *
583  * Swaps the front and back buffers on the specified windows. The front and back buffers retain their ids, so that the window id continues to refer to the front buffer, while the back buffer id created by this extension continues to refer to the back buffer. Back buffer contents is moved to the front buffer. Back buffer contents after the operation depends on the given swap action. The optimal swap action depends on how each frame is rendered. For example, if the buffer is cleared and fully overwritten on every frame, the "untouched" action, which throws away the buffer contents, would provide the best performance. To eliminate visual artifacts, the swap will occure during the monitor VSync, if the X server supports detecting it.
584  *
585  */
586 xcb_void_cookie_t
587 xcb_dbe_swap_buffers (xcb_connection_t          *c,
588                       uint32_t                   n_actions,
589                       const xcb_dbe_swap_info_t *actions);
590 
591 xcb_dbe_swap_info_t *
592 xcb_dbe_swap_buffers_actions (const xcb_dbe_swap_buffers_request_t *R);
593 
594 int
595 xcb_dbe_swap_buffers_actions_length (const xcb_dbe_swap_buffers_request_t *R);
596 
597 xcb_dbe_swap_info_iterator_t
598 xcb_dbe_swap_buffers_actions_iterator (const xcb_dbe_swap_buffers_request_t *R);
599 
600 /**
601  * @brief Begins a logical swap block
602  *
603  * @param c The connection
604  * @return A cookie
605  *
606  * Creates a block of operations intended to occur together. This may be needed if window presentation requires changing buffers unknown to this extension, such as depth or stencil buffers.
607  *
608  * This form can be used only if the request will not cause
609  * a reply to be generated. Any returned error will be
610  * saved for handling by xcb_request_check().
611  */
612 xcb_void_cookie_t
613 xcb_dbe_begin_idiom_checked (xcb_connection_t *c);
614 
615 /**
616  * @brief Begins a logical swap block
617  *
618  * @param c The connection
619  * @return A cookie
620  *
621  * Creates a block of operations intended to occur together. This may be needed if window presentation requires changing buffers unknown to this extension, such as depth or stencil buffers.
622  *
623  */
624 xcb_void_cookie_t
625 xcb_dbe_begin_idiom (xcb_connection_t *c);
626 
627 /**
628  * @brief Ends a logical swap block
629  *
630  * @param c The connection
631  * @return A cookie
632  *
633  * No description yet
634  *
635  * This form can be used only if the request will not cause
636  * a reply to be generated. Any returned error will be
637  * saved for handling by xcb_request_check().
638  */
639 xcb_void_cookie_t
640 xcb_dbe_end_idiom_checked (xcb_connection_t *c);
641 
642 /**
643  * @brief Ends a logical swap block
644  *
645  * @param c The connection
646  * @return A cookie
647  *
648  * No description yet
649  *
650  */
651 xcb_void_cookie_t
652 xcb_dbe_end_idiom (xcb_connection_t *c);
653 
654 int
655 xcb_dbe_get_visual_info_sizeof (const void  *_buffer);
656 
657 /**
658  * @brief Requests visuals that support double buffering
659  *
660  * @param c The connection
661  * @return A cookie
662  *
663  * No description yet
664  *
665  */
666 xcb_dbe_get_visual_info_cookie_t
667 xcb_dbe_get_visual_info (xcb_connection_t     *c,
668                          uint32_t              n_drawables,
669                          const xcb_drawable_t *drawables);
670 
671 /**
672  * @brief Requests visuals that support double buffering
673  *
674  * @param c The connection
675  * @return A cookie
676  *
677  * No description yet
678  *
679  * This form can be used only if the request will cause
680  * a reply to be generated. Any returned error will be
681  * placed in the event queue.
682  */
683 xcb_dbe_get_visual_info_cookie_t
684 xcb_dbe_get_visual_info_unchecked (xcb_connection_t     *c,
685                                    uint32_t              n_drawables,
686                                    const xcb_drawable_t *drawables);
687 
688 int
689 xcb_dbe_get_visual_info_supported_visuals_length (const xcb_dbe_get_visual_info_reply_t *R);
690 
691 xcb_dbe_visual_infos_iterator_t
692 xcb_dbe_get_visual_info_supported_visuals_iterator (const xcb_dbe_get_visual_info_reply_t *R);
693 
694 /**
695  * Return the reply
696  * @param c      The connection
697  * @param cookie The cookie
698  * @param e      The xcb_generic_error_t supplied
699  *
700  * Returns the reply of the request asked by
701  *
702  * The parameter @p e supplied to this function must be NULL if
703  * xcb_dbe_get_visual_info_unchecked(). is used.
704  * Otherwise, it stores the error if any.
705  *
706  * The returned value must be freed by the caller using free().
707  */
708 xcb_dbe_get_visual_info_reply_t *
709 xcb_dbe_get_visual_info_reply (xcb_connection_t                  *c,
710                                xcb_dbe_get_visual_info_cookie_t   cookie  /**< */,
711                                xcb_generic_error_t              **e);
712 
713 /**
714  * @brief Gets back buffer attributes
715  *
716  * @param c The connection
717  * @param buffer The back buffer to query.
718  * @return A cookie
719  *
720  * Returns the attributes of the specified \a buffer.
721  *
722  */
723 xcb_dbe_get_back_buffer_attributes_cookie_t
724 xcb_dbe_get_back_buffer_attributes (xcb_connection_t      *c,
725                                     xcb_dbe_back_buffer_t  buffer);
726 
727 /**
728  * @brief Gets back buffer attributes
729  *
730  * @param c The connection
731  * @param buffer The back buffer to query.
732  * @return A cookie
733  *
734  * Returns the attributes of the specified \a buffer.
735  *
736  * This form can be used only if the request will cause
737  * a reply to be generated. Any returned error will be
738  * placed in the event queue.
739  */
740 xcb_dbe_get_back_buffer_attributes_cookie_t
741 xcb_dbe_get_back_buffer_attributes_unchecked (xcb_connection_t      *c,
742                                               xcb_dbe_back_buffer_t  buffer);
743 
744 /**
745  * Return the reply
746  * @param c      The connection
747  * @param cookie The cookie
748  * @param e      The xcb_generic_error_t supplied
749  *
750  * Returns the reply of the request asked by
751  *
752  * The parameter @p e supplied to this function must be NULL if
753  * xcb_dbe_get_back_buffer_attributes_unchecked(). is used.
754  * Otherwise, it stores the error if any.
755  *
756  * The returned value must be freed by the caller using free().
757  */
758 xcb_dbe_get_back_buffer_attributes_reply_t *
759 xcb_dbe_get_back_buffer_attributes_reply (xcb_connection_t                             *c,
760                                           xcb_dbe_get_back_buffer_attributes_cookie_t   cookie  /**< */,
761                                           xcb_generic_error_t                         **e);
762 
763 
764 #ifdef __cplusplus
765 }
766 #endif
767 
768 #endif
769 
770 /**
771  * @}
772  */
773