00001
00002
00003
00004
00005
00012 #ifndef __DAMAGE_H
00013 #define __DAMAGE_H
00014
00015 #include "xcb.h"
00016 #include "xproto.h"
00017 #include "xfixes.h"
00018
00019 #define XCB_DAMAGE_MAJOR_VERSION 1
00020 #define XCB_DAMAGE_MINOR_VERSION 0
00021
00022 extern xcb_extension_t xcb_damage_id;
00023
00024 typedef uint32_t xcb_damage_damage_t;
00025
00029 typedef struct xcb_damage_damage_iterator_t {
00030 xcb_damage_damage_t *data;
00031 int rem;
00032 int index;
00033 } xcb_damage_damage_iterator_t;
00034
00035 typedef enum xcb_damage_report_level_t {
00036 XCB_DAMAGE_REPORT_LEVEL_RAW_RECTANGLES,
00037 XCB_DAMAGE_REPORT_LEVEL_DELTA_RECTANGLES,
00038 XCB_DAMAGE_REPORT_LEVEL_BOUNDING_BOX,
00039 XCB_DAMAGE_REPORT_LEVEL_NON_EMPTY
00040 } xcb_damage_report_level_t;
00041
00043 #define XCB_DAMAGE_BAD_DAMAGE 0
00044
00048 typedef struct xcb_damage_bad_damage_error_t {
00049 uint8_t response_type;
00050 uint8_t error_code;
00051 uint16_t sequence;
00052 } xcb_damage_bad_damage_error_t;
00053
00057 typedef struct xcb_damage_query_version_cookie_t {
00058 unsigned int sequence;
00059 } xcb_damage_query_version_cookie_t;
00060
00062 #define XCB_DAMAGE_QUERY_VERSION 0
00063
00067 typedef struct xcb_damage_query_version_request_t {
00068 uint8_t major_opcode;
00069 uint8_t minor_opcode;
00070 uint16_t length;
00071 uint32_t client_major_version;
00072 uint32_t client_minor_version;
00073 } xcb_damage_query_version_request_t;
00074
00078 typedef struct xcb_damage_query_version_reply_t {
00079 uint8_t response_type;
00080 uint8_t pad0;
00081 uint16_t sequence;
00082 uint32_t length;
00083 uint32_t major_version;
00084 uint32_t minor_version;
00085 uint8_t pad1[16];
00086 } xcb_damage_query_version_reply_t;
00087
00089 #define XCB_DAMAGE_CREATE 1
00090
00094 typedef struct xcb_damage_create_request_t {
00095 uint8_t major_opcode;
00096 uint8_t minor_opcode;
00097 uint16_t length;
00098 xcb_damage_damage_t damage;
00099 xcb_drawable_t drawable;
00100 uint8_t level;
00101 uint8_t pad0[3];
00102 } xcb_damage_create_request_t;
00103
00105 #define XCB_DAMAGE_DESTROY 2
00106
00110 typedef struct xcb_damage_destroy_request_t {
00111 uint8_t major_opcode;
00112 uint8_t minor_opcode;
00113 uint16_t length;
00114 xcb_damage_damage_t damage;
00115 } xcb_damage_destroy_request_t;
00116
00118 #define XCB_DAMAGE_SUBTRACT 3
00119
00123 typedef struct xcb_damage_subtract_request_t {
00124 uint8_t major_opcode;
00125 uint8_t minor_opcode;
00126 uint16_t length;
00127 xcb_damage_damage_t damage;
00128 xcb_xfixes_region_t repair;
00129 xcb_xfixes_region_t parts;
00130 } xcb_damage_subtract_request_t;
00131
00133 #define XCB_DAMAGE_NOTIFY 0
00134
00138 typedef struct xcb_damage_notify_event_t {
00139 uint8_t response_type;
00140 uint8_t level;
00141 uint16_t sequence;
00142 xcb_drawable_t drawable;
00143 xcb_damage_damage_t damage;
00144 xcb_timestamp_t timestamp;
00145 xcb_rectangle_t area;
00146 xcb_rectangle_t geometry;
00147 } xcb_damage_notify_event_t;
00148
00149
00150
00151
00152
00153
00154
00155
00156
00157
00158
00159 void
00160 xcb_damage_damage_next (xcb_damage_damage_iterator_t *i );
00161
00162
00163
00164
00165
00166
00167
00168
00169
00170
00171
00172 xcb_generic_iterator_t
00173 xcb_damage_damage_end (xcb_damage_damage_iterator_t i );
00174
00175
00176
00177
00178
00179
00180
00181
00182
00183
00184
00185
00186
00187 xcb_damage_query_version_cookie_t
00188 xcb_damage_query_version (xcb_connection_t *c ,
00189 uint32_t client_major_version ,
00190 uint32_t client_minor_version );
00191
00192
00193
00194
00195
00196
00197
00198
00199
00200
00201
00202
00203
00204 xcb_damage_query_version_cookie_t
00205 xcb_damage_query_version_unchecked (xcb_connection_t *c ,
00206 uint32_t client_major_version ,
00207 uint32_t client_minor_version );
00208
00209
00210
00211
00212
00213
00214
00215
00216
00217
00218
00219
00220
00221 xcb_damage_query_version_reply_t *
00222 xcb_damage_query_version_reply (xcb_connection_t *c ,
00223 xcb_damage_query_version_cookie_t cookie ,
00224 xcb_generic_error_t **e );
00225
00226
00227
00228
00229
00230
00231
00232
00233
00234
00235
00236
00237
00238
00239 xcb_void_cookie_t
00240 xcb_damage_create_checked (xcb_connection_t *c ,
00241 xcb_damage_damage_t damage ,
00242 xcb_drawable_t drawable ,
00243 uint8_t level );
00244
00245
00246
00247
00248
00249
00250
00251
00252
00253
00254
00255
00256
00257
00258 xcb_void_cookie_t
00259 xcb_damage_create (xcb_connection_t *c ,
00260 xcb_damage_damage_t damage ,
00261 xcb_drawable_t drawable ,
00262 uint8_t level );
00263
00264
00265
00266
00267
00268
00269
00270
00271
00272
00273
00274
00275 xcb_void_cookie_t
00276 xcb_damage_destroy_checked (xcb_connection_t *c ,
00277 xcb_damage_damage_t damage );
00278
00279
00280
00281
00282
00283
00284
00285
00286
00287
00288
00289
00290 xcb_void_cookie_t
00291 xcb_damage_destroy (xcb_connection_t *c ,
00292 xcb_damage_damage_t damage );
00293
00294
00295
00296
00297
00298
00299
00300
00301
00302
00303
00304
00305
00306
00307 xcb_void_cookie_t
00308 xcb_damage_subtract_checked (xcb_connection_t *c ,
00309 xcb_damage_damage_t damage ,
00310 xcb_xfixes_region_t repair ,
00311 xcb_xfixes_region_t parts );
00312
00313
00314
00315
00316
00317
00318
00319
00320
00321
00322
00323
00324
00325
00326 xcb_void_cookie_t
00327 xcb_damage_subtract (xcb_connection_t *c ,
00328 xcb_damage_damage_t damage ,
00329 xcb_xfixes_region_t repair ,
00330 xcb_xfixes_region_t parts );
00331
00332
00333 #endif
00334