28 #if !defined(_SPANDSP_T43_H_)
29 #define _SPANDSP_T43_H_
46 T43_IMAGE_TYPE_RGB_BILEVEL = 0,
47 T43_IMAGE_TYPE_CMY_BILEVEL = 1,
48 T43_IMAGE_TYPE_CMYK_BILEVEL = 2,
49 T43_IMAGE_TYPE_8BIT_COLOUR_PALETTE = 16,
50 T43_IMAGE_TYPE_12BIT_COLOUR_PALETTE = 17,
51 T43_IMAGE_TYPE_GRAY = 32,
52 T43_IMAGE_TYPE_COLOUR = 48
55 #if defined(__cplusplus)
60 SPAN_DECLARE(
const char *) t43_image_type_to_str(
int type);
67 SPAN_DECLARE(
int) t43_encode_set_image_width(
t43_encode_state_t *s, uint32_t image_width);
75 SPAN_DECLARE(
void) t43_encode_comment(
t43_encode_state_t *s,
const uint8_t comment[],
size_t len);
82 SPAN_DECLARE(
int) t43_encode_get(
t43_encode_state_t *s, uint8_t buf[],
size_t max_len);
115 uint32_t image_width,
116 uint32_t image_length,
155 uint32_t max_comment_len,
202 #if defined(__cplusplus)
Definition: private/logging.h:34
Definition: private/t43.h:62
Definition: private/t43.h:31
int t43_encode_image_complete(t43_encode_state_t *s)
Check if we are at the end of the current document page.
Definition: t43.c:291
int t43_decode_set_row_write_handler(t43_decode_state_t *s, t4_row_write_handler_t handler, void *user_data)
Set the row handler routine.
Definition: t43.c:812
logging_state_t * t43_encode_get_logging_state(t43_encode_state_t *s)
Get the logging context associated with a T.43 encode context.
Definition: t43.c:331
int t43_decode_set_comment_handler(t43_decode_state_t *s, uint32_t max_comment_len, t4_row_write_handler_t handler, void *user_data)
Set the comment handler routine.
Definition: t43.c:824
int t43_decode_put(t43_decode_state_t *s, const uint8_t data[], size_t len)
Decode a chunk of T.43 data.
Definition: t43.c:739
int t43_encode_release(t43_encode_state_t *s)
Release a T.43 encode context.
Definition: t43.c:373
int t43_decode_free(t43_decode_state_t *s)
Free a T.43 decode context.
Definition: t43.c:924
int t43_decode_release(t43_decode_state_t *s)
Release a T.43 decode context.
Definition: t43.c:917
logging_state_t * t43_decode_get_logging_state(t43_decode_state_t *s)
Get the logging context associated with a T.43 decode context.
Definition: t43.c:859
t43_encode_state_t * t43_encode_init(t43_encode_state_t *s, uint32_t image_width, uint32_t image_length, t4_row_read_handler_t handler, void *user_data)
Prepare to encode an image in T.43 format.
Definition: t43.c:343
uint32_t t43_decode_get_image_width(t43_decode_state_t *s)
Get the width of the image.
Definition: t43.c:841
int t43_encode_restart(t43_encode_state_t *s, uint32_t image_width, uint32_t image_length)
Restart a T.43 encode context.
Definition: t43.c:337
int t43_encode_free(t43_encode_state_t *s)
Free a T.43 encode context.
Definition: t43.c:380
uint32_t t43_decode_get_image_length(t43_decode_state_t *s)
Get the length of the image.
Definition: t43.c:847
t43_decode_state_t * t43_decode_init(t43_decode_state_t *s, t4_row_write_handler_t handler, void *user_data)
Prepare to decode an image in T.43 format.
Definition: t43.c:883
int(* t4_row_write_handler_t)(void *user_data, const uint8_t buf[], size_t len)
Definition: t4_rx.h:46
int(* t4_row_read_handler_t)(void *user_data, uint8_t buf[], size_t len)
Definition: t4_tx.h:34