43 const uint8_t **poutbuf,
int *poutbuf_size,
44 const uint8_t *buf,
int buf_size)
60 *poutbuf_size = buf_size;
64 while (buf_size || t->
index + needed <= pc->
index) {
71 consumed += tmp_buf_size;
73 buf_size -= tmp_buf_size;
109 return buf_size + consumed;
118 *poutbuf_size = buf_size;
int ff_tak_decode_frame_header(AVCodecContext *avctx, GetBitContext *gb, TAKStreamInfo *ti, int log_level_offset)
Validate and decode a frame header.
AVCodecParser ff_tak_parser
int duration
Duration of the current frame.
static int tak_parse(AVCodecParserContext *s, AVCodecContext *avctx, const uint8_t **poutbuf, int *poutbuf_size, const uint8_t *buf, int buf_size)
int ff_tak_check_crc(const uint8_t *buf, unsigned int buf_size)
static int get_bits_count(const GetBitContext *s)
int ff_combine_frame(ParseContext *pc, int next, const uint8_t **buf, int *buf_size)
Combine the (truncated) bitstream to a complete frame.
av_cold void ff_tak_init_crc(void)
void ff_parse_close(AVCodecParserContext *s)
int overread
the number of bytes which where irreversibly read from the next frame
static av_cold int tak_init(AVCodecParserContext *s)
#define PARSER_FLAG_COMPLETE_FRAMES
main external API structure.
TAK (Tom's lossless Audio Kompressor) decoder/demuxer common functions.
static int init_get_bits(GetBitContext *s, const uint8_t *buffer, int bit_size)
Initialize GetBitContext.
struct TAKParseContext TAKParseContext
#define TAK_MAX_FRAME_HEADER_BYTES