554{
555 fl::u32 pixels;
556 fl::u32 written = 0;
559
562 }
563
565
568 }
569
570
572 transparency_index, colour_table,
574 data + 1 - gif->
buf);
577 }
578
579 frame_data += (offset_y * gif->
info.
width);
581
582 while (pixels > 0) {
584 frame_data, pixels, &written);
585 pixels -= written;
586 frame_data += written;
588
591 } else {
593 }
594 break;
595 }
596 }
597
598 if (pixels == 0) {
600 }
601
602 return ret;
603}
nsgif_error
LibNSGIF return codes.
static fl::u32 gif__clip(fl::u32 frame_off, fl::u32 frame_dim, fl::u32 image_ext) FL_NOEXCEPT
Get any frame clip adjustment for the image extent.
lzw_result
LZW decoding response codes.
@ LZW_EOI_CODE
Error: End of Information code.
@ LZW_OK_EOD
Success; reached zero-length sub-block.
static nsgif_error nsgif__error_from_lzw(lzw_result l_res) FL_NOEXCEPT
Convert an LZW result code to equivalent GIF result code.
lzw_result lzw_decode_init_map(struct lzw_ctx *ctx, fl::u8 minimum_code_size, fl::u32 transparency_idx, const fl::u32 *colour_table, const fl::u8 *input_data, fl::size input_length, fl::size input_pos) FL_NOEXCEPT
Initialise an LZW decompression context for decoding to colour map values.
lzw_result lzw_decode_map(struct lzw_ctx *ctx, fl::u32 *output_data, fl::u32 output_length, fl::u32 *output_written) FL_NOEXCEPT
Read LZW codes into client buffer, mapping output to colours.
fl::u32 width
width of GIF (may increase during decoding)
fl::u32 height
height of GIF (may increase during decoding)
fl::size buf_len
total number of bytes of GIF data available
void * lzw_ctx
LZW decode context.
const fl::u8 * buf
pointer to GIF data
LZW decompression context.