00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028 #ifndef __XCBEXT_H
00029 #define __XCBEXT_H
00030
00031 #include "xcb.h"
00032
00033 #ifdef __cplusplus
00034 extern "C" {
00035 #endif
00036
00037
00038
00039 struct xcb_extension_t {
00040 const char *name;
00041 int global_id;
00042 };
00043
00044
00045
00046
00047 typedef struct {
00048 size_t count;
00049 xcb_extension_t *ext;
00050 uint8_t opcode;
00051 uint8_t isvoid;
00052 } xcb_protocol_request_t;
00053
00054 enum xcb_send_request_flags_t {
00055 XCB_REQUEST_CHECKED = 1 << 0,
00056 XCB_REQUEST_RAW = 1 << 1,
00057 XCB_REQUEST_DISCARD_REPLY = 1 << 2,
00058 XCB_REQUEST_REPLY_FDS = 1 << 3
00059 };
00060
00083 unsigned int xcb_send_request(xcb_connection_t *c, int flags, struct iovec *vector, const xcb_protocol_request_t *request);
00084
00107 uint64_t xcb_send_request64(xcb_connection_t *c, int flags, struct iovec *vector, const xcb_protocol_request_t *request);
00108
00121 void xcb_send_fd(xcb_connection_t *c, int fd);
00122
00150 int xcb_take_socket(xcb_connection_t *c, void (*return_socket)(void *closure), void *closure, int flags, uint64_t *sent);
00151
00171 int xcb_writev(xcb_connection_t *c, struct iovec *vector, int count, uint64_t requests);
00172
00173
00174
00175
00186 void *xcb_wait_for_reply(xcb_connection_t *c, unsigned int request, xcb_generic_error_t **e);
00187
00201 void *xcb_wait_for_reply64(xcb_connection_t *c, uint64_t request, xcb_generic_error_t **e);
00202
00213 int xcb_poll_for_reply(xcb_connection_t *c, unsigned int request, void **reply, xcb_generic_error_t **error);
00214
00228 int xcb_poll_for_reply64(xcb_connection_t *c, uint64_t request, void **reply, xcb_generic_error_t **error);
00229
00237 int *xcb_get_reply_fds(xcb_connection_t *c, void *reply, size_t replylen);
00238
00239
00240
00241
00246 int xcb_popcount(uint32_t mask);
00247
00253 int xcb_sumof(uint8_t *list, int len);
00254
00255 #ifdef __cplusplus
00256 }
00257 #endif
00258
00259 #endif