1 /* 2 * This file generated automatically from dri2.xml by c_client.py. 3 * Edit at your peril. 4 */ 5 6 /** 7 * @defgroup XCB_DRI2_API XCB DRI2 API 8 * @brief DRI2 XCB Protocol Implementation. 9 * @{ 10 **/ 11 12 #ifndef __DRI2_H 13 #define __DRI2_H 14 15 #include "xcb.h" 16 #include "xproto.h" 17 18 #ifdef __cplusplus 19 extern "C" { 20 #endif 21 22 #define XCB_DRI2_MAJOR_VERSION 1 23 #define XCB_DRI2_MINOR_VERSION 4 24 25 extern xcb_extension_t xcb_dri2_id; 26 27 typedef enum xcb_dri2_attachment_t { 28 XCB_DRI2_ATTACHMENT_BUFFER_FRONT_LEFT = 0, 29 XCB_DRI2_ATTACHMENT_BUFFER_BACK_LEFT = 1, 30 XCB_DRI2_ATTACHMENT_BUFFER_FRONT_RIGHT = 2, 31 XCB_DRI2_ATTACHMENT_BUFFER_BACK_RIGHT = 3, 32 XCB_DRI2_ATTACHMENT_BUFFER_DEPTH = 4, 33 XCB_DRI2_ATTACHMENT_BUFFER_STENCIL = 5, 34 XCB_DRI2_ATTACHMENT_BUFFER_ACCUM = 6, 35 XCB_DRI2_ATTACHMENT_BUFFER_FAKE_FRONT_LEFT = 7, 36 XCB_DRI2_ATTACHMENT_BUFFER_FAKE_FRONT_RIGHT = 8, 37 XCB_DRI2_ATTACHMENT_BUFFER_DEPTH_STENCIL = 9, 38 XCB_DRI2_ATTACHMENT_BUFFER_HIZ = 10 39 } xcb_dri2_attachment_t; 40 41 typedef enum xcb_dri2_driver_type_t { 42 XCB_DRI2_DRIVER_TYPE_DRI = 0, 43 XCB_DRI2_DRIVER_TYPE_VDPAU = 1 44 } xcb_dri2_driver_type_t; 45 46 typedef enum xcb_dri2_event_type_t { 47 XCB_DRI2_EVENT_TYPE_EXCHANGE_COMPLETE = 1, 48 XCB_DRI2_EVENT_TYPE_BLIT_COMPLETE = 2, 49 XCB_DRI2_EVENT_TYPE_FLIP_COMPLETE = 3 50 } xcb_dri2_event_type_t; 51 52 /** 53 * @brief xcb_dri2_dri2_buffer_t 54 **/ 55 typedef struct xcb_dri2_dri2_buffer_t { 56 uint32_t attachment; /**< */ 57 uint32_t name; /**< */ 58 uint32_t pitch; /**< */ 59 uint32_t cpp; /**< */ 60 uint32_t flags; /**< */ 61 } xcb_dri2_dri2_buffer_t; 62 63 /** 64 * @brief xcb_dri2_dri2_buffer_iterator_t 65 **/ 66 typedef struct xcb_dri2_dri2_buffer_iterator_t { 67 xcb_dri2_dri2_buffer_t *data; /**< */ 68 int rem; /**< */ 69 int index; /**< */ 70 } xcb_dri2_dri2_buffer_iterator_t; 71 72 /** 73 * @brief xcb_dri2_attach_format_t 74 **/ 75 typedef struct xcb_dri2_attach_format_t { 76 uint32_t attachment; /**< */ 77 uint32_t format; /**< */ 78 } xcb_dri2_attach_format_t; 79 80 /** 81 * @brief xcb_dri2_attach_format_iterator_t 82 **/ 83 typedef struct xcb_dri2_attach_format_iterator_t { 84 xcb_dri2_attach_format_t *data; /**< */ 85 int rem; /**< */ 86 int index; /**< */ 87 } xcb_dri2_attach_format_iterator_t; 88 89 /** 90 * @brief xcb_dri2_query_version_cookie_t 91 **/ 92 typedef struct xcb_dri2_query_version_cookie_t { 93 unsigned int sequence; /**< */ 94 } xcb_dri2_query_version_cookie_t; 95 96 /** Opcode for xcb_dri2_query_version. */ 97 #define XCB_DRI2_QUERY_VERSION 0 98 99 /** 100 * @brief xcb_dri2_query_version_request_t 101 **/ 102 typedef struct xcb_dri2_query_version_request_t { 103 uint8_t major_opcode; /**< */ 104 uint8_t minor_opcode; /**< */ 105 uint16_t length; /**< */ 106 uint32_t major_version; /**< */ 107 uint32_t minor_version; /**< */ 108 } xcb_dri2_query_version_request_t; 109 110 /** 111 * @brief xcb_dri2_query_version_reply_t 112 **/ 113 typedef struct xcb_dri2_query_version_reply_t { 114 uint8_t response_type; /**< */ 115 uint8_t pad0; /**< */ 116 uint16_t sequence; /**< */ 117 uint32_t length; /**< */ 118 uint32_t major_version; /**< */ 119 uint32_t minor_version; /**< */ 120 } xcb_dri2_query_version_reply_t; 121 122 /** 123 * @brief xcb_dri2_connect_cookie_t 124 **/ 125 typedef struct xcb_dri2_connect_cookie_t { 126 unsigned int sequence; /**< */ 127 } xcb_dri2_connect_cookie_t; 128 129 /** Opcode for xcb_dri2_connect. */ 130 #define XCB_DRI2_CONNECT 1 131 132 /** 133 * @brief xcb_dri2_connect_request_t 134 **/ 135 typedef struct xcb_dri2_connect_request_t { 136 uint8_t major_opcode; /**< */ 137 uint8_t minor_opcode; /**< */ 138 uint16_t length; /**< */ 139 xcb_window_t window; /**< */ 140 uint32_t driver_type; /**< */ 141 } xcb_dri2_connect_request_t; 142 143 /** 144 * @brief xcb_dri2_connect_reply_t 145 **/ 146 typedef struct xcb_dri2_connect_reply_t { 147 uint8_t response_type; /**< */ 148 uint8_t pad0; /**< */ 149 uint16_t sequence; /**< */ 150 uint32_t length; /**< */ 151 uint32_t driver_name_length; /**< */ 152 uint32_t device_name_length; /**< */ 153 uint8_t pad1[16]; /**< */ 154 } xcb_dri2_connect_reply_t; 155 156 /** 157 * @brief xcb_dri2_authenticate_cookie_t 158 **/ 159 typedef struct xcb_dri2_authenticate_cookie_t { 160 unsigned int sequence; /**< */ 161 } xcb_dri2_authenticate_cookie_t; 162 163 /** Opcode for xcb_dri2_authenticate. */ 164 #define XCB_DRI2_AUTHENTICATE 2 165 166 /** 167 * @brief xcb_dri2_authenticate_request_t 168 **/ 169 typedef struct xcb_dri2_authenticate_request_t { 170 uint8_t major_opcode; /**< */ 171 uint8_t minor_opcode; /**< */ 172 uint16_t length; /**< */ 173 xcb_window_t window; /**< */ 174 uint32_t magic; /**< */ 175 } xcb_dri2_authenticate_request_t; 176 177 /** 178 * @brief xcb_dri2_authenticate_reply_t 179 **/ 180 typedef struct xcb_dri2_authenticate_reply_t { 181 uint8_t response_type; /**< */ 182 uint8_t pad0; /**< */ 183 uint16_t sequence; /**< */ 184 uint32_t length; /**< */ 185 uint32_t authenticated; /**< */ 186 } xcb_dri2_authenticate_reply_t; 187 188 /** Opcode for xcb_dri2_create_drawable. */ 189 #define XCB_DRI2_CREATE_DRAWABLE 3 190 191 /** 192 * @brief xcb_dri2_create_drawable_request_t 193 **/ 194 typedef struct xcb_dri2_create_drawable_request_t { 195 uint8_t major_opcode; /**< */ 196 uint8_t minor_opcode; /**< */ 197 uint16_t length; /**< */ 198 xcb_drawable_t drawable; /**< */ 199 } xcb_dri2_create_drawable_request_t; 200 201 /** Opcode for xcb_dri2_destroy_drawable. */ 202 #define XCB_DRI2_DESTROY_DRAWABLE 4 203 204 /** 205 * @brief xcb_dri2_destroy_drawable_request_t 206 **/ 207 typedef struct xcb_dri2_destroy_drawable_request_t { 208 uint8_t major_opcode; /**< */ 209 uint8_t minor_opcode; /**< */ 210 uint16_t length; /**< */ 211 xcb_drawable_t drawable; /**< */ 212 } xcb_dri2_destroy_drawable_request_t; 213 214 /** 215 * @brief xcb_dri2_get_buffers_cookie_t 216 **/ 217 typedef struct xcb_dri2_get_buffers_cookie_t { 218 unsigned int sequence; /**< */ 219 } xcb_dri2_get_buffers_cookie_t; 220 221 /** Opcode for xcb_dri2_get_buffers. */ 222 #define XCB_DRI2_GET_BUFFERS 5 223 224 /** 225 * @brief xcb_dri2_get_buffers_request_t 226 **/ 227 typedef struct xcb_dri2_get_buffers_request_t { 228 uint8_t major_opcode; /**< */ 229 uint8_t minor_opcode; /**< */ 230 uint16_t length; /**< */ 231 xcb_drawable_t drawable; /**< */ 232 uint32_t count; /**< */ 233 } xcb_dri2_get_buffers_request_t; 234 235 /** 236 * @brief xcb_dri2_get_buffers_reply_t 237 **/ 238 typedef struct xcb_dri2_get_buffers_reply_t { 239 uint8_t response_type; /**< */ 240 uint8_t pad0; /**< */ 241 uint16_t sequence; /**< */ 242 uint32_t length; /**< */ 243 uint32_t width; /**< */ 244 uint32_t height; /**< */ 245 uint32_t count; /**< */ 246 uint8_t pad1[12]; /**< */ 247 } xcb_dri2_get_buffers_reply_t; 248 249 /** 250 * @brief xcb_dri2_copy_region_cookie_t 251 **/ 252 typedef struct xcb_dri2_copy_region_cookie_t { 253 unsigned int sequence; /**< */ 254 } xcb_dri2_copy_region_cookie_t; 255 256 /** Opcode for xcb_dri2_copy_region. */ 257 #define XCB_DRI2_COPY_REGION 6 258 259 /** 260 * @brief xcb_dri2_copy_region_request_t 261 **/ 262 typedef struct xcb_dri2_copy_region_request_t { 263 uint8_t major_opcode; /**< */ 264 uint8_t minor_opcode; /**< */ 265 uint16_t length; /**< */ 266 xcb_drawable_t drawable; /**< */ 267 uint32_t region; /**< */ 268 uint32_t dest; /**< */ 269 uint32_t src; /**< */ 270 } xcb_dri2_copy_region_request_t; 271 272 /** 273 * @brief xcb_dri2_copy_region_reply_t 274 **/ 275 typedef struct xcb_dri2_copy_region_reply_t { 276 uint8_t response_type; /**< */ 277 uint8_t pad0; /**< */ 278 uint16_t sequence; /**< */ 279 uint32_t length; /**< */ 280 } xcb_dri2_copy_region_reply_t; 281 282 /** 283 * @brief xcb_dri2_get_buffers_with_format_cookie_t 284 **/ 285 typedef struct xcb_dri2_get_buffers_with_format_cookie_t { 286 unsigned int sequence; /**< */ 287 } xcb_dri2_get_buffers_with_format_cookie_t; 288 289 /** Opcode for xcb_dri2_get_buffers_with_format. */ 290 #define XCB_DRI2_GET_BUFFERS_WITH_FORMAT 7 291 292 /** 293 * @brief xcb_dri2_get_buffers_with_format_request_t 294 **/ 295 typedef struct xcb_dri2_get_buffers_with_format_request_t { 296 uint8_t major_opcode; /**< */ 297 uint8_t minor_opcode; /**< */ 298 uint16_t length; /**< */ 299 xcb_drawable_t drawable; /**< */ 300 uint32_t count; /**< */ 301 } xcb_dri2_get_buffers_with_format_request_t; 302 303 /** 304 * @brief xcb_dri2_get_buffers_with_format_reply_t 305 **/ 306 typedef struct xcb_dri2_get_buffers_with_format_reply_t { 307 uint8_t response_type; /**< */ 308 uint8_t pad0; /**< */ 309 uint16_t sequence; /**< */ 310 uint32_t length; /**< */ 311 uint32_t width; /**< */ 312 uint32_t height; /**< */ 313 uint32_t count; /**< */ 314 uint8_t pad1[12]; /**< */ 315 } xcb_dri2_get_buffers_with_format_reply_t; 316 317 /** 318 * @brief xcb_dri2_swap_buffers_cookie_t 319 **/ 320 typedef struct xcb_dri2_swap_buffers_cookie_t { 321 unsigned int sequence; /**< */ 322 } xcb_dri2_swap_buffers_cookie_t; 323 324 /** Opcode for xcb_dri2_swap_buffers. */ 325 #define XCB_DRI2_SWAP_BUFFERS 8 326 327 /** 328 * @brief xcb_dri2_swap_buffers_request_t 329 **/ 330 typedef struct xcb_dri2_swap_buffers_request_t { 331 uint8_t major_opcode; /**< */ 332 uint8_t minor_opcode; /**< */ 333 uint16_t length; /**< */ 334 xcb_drawable_t drawable; /**< */ 335 uint32_t target_msc_hi; /**< */ 336 uint32_t target_msc_lo; /**< */ 337 uint32_t divisor_hi; /**< */ 338 uint32_t divisor_lo; /**< */ 339 uint32_t remainder_hi; /**< */ 340 uint32_t remainder_lo; /**< */ 341 } xcb_dri2_swap_buffers_request_t; 342 343 /** 344 * @brief xcb_dri2_swap_buffers_reply_t 345 **/ 346 typedef struct xcb_dri2_swap_buffers_reply_t { 347 uint8_t response_type; /**< */ 348 uint8_t pad0; /**< */ 349 uint16_t sequence; /**< */ 350 uint32_t length; /**< */ 351 uint32_t swap_hi; /**< */ 352 uint32_t swap_lo; /**< */ 353 } xcb_dri2_swap_buffers_reply_t; 354 355 /** 356 * @brief xcb_dri2_get_msc_cookie_t 357 **/ 358 typedef struct xcb_dri2_get_msc_cookie_t { 359 unsigned int sequence; /**< */ 360 } xcb_dri2_get_msc_cookie_t; 361 362 /** Opcode for xcb_dri2_get_msc. */ 363 #define XCB_DRI2_GET_MSC 9 364 365 /** 366 * @brief xcb_dri2_get_msc_request_t 367 **/ 368 typedef struct xcb_dri2_get_msc_request_t { 369 uint8_t major_opcode; /**< */ 370 uint8_t minor_opcode; /**< */ 371 uint16_t length; /**< */ 372 xcb_drawable_t drawable; /**< */ 373 } xcb_dri2_get_msc_request_t; 374 375 /** 376 * @brief xcb_dri2_get_msc_reply_t 377 **/ 378 typedef struct xcb_dri2_get_msc_reply_t { 379 uint8_t response_type; /**< */ 380 uint8_t pad0; /**< */ 381 uint16_t sequence; /**< */ 382 uint32_t length; /**< */ 383 uint32_t ust_hi; /**< */ 384 uint32_t ust_lo; /**< */ 385 uint32_t msc_hi; /**< */ 386 uint32_t msc_lo; /**< */ 387 uint32_t sbc_hi; /**< */ 388 uint32_t sbc_lo; /**< */ 389 } xcb_dri2_get_msc_reply_t; 390 391 /** 392 * @brief xcb_dri2_wait_msc_cookie_t 393 **/ 394 typedef struct xcb_dri2_wait_msc_cookie_t { 395 unsigned int sequence; /**< */ 396 } xcb_dri2_wait_msc_cookie_t; 397 398 /** Opcode for xcb_dri2_wait_msc. */ 399 #define XCB_DRI2_WAIT_MSC 10 400 401 /** 402 * @brief xcb_dri2_wait_msc_request_t 403 **/ 404 typedef struct xcb_dri2_wait_msc_request_t { 405 uint8_t major_opcode; /**< */ 406 uint8_t minor_opcode; /**< */ 407 uint16_t length; /**< */ 408 xcb_drawable_t drawable; /**< */ 409 uint32_t target_msc_hi; /**< */ 410 uint32_t target_msc_lo; /**< */ 411 uint32_t divisor_hi; /**< */ 412 uint32_t divisor_lo; /**< */ 413 uint32_t remainder_hi; /**< */ 414 uint32_t remainder_lo; /**< */ 415 } xcb_dri2_wait_msc_request_t; 416 417 /** 418 * @brief xcb_dri2_wait_msc_reply_t 419 **/ 420 typedef struct xcb_dri2_wait_msc_reply_t { 421 uint8_t response_type; /**< */ 422 uint8_t pad0; /**< */ 423 uint16_t sequence; /**< */ 424 uint32_t length; /**< */ 425 uint32_t ust_hi; /**< */ 426 uint32_t ust_lo; /**< */ 427 uint32_t msc_hi; /**< */ 428 uint32_t msc_lo; /**< */ 429 uint32_t sbc_hi; /**< */ 430 uint32_t sbc_lo; /**< */ 431 } xcb_dri2_wait_msc_reply_t; 432 433 /** 434 * @brief xcb_dri2_wait_sbc_cookie_t 435 **/ 436 typedef struct xcb_dri2_wait_sbc_cookie_t { 437 unsigned int sequence; /**< */ 438 } xcb_dri2_wait_sbc_cookie_t; 439 440 /** Opcode for xcb_dri2_wait_sbc. */ 441 #define XCB_DRI2_WAIT_SBC 11 442 443 /** 444 * @brief xcb_dri2_wait_sbc_request_t 445 **/ 446 typedef struct xcb_dri2_wait_sbc_request_t { 447 uint8_t major_opcode; /**< */ 448 uint8_t minor_opcode; /**< */ 449 uint16_t length; /**< */ 450 xcb_drawable_t drawable; /**< */ 451 uint32_t target_sbc_hi; /**< */ 452 uint32_t target_sbc_lo; /**< */ 453 } xcb_dri2_wait_sbc_request_t; 454 455 /** 456 * @brief xcb_dri2_wait_sbc_reply_t 457 **/ 458 typedef struct xcb_dri2_wait_sbc_reply_t { 459 uint8_t response_type; /**< */ 460 uint8_t pad0; /**< */ 461 uint16_t sequence; /**< */ 462 uint32_t length; /**< */ 463 uint32_t ust_hi; /**< */ 464 uint32_t ust_lo; /**< */ 465 uint32_t msc_hi; /**< */ 466 uint32_t msc_lo; /**< */ 467 uint32_t sbc_hi; /**< */ 468 uint32_t sbc_lo; /**< */ 469 } xcb_dri2_wait_sbc_reply_t; 470 471 /** Opcode for xcb_dri2_swap_interval. */ 472 #define XCB_DRI2_SWAP_INTERVAL 12 473 474 /** 475 * @brief xcb_dri2_swap_interval_request_t 476 **/ 477 typedef struct xcb_dri2_swap_interval_request_t { 478 uint8_t major_opcode; /**< */ 479 uint8_t minor_opcode; /**< */ 480 uint16_t length; /**< */ 481 xcb_drawable_t drawable; /**< */ 482 uint32_t interval; /**< */ 483 } xcb_dri2_swap_interval_request_t; 484 485 /** 486 * @brief xcb_dri2_get_param_cookie_t 487 **/ 488 typedef struct xcb_dri2_get_param_cookie_t { 489 unsigned int sequence; /**< */ 490 } xcb_dri2_get_param_cookie_t; 491 492 /** Opcode for xcb_dri2_get_param. */ 493 #define XCB_DRI2_GET_PARAM 13 494 495 /** 496 * @brief xcb_dri2_get_param_request_t 497 **/ 498 typedef struct xcb_dri2_get_param_request_t { 499 uint8_t major_opcode; /**< */ 500 uint8_t minor_opcode; /**< */ 501 uint16_t length; /**< */ 502 xcb_drawable_t drawable; /**< */ 503 uint32_t param; /**< */ 504 } xcb_dri2_get_param_request_t; 505 506 /** 507 * @brief xcb_dri2_get_param_reply_t 508 **/ 509 typedef struct xcb_dri2_get_param_reply_t { 510 uint8_t response_type; /**< */ 511 uint8_t is_param_recognized; /**< */ 512 uint16_t sequence; /**< */ 513 uint32_t length; /**< */ 514 uint32_t value_hi; /**< */ 515 uint32_t value_lo; /**< */ 516 } xcb_dri2_get_param_reply_t; 517 518 /** Opcode for xcb_dri2_buffer_swap_complete. */ 519 #define XCB_DRI2_BUFFER_SWAP_COMPLETE 0 520 521 /** 522 * @brief xcb_dri2_buffer_swap_complete_event_t 523 **/ 524 typedef struct xcb_dri2_buffer_swap_complete_event_t { 525 uint8_t response_type; /**< */ 526 uint8_t pad0; /**< */ 527 uint16_t sequence; /**< */ 528 uint16_t event_type; /**< */ 529 uint8_t pad1[2]; /**< */ 530 xcb_drawable_t drawable; /**< */ 531 uint32_t ust_hi; /**< */ 532 uint32_t ust_lo; /**< */ 533 uint32_t msc_hi; /**< */ 534 uint32_t msc_lo; /**< */ 535 uint32_t sbc; /**< */ 536 } xcb_dri2_buffer_swap_complete_event_t; 537 538 /** Opcode for xcb_dri2_invalidate_buffers. */ 539 #define XCB_DRI2_INVALIDATE_BUFFERS 1 540 541 /** 542 * @brief xcb_dri2_invalidate_buffers_event_t 543 **/ 544 typedef struct xcb_dri2_invalidate_buffers_event_t { 545 uint8_t response_type; /**< */ 546 uint8_t pad0; /**< */ 547 uint16_t sequence; /**< */ 548 xcb_drawable_t drawable; /**< */ 549 } xcb_dri2_invalidate_buffers_event_t; 550 551 /** 552 * Get the next element of the iterator 553 * @param i Pointer to a xcb_dri2_dri2_buffer_iterator_t 554 * 555 * Get the next element in the iterator. The member rem is 556 * decreased by one. The member data points to the next 557 * element. The member index is increased by sizeof(xcb_dri2_dri2_buffer_t) 558 */ 559 void 560 xcb_dri2_dri2_buffer_next (xcb_dri2_dri2_buffer_iterator_t *i /**< */); 561 562 /** 563 * Return the iterator pointing to the last element 564 * @param i An xcb_dri2_dri2_buffer_iterator_t 565 * @return The iterator pointing to the last element 566 * 567 * Set the current element in the iterator to the last element. 568 * The member rem is set to 0. The member data points to the 569 * last element. 570 */ 571 xcb_generic_iterator_t 572 xcb_dri2_dri2_buffer_end (xcb_dri2_dri2_buffer_iterator_t i /**< */); 573 574 /** 575 * Get the next element of the iterator 576 * @param i Pointer to a xcb_dri2_attach_format_iterator_t 577 * 578 * Get the next element in the iterator. The member rem is 579 * decreased by one. The member data points to the next 580 * element. The member index is increased by sizeof(xcb_dri2_attach_format_t) 581 */ 582 void 583 xcb_dri2_attach_format_next (xcb_dri2_attach_format_iterator_t *i /**< */); 584 585 /** 586 * Return the iterator pointing to the last element 587 * @param i An xcb_dri2_attach_format_iterator_t 588 * @return The iterator pointing to the last element 589 * 590 * Set the current element in the iterator to the last element. 591 * The member rem is set to 0. The member data points to the 592 * last element. 593 */ 594 xcb_generic_iterator_t 595 xcb_dri2_attach_format_end (xcb_dri2_attach_format_iterator_t i /**< */); 596 597 /** 598 * 599 * @param c The connection 600 * @return A cookie 601 * 602 * Delivers a request to the X server. 603 * 604 */ 605 xcb_dri2_query_version_cookie_t 606 xcb_dri2_query_version (xcb_connection_t *c /**< */, 607 uint32_t major_version /**< */, 608 uint32_t minor_version /**< */); 609 610 /** 611 * 612 * @param c The connection 613 * @return A cookie 614 * 615 * Delivers a request to the X server. 616 * 617 * This form can be used only if the request will cause 618 * a reply to be generated. Any returned error will be 619 * placed in the event queue. 620 */ 621 xcb_dri2_query_version_cookie_t 622 xcb_dri2_query_version_unchecked (xcb_connection_t *c /**< */, 623 uint32_t major_version /**< */, 624 uint32_t minor_version /**< */); 625 626 /** 627 * Return the reply 628 * @param c The connection 629 * @param cookie The cookie 630 * @param e The xcb_generic_error_t supplied 631 * 632 * Returns the reply of the request asked by 633 * 634 * The parameter @p e supplied to this function must be NULL if 635 * xcb_dri2_query_version_unchecked(). is used. 636 * Otherwise, it stores the error if any. 637 * 638 * The returned value must be freed by the caller using free(). 639 */ 640 xcb_dri2_query_version_reply_t * 641 xcb_dri2_query_version_reply (xcb_connection_t *c /**< */, 642 xcb_dri2_query_version_cookie_t cookie /**< */, 643 xcb_generic_error_t **e /**< */); 644 645 int 646 xcb_dri2_connect_sizeof (const void *_buffer /**< */); 647 648 /** 649 * 650 * @param c The connection 651 * @return A cookie 652 * 653 * Delivers a request to the X server. 654 * 655 */ 656 xcb_dri2_connect_cookie_t 657 xcb_dri2_connect (xcb_connection_t *c /**< */, 658 xcb_window_t window /**< */, 659 uint32_t driver_type /**< */); 660 661 /** 662 * 663 * @param c The connection 664 * @return A cookie 665 * 666 * Delivers a request to the X server. 667 * 668 * This form can be used only if the request will cause 669 * a reply to be generated. Any returned error will be 670 * placed in the event queue. 671 */ 672 xcb_dri2_connect_cookie_t 673 xcb_dri2_connect_unchecked (xcb_connection_t *c /**< */, 674 xcb_window_t window /**< */, 675 uint32_t driver_type /**< */); 676 677 char * 678 xcb_dri2_connect_driver_name (const xcb_dri2_connect_reply_t *R /**< */); 679 680 int 681 xcb_dri2_connect_driver_name_length (const xcb_dri2_connect_reply_t *R /**< */); 682 683 xcb_generic_iterator_t 684 xcb_dri2_connect_driver_name_end (const xcb_dri2_connect_reply_t *R /**< */); 685 686 void * 687 xcb_dri2_connect_alignment_pad (const xcb_dri2_connect_reply_t *R /**< */); 688 689 int 690 xcb_dri2_connect_alignment_pad_length (const xcb_dri2_connect_reply_t *R /**< */); 691 692 xcb_generic_iterator_t 693 xcb_dri2_connect_alignment_pad_end (const xcb_dri2_connect_reply_t *R /**< */); 694 695 char * 696 xcb_dri2_connect_device_name (const xcb_dri2_connect_reply_t *R /**< */); 697 698 int 699 xcb_dri2_connect_device_name_length (const xcb_dri2_connect_reply_t *R /**< */); 700 701 xcb_generic_iterator_t 702 xcb_dri2_connect_device_name_end (const xcb_dri2_connect_reply_t *R /**< */); 703 704 /** 705 * Return the reply 706 * @param c The connection 707 * @param cookie The cookie 708 * @param e The xcb_generic_error_t supplied 709 * 710 * Returns the reply of the request asked by 711 * 712 * The parameter @p e supplied to this function must be NULL if 713 * xcb_dri2_connect_unchecked(). is used. 714 * Otherwise, it stores the error if any. 715 * 716 * The returned value must be freed by the caller using free(). 717 */ 718 xcb_dri2_connect_reply_t * 719 xcb_dri2_connect_reply (xcb_connection_t *c /**< */, 720 xcb_dri2_connect_cookie_t cookie /**< */, 721 xcb_generic_error_t **e /**< */); 722 723 /** 724 * 725 * @param c The connection 726 * @return A cookie 727 * 728 * Delivers a request to the X server. 729 * 730 */ 731 xcb_dri2_authenticate_cookie_t 732 xcb_dri2_authenticate (xcb_connection_t *c /**< */, 733 xcb_window_t window /**< */, 734 uint32_t magic /**< */); 735 736 /** 737 * 738 * @param c The connection 739 * @return A cookie 740 * 741 * Delivers a request to the X server. 742 * 743 * This form can be used only if the request will cause 744 * a reply to be generated. Any returned error will be 745 * placed in the event queue. 746 */ 747 xcb_dri2_authenticate_cookie_t 748 xcb_dri2_authenticate_unchecked (xcb_connection_t *c /**< */, 749 xcb_window_t window /**< */, 750 uint32_t magic /**< */); 751 752 /** 753 * Return the reply 754 * @param c The connection 755 * @param cookie The cookie 756 * @param e The xcb_generic_error_t supplied 757 * 758 * Returns the reply of the request asked by 759 * 760 * The parameter @p e supplied to this function must be NULL if 761 * xcb_dri2_authenticate_unchecked(). is used. 762 * Otherwise, it stores the error if any. 763 * 764 * The returned value must be freed by the caller using free(). 765 */ 766 xcb_dri2_authenticate_reply_t * 767 xcb_dri2_authenticate_reply (xcb_connection_t *c /**< */, 768 xcb_dri2_authenticate_cookie_t cookie /**< */, 769 xcb_generic_error_t **e /**< */); 770 771 /** 772 * 773 * @param c The connection 774 * @return A cookie 775 * 776 * Delivers a request to the X server. 777 * 778 * This form can be used only if the request will not cause 779 * a reply to be generated. Any returned error will be 780 * saved for handling by xcb_request_check(). 781 */ 782 xcb_void_cookie_t 783 xcb_dri2_create_drawable_checked (xcb_connection_t *c /**< */, 784 xcb_drawable_t drawable /**< */); 785 786 /** 787 * 788 * @param c The connection 789 * @return A cookie 790 * 791 * Delivers a request to the X server. 792 * 793 */ 794 xcb_void_cookie_t 795 xcb_dri2_create_drawable (xcb_connection_t *c /**< */, 796 xcb_drawable_t drawable /**< */); 797 798 /** 799 * 800 * @param c The connection 801 * @return A cookie 802 * 803 * Delivers a request to the X server. 804 * 805 * This form can be used only if the request will not cause 806 * a reply to be generated. Any returned error will be 807 * saved for handling by xcb_request_check(). 808 */ 809 xcb_void_cookie_t 810 xcb_dri2_destroy_drawable_checked (xcb_connection_t *c /**< */, 811 xcb_drawable_t drawable /**< */); 812 813 /** 814 * 815 * @param c The connection 816 * @return A cookie 817 * 818 * Delivers a request to the X server. 819 * 820 */ 821 xcb_void_cookie_t 822 xcb_dri2_destroy_drawable (xcb_connection_t *c /**< */, 823 xcb_drawable_t drawable /**< */); 824 825 int 826 xcb_dri2_get_buffers_sizeof (const void *_buffer /**< */, 827 uint32_t attachments_len /**< */); 828 829 /** 830 * 831 * @param c The connection 832 * @return A cookie 833 * 834 * Delivers a request to the X server. 835 * 836 */ 837 xcb_dri2_get_buffers_cookie_t 838 xcb_dri2_get_buffers (xcb_connection_t *c /**< */, 839 xcb_drawable_t drawable /**< */, 840 uint32_t count /**< */, 841 uint32_t attachments_len /**< */, 842 const uint32_t *attachments /**< */); 843 844 /** 845 * 846 * @param c The connection 847 * @return A cookie 848 * 849 * Delivers a request to the X server. 850 * 851 * This form can be used only if the request will cause 852 * a reply to be generated. Any returned error will be 853 * placed in the event queue. 854 */ 855 xcb_dri2_get_buffers_cookie_t 856 xcb_dri2_get_buffers_unchecked (xcb_connection_t *c /**< */, 857 xcb_drawable_t drawable /**< */, 858 uint32_t count /**< */, 859 uint32_t attachments_len /**< */, 860 const uint32_t *attachments /**< */); 861 862 xcb_dri2_dri2_buffer_t * 863 xcb_dri2_get_buffers_buffers (const xcb_dri2_get_buffers_reply_t *R /**< */); 864 865 int 866 xcb_dri2_get_buffers_buffers_length (const xcb_dri2_get_buffers_reply_t *R /**< */); 867 868 xcb_dri2_dri2_buffer_iterator_t 869 xcb_dri2_get_buffers_buffers_iterator (const xcb_dri2_get_buffers_reply_t *R /**< */); 870 871 /** 872 * Return the reply 873 * @param c The connection 874 * @param cookie The cookie 875 * @param e The xcb_generic_error_t supplied 876 * 877 * Returns the reply of the request asked by 878 * 879 * The parameter @p e supplied to this function must be NULL if 880 * xcb_dri2_get_buffers_unchecked(). is used. 881 * Otherwise, it stores the error if any. 882 * 883 * The returned value must be freed by the caller using free(). 884 */ 885 xcb_dri2_get_buffers_reply_t * 886 xcb_dri2_get_buffers_reply (xcb_connection_t *c /**< */, 887 xcb_dri2_get_buffers_cookie_t cookie /**< */, 888 xcb_generic_error_t **e /**< */); 889 890 /** 891 * 892 * @param c The connection 893 * @return A cookie 894 * 895 * Delivers a request to the X server. 896 * 897 */ 898 xcb_dri2_copy_region_cookie_t 899 xcb_dri2_copy_region (xcb_connection_t *c /**< */, 900 xcb_drawable_t drawable /**< */, 901 uint32_t region /**< */, 902 uint32_t dest /**< */, 903 uint32_t src /**< */); 904 905 /** 906 * 907 * @param c The connection 908 * @return A cookie 909 * 910 * Delivers a request to the X server. 911 * 912 * This form can be used only if the request will cause 913 * a reply to be generated. Any returned error will be 914 * placed in the event queue. 915 */ 916 xcb_dri2_copy_region_cookie_t 917 xcb_dri2_copy_region_unchecked (xcb_connection_t *c /**< */, 918 xcb_drawable_t drawable /**< */, 919 uint32_t region /**< */, 920 uint32_t dest /**< */, 921 uint32_t src /**< */); 922 923 /** 924 * Return the reply 925 * @param c The connection 926 * @param cookie The cookie 927 * @param e The xcb_generic_error_t supplied 928 * 929 * Returns the reply of the request asked by 930 * 931 * The parameter @p e supplied to this function must be NULL if 932 * xcb_dri2_copy_region_unchecked(). is used. 933 * Otherwise, it stores the error if any. 934 * 935 * The returned value must be freed by the caller using free(). 936 */ 937 xcb_dri2_copy_region_reply_t * 938 xcb_dri2_copy_region_reply (xcb_connection_t *c /**< */, 939 xcb_dri2_copy_region_cookie_t cookie /**< */, 940 xcb_generic_error_t **e /**< */); 941 942 int 943 xcb_dri2_get_buffers_with_format_sizeof (const void *_buffer /**< */, 944 uint32_t attachments_len /**< */); 945 946 /** 947 * 948 * @param c The connection 949 * @return A cookie 950 * 951 * Delivers a request to the X server. 952 * 953 */ 954 xcb_dri2_get_buffers_with_format_cookie_t 955 xcb_dri2_get_buffers_with_format (xcb_connection_t *c /**< */, 956 xcb_drawable_t drawable /**< */, 957 uint32_t count /**< */, 958 uint32_t attachments_len /**< */, 959 const xcb_dri2_attach_format_t *attachments /**< */); 960 961 /** 962 * 963 * @param c The connection 964 * @return A cookie 965 * 966 * Delivers a request to the X server. 967 * 968 * This form can be used only if the request will cause 969 * a reply to be generated. Any returned error will be 970 * placed in the event queue. 971 */ 972 xcb_dri2_get_buffers_with_format_cookie_t 973 xcb_dri2_get_buffers_with_format_unchecked (xcb_connection_t *c /**< */, 974 xcb_drawable_t drawable /**< */, 975 uint32_t count /**< */, 976 uint32_t attachments_len /**< */, 977 const xcb_dri2_attach_format_t *attachments /**< */); 978 979 xcb_dri2_dri2_buffer_t * 980 xcb_dri2_get_buffers_with_format_buffers (const xcb_dri2_get_buffers_with_format_reply_t *R /**< */); 981 982 int 983 xcb_dri2_get_buffers_with_format_buffers_length (const xcb_dri2_get_buffers_with_format_reply_t *R /**< */); 984 985 xcb_dri2_dri2_buffer_iterator_t 986 xcb_dri2_get_buffers_with_format_buffers_iterator (const xcb_dri2_get_buffers_with_format_reply_t *R /**< */); 987 988 /** 989 * Return the reply 990 * @param c The connection 991 * @param cookie The cookie 992 * @param e The xcb_generic_error_t supplied 993 * 994 * Returns the reply of the request asked by 995 * 996 * The parameter @p e supplied to this function must be NULL if 997 * xcb_dri2_get_buffers_with_format_unchecked(). is used. 998 * Otherwise, it stores the error if any. 999 * 1000 * The returned value must be freed by the caller using free(). 1001 */ 1002 xcb_dri2_get_buffers_with_format_reply_t * 1003 xcb_dri2_get_buffers_with_format_reply (xcb_connection_t *c /**< */, 1004 xcb_dri2_get_buffers_with_format_cookie_t cookie /**< */, 1005 xcb_generic_error_t **e /**< */); 1006 1007 /** 1008 * 1009 * @param c The connection 1010 * @return A cookie 1011 * 1012 * Delivers a request to the X server. 1013 * 1014 */ 1015 xcb_dri2_swap_buffers_cookie_t 1016 xcb_dri2_swap_buffers (xcb_connection_t *c /**< */, 1017 xcb_drawable_t drawable /**< */, 1018 uint32_t target_msc_hi /**< */, 1019 uint32_t target_msc_lo /**< */, 1020 uint32_t divisor_hi /**< */, 1021 uint32_t divisor_lo /**< */, 1022 uint32_t remainder_hi /**< */, 1023 uint32_t remainder_lo /**< */); 1024 1025 /** 1026 * 1027 * @param c The connection 1028 * @return A cookie 1029 * 1030 * Delivers a request to the X server. 1031 * 1032 * This form can be used only if the request will cause 1033 * a reply to be generated. Any returned error will be 1034 * placed in the event queue. 1035 */ 1036 xcb_dri2_swap_buffers_cookie_t 1037 xcb_dri2_swap_buffers_unchecked (xcb_connection_t *c /**< */, 1038 xcb_drawable_t drawable /**< */, 1039 uint32_t target_msc_hi /**< */, 1040 uint32_t target_msc_lo /**< */, 1041 uint32_t divisor_hi /**< */, 1042 uint32_t divisor_lo /**< */, 1043 uint32_t remainder_hi /**< */, 1044 uint32_t remainder_lo /**< */); 1045 1046 /** 1047 * Return the reply 1048 * @param c The connection 1049 * @param cookie The cookie 1050 * @param e The xcb_generic_error_t supplied 1051 * 1052 * Returns the reply of the request asked by 1053 * 1054 * The parameter @p e supplied to this function must be NULL if 1055 * xcb_dri2_swap_buffers_unchecked(). is used. 1056 * Otherwise, it stores the error if any. 1057 * 1058 * The returned value must be freed by the caller using free(). 1059 */ 1060 xcb_dri2_swap_buffers_reply_t * 1061 xcb_dri2_swap_buffers_reply (xcb_connection_t *c /**< */, 1062 xcb_dri2_swap_buffers_cookie_t cookie /**< */, 1063 xcb_generic_error_t **e /**< */); 1064 1065 /** 1066 * 1067 * @param c The connection 1068 * @return A cookie 1069 * 1070 * Delivers a request to the X server. 1071 * 1072 */ 1073 xcb_dri2_get_msc_cookie_t 1074 xcb_dri2_get_msc (xcb_connection_t *c /**< */, 1075 xcb_drawable_t drawable /**< */); 1076 1077 /** 1078 * 1079 * @param c The connection 1080 * @return A cookie 1081 * 1082 * Delivers a request to the X server. 1083 * 1084 * This form can be used only if the request will cause 1085 * a reply to be generated. Any returned error will be 1086 * placed in the event queue. 1087 */ 1088 xcb_dri2_get_msc_cookie_t 1089 xcb_dri2_get_msc_unchecked (xcb_connection_t *c /**< */, 1090 xcb_drawable_t drawable /**< */); 1091 1092 /** 1093 * Return the reply 1094 * @param c The connection 1095 * @param cookie The cookie 1096 * @param e The xcb_generic_error_t supplied 1097 * 1098 * Returns the reply of the request asked by 1099 * 1100 * The parameter @p e supplied to this function must be NULL if 1101 * xcb_dri2_get_msc_unchecked(). is used. 1102 * Otherwise, it stores the error if any. 1103 * 1104 * The returned value must be freed by the caller using free(). 1105 */ 1106 xcb_dri2_get_msc_reply_t * 1107 xcb_dri2_get_msc_reply (xcb_connection_t *c /**< */, 1108 xcb_dri2_get_msc_cookie_t cookie /**< */, 1109 xcb_generic_error_t **e /**< */); 1110 1111 /** 1112 * 1113 * @param c The connection 1114 * @return A cookie 1115 * 1116 * Delivers a request to the X server. 1117 * 1118 */ 1119 xcb_dri2_wait_msc_cookie_t 1120 xcb_dri2_wait_msc (xcb_connection_t *c /**< */, 1121 xcb_drawable_t drawable /**< */, 1122 uint32_t target_msc_hi /**< */, 1123 uint32_t target_msc_lo /**< */, 1124 uint32_t divisor_hi /**< */, 1125 uint32_t divisor_lo /**< */, 1126 uint32_t remainder_hi /**< */, 1127 uint32_t remainder_lo /**< */); 1128 1129 /** 1130 * 1131 * @param c The connection 1132 * @return A cookie 1133 * 1134 * Delivers a request to the X server. 1135 * 1136 * This form can be used only if the request will cause 1137 * a reply to be generated. Any returned error will be 1138 * placed in the event queue. 1139 */ 1140 xcb_dri2_wait_msc_cookie_t 1141 xcb_dri2_wait_msc_unchecked (xcb_connection_t *c /**< */, 1142 xcb_drawable_t drawable /**< */, 1143 uint32_t target_msc_hi /**< */, 1144 uint32_t target_msc_lo /**< */, 1145 uint32_t divisor_hi /**< */, 1146 uint32_t divisor_lo /**< */, 1147 uint32_t remainder_hi /**< */, 1148 uint32_t remainder_lo /**< */); 1149 1150 /** 1151 * Return the reply 1152 * @param c The connection 1153 * @param cookie The cookie 1154 * @param e The xcb_generic_error_t supplied 1155 * 1156 * Returns the reply of the request asked by 1157 * 1158 * The parameter @p e supplied to this function must be NULL if 1159 * xcb_dri2_wait_msc_unchecked(). is used. 1160 * Otherwise, it stores the error if any. 1161 * 1162 * The returned value must be freed by the caller using free(). 1163 */ 1164 xcb_dri2_wait_msc_reply_t * 1165 xcb_dri2_wait_msc_reply (xcb_connection_t *c /**< */, 1166 xcb_dri2_wait_msc_cookie_t cookie /**< */, 1167 xcb_generic_error_t **e /**< */); 1168 1169 /** 1170 * 1171 * @param c The connection 1172 * @return A cookie 1173 * 1174 * Delivers a request to the X server. 1175 * 1176 */ 1177 xcb_dri2_wait_sbc_cookie_t 1178 xcb_dri2_wait_sbc (xcb_connection_t *c /**< */, 1179 xcb_drawable_t drawable /**< */, 1180 uint32_t target_sbc_hi /**< */, 1181 uint32_t target_sbc_lo /**< */); 1182 1183 /** 1184 * 1185 * @param c The connection 1186 * @return A cookie 1187 * 1188 * Delivers a request to the X server. 1189 * 1190 * This form can be used only if the request will cause 1191 * a reply to be generated. Any returned error will be 1192 * placed in the event queue. 1193 */ 1194 xcb_dri2_wait_sbc_cookie_t 1195 xcb_dri2_wait_sbc_unchecked (xcb_connection_t *c /**< */, 1196 xcb_drawable_t drawable /**< */, 1197 uint32_t target_sbc_hi /**< */, 1198 uint32_t target_sbc_lo /**< */); 1199 1200 /** 1201 * Return the reply 1202 * @param c The connection 1203 * @param cookie The cookie 1204 * @param e The xcb_generic_error_t supplied 1205 * 1206 * Returns the reply of the request asked by 1207 * 1208 * The parameter @p e supplied to this function must be NULL if 1209 * xcb_dri2_wait_sbc_unchecked(). is used. 1210 * Otherwise, it stores the error if any. 1211 * 1212 * The returned value must be freed by the caller using free(). 1213 */ 1214 xcb_dri2_wait_sbc_reply_t * 1215 xcb_dri2_wait_sbc_reply (xcb_connection_t *c /**< */, 1216 xcb_dri2_wait_sbc_cookie_t cookie /**< */, 1217 xcb_generic_error_t **e /**< */); 1218 1219 /** 1220 * 1221 * @param c The connection 1222 * @return A cookie 1223 * 1224 * Delivers a request to the X server. 1225 * 1226 * This form can be used only if the request will not cause 1227 * a reply to be generated. Any returned error will be 1228 * saved for handling by xcb_request_check(). 1229 */ 1230 xcb_void_cookie_t 1231 xcb_dri2_swap_interval_checked (xcb_connection_t *c /**< */, 1232 xcb_drawable_t drawable /**< */, 1233 uint32_t interval /**< */); 1234 1235 /** 1236 * 1237 * @param c The connection 1238 * @return A cookie 1239 * 1240 * Delivers a request to the X server. 1241 * 1242 */ 1243 xcb_void_cookie_t 1244 xcb_dri2_swap_interval (xcb_connection_t *c /**< */, 1245 xcb_drawable_t drawable /**< */, 1246 uint32_t interval /**< */); 1247 1248 /** 1249 * 1250 * @param c The connection 1251 * @return A cookie 1252 * 1253 * Delivers a request to the X server. 1254 * 1255 */ 1256 xcb_dri2_get_param_cookie_t 1257 xcb_dri2_get_param (xcb_connection_t *c /**< */, 1258 xcb_drawable_t drawable /**< */, 1259 uint32_t param /**< */); 1260 1261 /** 1262 * 1263 * @param c The connection 1264 * @return A cookie 1265 * 1266 * Delivers a request to the X server. 1267 * 1268 * This form can be used only if the request will cause 1269 * a reply to be generated. Any returned error will be 1270 * placed in the event queue. 1271 */ 1272 xcb_dri2_get_param_cookie_t 1273 xcb_dri2_get_param_unchecked (xcb_connection_t *c /**< */, 1274 xcb_drawable_t drawable /**< */, 1275 uint32_t param /**< */); 1276 1277 /** 1278 * Return the reply 1279 * @param c The connection 1280 * @param cookie The cookie 1281 * @param e The xcb_generic_error_t supplied 1282 * 1283 * Returns the reply of the request asked by 1284 * 1285 * The parameter @p e supplied to this function must be NULL if 1286 * xcb_dri2_get_param_unchecked(). is used. 1287 * Otherwise, it stores the error if any. 1288 * 1289 * The returned value must be freed by the caller using free(). 1290 */ 1291 xcb_dri2_get_param_reply_t * 1292 xcb_dri2_get_param_reply (xcb_connection_t *c /**< */, 1293 xcb_dri2_get_param_cookie_t cookie /**< */, 1294 xcb_generic_error_t **e /**< */); 1295 1296 1297 #ifdef __cplusplus 1298 } 1299 #endif 1300 1301 #endif 1302 1303 /** 1304 * @} 1305 */ 1306