diff options
| author | TazyFoundSoup <gardendistrict0x0@outlook.com> | 2026-03-30 08:42:42 +1100 |
|---|---|---|
| committer | TazyFoundSoup <gardendistrict0x0@outlook.com> | 2026-03-30 08:42:42 +1100 |
| commit | 081889cfca1d984196fabdd6cf645f9f6a9890fb (patch) | |
| tree | bf9cd87c26de1e327d1e71b37aa38782a95b09e0 | |
| parent | 253db94f5a26820673a6ab3901093466f057b19e (diff) | |
fix(bmp): Chunk handler's require context for debug configuration
| -rw-r--r-- | include/tinyff/image/bmp.h | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/include/tinyff/image/bmp.h b/include/tinyff/image/bmp.h index 6cb0ff2..c4bb91b 100644 --- a/include/tinyff/image/bmp.h +++ b/include/tinyff/image/bmp.h @@ -46,7 +46,7 @@ typedef struct { } ff_bmp_ctx; -typedef ff_result (*ff_bmp_section_handler_ptr)(uint8_t *buf, size_t len, ff_bmp_ctx* ctx); +typedef ff_result (*ff_bmp_section_handler_ptr)(ff_ctx* ctx, uint8_t *buf, size_t len, ff_bmp_ctx* bmp_ctx); typedef struct { // Even though the types in bitmaps are invisible (they don't have labels) @@ -58,10 +58,10 @@ typedef struct { ff_bmp_section_handler_ptr handler; } ff_bmp_section_handler; -ff_result ff_bmp_header_handler(uint8_t *buf, size_t len, ff_bmp_ctx* ctx); -ff_result ff_bmp_info_handler(uint8_t *buf, size_t len, ff_bmp_ctx* ctx); -ff_result ff_bmp_color_handler(uint8_t *buf, size_t len, ff_bmp_ctx* ctx); -ff_result ff_bmp_data_handler(uint8_t *buf, size_t len, ff_bmp_ctx* ctx); +ff_result ff_bmp_header_handler(ff_ctx* ctx, uint8_t *buf, size_t len, ff_bmp_ctx* bmp_ctx); +ff_result ff_bmp_info_handler(ff_ctx* ctx, uint8_t *buf, size_t len, ff_bmp_ctx* bmp_ctx); +ff_result ff_bmp_color_handler(ff_ctx* ctx, uint8_t *buf, size_t len, ff_bmp_ctx* bmp_ctx); +ff_result ff_bmp_data_handler(ff_ctx* ctx, uint8_t *buf, size_t len, ff_bmp_ctx* bmp_ctx); const ff_bmp_section_handler ff_bmp_section_handlers[] = { @@ -73,8 +73,8 @@ const ff_bmp_section_handler ff_bmp_section_handlers[] = { {NULL, NULL} // Terminator }; -ff_result ff_bmp_isvalid(ff_stream *stream); -ff_result ff_open_bmp(ff_stream *stream, ff_bmp_ctx **out_ctx, ff_flag require_valid); +ff_result ff_bmp_isvalid(ff_ctx* ctx, ff_stream *stream); +ff_result ff_open_bmp(ff_ctx* ctx, ff_stream *stream, ff_bmp_ctx **out_ctx, ff_flag require_valid); #endif // BMP_H_
\ No newline at end of file |
