diff options
author | Michael Drake <tlsa@netsurf-browser.org> | 2022-02-26 13:26:41 +0000 |
---|---|---|
committer | Michael Drake <tlsa@netsurf-browser.org> | 2022-02-26 13:26:41 +0000 |
commit | ff86c40667cdaa2a535c992f908ba15912d93d59 (patch) | |
tree | 730445a3c6d9a8fc8d6115d4c12672530656565a | |
parent | a0b9fcb4fa4c53319726044c8278a551293af817 (diff) | |
download | libnsgif-ff86c40667cdaa2a535c992f908ba15912d93d59.tar.gz libnsgif-ff86c40667cdaa2a535c992f908ba15912d93d59.tar.bz2 |
GIF: Minimum gif delay shouldn't be public.
-rw-r--r-- | include/nsgif.h | 2 | ||||
-rw-r--r-- | src/gif.c | 6 |
2 files changed, 4 insertions, 4 deletions
diff --git a/include/nsgif.h b/include/nsgif.h index f03d121..550fea3 100644 --- a/include/nsgif.h +++ b/include/nsgif.h @@ -35,8 +35,6 @@ typedef struct nsgif_info { int loop_max; /** number of animation loops so far */ int loop_count; - - uint16_t delay_min; } nsgif_info_t; /** @@ -69,7 +69,9 @@ struct nsgif { /** currently decoded image; stored as bitmap from bitmap_create callback */ nsgif_bitmap_t *frame_image; + uint16_t delay_min; uint16_t delay_default; + /** number of frames partially decoded */ uint32_t frame_count_partial; @@ -735,7 +737,7 @@ static nsgif_error nsgif__parse_extension_graphic_control( } frame->frame_delay = data[3] | (data[4] << 8); - if (frame->frame_delay < gif->info.delay_min) { + if (frame->frame_delay < gif->delay_min) { frame->frame_delay = gif->delay_default; } @@ -1309,7 +1311,7 @@ nsgif_error nsgif_create(const nsgif_bitmap_cb_vt *bitmap_vt, nsgif **gif_out) gif->decoded_frame = NSGIF_FRAME_INVALID; gif->prev_index = NSGIF_FRAME_INVALID; - gif->info.delay_min = 2; + gif->delay_min = 2; gif->delay_default = 10; *gif_out = gif; |