diff options
author | Michael Drake <tlsa@netsurf-browser.org> | 2021-12-14 11:11:07 +0000 |
---|---|---|
committer | Michael Drake <tlsa@netsurf-browser.org> | 2022-02-23 11:32:42 +0000 |
commit | fedd37d9ce70571f305c8c8e66fd9ec7d837585b (patch) | |
tree | a864563f8696c4cfa779cae9593c5370dae1ad39 /include | |
parent | 87c9a0ce41757c9c0ff2f3f19054edfd8296ef31 (diff) | |
download | libnsgif-fedd37d9ce70571f305c8c8e66fd9ec7d837585b.tar.gz libnsgif-fedd37d9ce70571f305c8c8e66fd9ec7d837585b.tar.bz2 |
API: Split out redraw rectangle.
Diffstat (limited to 'include')
-rw-r--r-- | include/nsgif.h | 23 |
1 files changed, 15 insertions, 8 deletions
diff --git a/include/nsgif.h b/include/nsgif.h index 114addf..8e84519 100644 --- a/include/nsgif.h +++ b/include/nsgif.h @@ -32,6 +32,18 @@ typedef enum { NSGIF_END_OF_FRAME = -7 } nsgif_result; +/** GIF rectangle structure. */ +typedef struct nsgif_rect { + /** x co-ordinate of redraw rectangle */ + uint32_t x; + /** y co-ordinate of redraw rectangle */ + uint32_t y; + /** width of redraw rectangle */ + uint32_t w; + /** height of redraw rectangle */ + uint32_t h; +} nsgif_rect; + /** GIF frame data */ typedef struct nsgif_frame { /** whether the frame should be displayed/animated */ @@ -55,16 +67,11 @@ typedef struct nsgif_frame { bool transparency; /** the index designating a transparent pixel */ uint32_t transparency_index; - /** x co-ordinate of redraw rectangle */ - uint32_t redraw_x; - /** y co-ordinate of redraw rectangle */ - uint32_t redraw_y; - /** width of redraw rectangle */ - uint32_t redraw_width; - /** height of redraw rectangle */ - uint32_t redraw_height; /* Frame flags */ uint32_t flags; + + /** Frame's redraw rectangle. */ + nsgif_rect redraw; } nsgif_frame; /* API for Bitmap callbacks */ |