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 1
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_ADD 4
00134
00138 typedef struct xcb_damage_add_request_t {
00139 uint8_t major_opcode;
00140 uint8_t minor_opcode;
00141 uint16_t length;
00142 xcb_drawable_t drawable;
00143 xcb_xfixes_region_t region;
00144 } xcb_damage_add_request_t;
00145
00147 #define XCB_DAMAGE_NOTIFY 0
00148
00152 typedef struct xcb_damage_notify_event_t {
00153 uint8_t response_type;
00154 uint8_t level;
00155 uint16_t sequence;
00156 xcb_drawable_t drawable;
00157 xcb_damage_damage_t damage;
00158 xcb_timestamp_t timestamp;
00159 xcb_rectangle_t area;
00160 xcb_rectangle_t geometry;
00161 } xcb_damage_notify_event_t;
00162
00172
00173
00174
00175
00176
00177
00178
00179
00180
00181 void
00182 xcb_damage_damage_next (xcb_damage_damage_iterator_t *i );
00183
00194
00195
00196
00197
00198
00199
00200
00201
00202
00203 xcb_generic_iterator_t
00204 xcb_damage_damage_end (xcb_damage_damage_iterator_t i );
00205
00215
00216
00217
00218
00219
00220
00221
00222
00223
00224
00225
00226 xcb_damage_query_version_cookie_t
00227 xcb_damage_query_version (xcb_connection_t *c ,
00228 uint32_t client_major_version ,
00229 uint32_t client_minor_version );
00230
00243
00244
00245
00246
00247
00248
00249
00250
00251
00252
00253
00254 xcb_damage_query_version_cookie_t
00255 xcb_damage_query_version_unchecked (xcb_connection_t *c ,
00256 uint32_t client_major_version ,
00257 uint32_t client_minor_version );
00258
00272
00273
00274
00275
00276
00277
00278
00279
00280
00281
00282
00283 xcb_damage_query_version_reply_t *
00284 xcb_damage_query_version_reply (xcb_connection_t *c ,
00285 xcb_damage_query_version_cookie_t cookie ,
00286 xcb_generic_error_t **e );
00287
00300
00301
00302
00303
00304
00305
00306
00307
00308
00309
00310
00311
00312 xcb_void_cookie_t
00313 xcb_damage_create_checked (xcb_connection_t *c ,
00314 xcb_damage_damage_t damage ,
00315 xcb_drawable_t drawable ,
00316 uint8_t level );
00317
00327
00328
00329
00330
00331
00332
00333
00334
00335
00336
00337
00338
00339 xcb_void_cookie_t
00340 xcb_damage_create (xcb_connection_t *c ,
00341 xcb_damage_damage_t damage ,
00342 xcb_drawable_t drawable ,
00343 uint8_t level );
00344
00357
00358
00359
00360
00361
00362
00363
00364
00365
00366
00367 xcb_void_cookie_t
00368 xcb_damage_destroy_checked (xcb_connection_t *c ,
00369 xcb_damage_damage_t damage );
00370
00380
00381
00382
00383
00384
00385
00386
00387
00388
00389
00390 xcb_void_cookie_t
00391 xcb_damage_destroy (xcb_connection_t *c ,
00392 xcb_damage_damage_t damage );
00393
00406
00407
00408
00409
00410
00411
00412
00413
00414
00415
00416
00417
00418 xcb_void_cookie_t
00419 xcb_damage_subtract_checked (xcb_connection_t *c ,
00420 xcb_damage_damage_t damage ,
00421 xcb_xfixes_region_t repair ,
00422 xcb_xfixes_region_t parts );
00423
00433
00434
00435
00436
00437
00438
00439
00440
00441
00442
00443
00444
00445 xcb_void_cookie_t
00446 xcb_damage_subtract (xcb_connection_t *c ,
00447 xcb_damage_damage_t damage ,
00448 xcb_xfixes_region_t repair ,
00449 xcb_xfixes_region_t parts );
00450
00463
00464
00465
00466
00467
00468
00469
00470
00471
00472
00473
00474 xcb_void_cookie_t
00475 xcb_damage_add_checked (xcb_connection_t *c ,
00476 xcb_drawable_t drawable ,
00477 xcb_xfixes_region_t region );
00478
00488
00489
00490
00491
00492
00493
00494
00495
00496
00497
00498
00499 xcb_void_cookie_t
00500 xcb_damage_add (xcb_connection_t *c ,
00501 xcb_drawable_t drawable ,
00502 xcb_xfixes_region_t region );
00503
00504
00505 #endif
00506