FFmpeg
Data Structures | Enumerations | Functions | Variables
jpeg2000_parser.c File Reference
#include "parser.h"
#include "parser_internal.h"

Go to the source code of this file.

Data Structures

struct  JPEG2000ParserContext
 

Enumerations

enum  frame_type { jp2_file = 1, j2k_cstream }
 

Functions

static void reset_context (JPEG2000ParserContext *m)
 
static uint8_t info_marker (uint16_t marker)
 
static int find_frame_end (JPEG2000ParserContext *m, const uint8_t *buf, int buf_size)
 Find the end of the current frame in the bitstream. More...
 
static int jpeg2000_parse (AVCodecParserContext *s, AVCodecContext *avctx, const uint8_t **poutbuf, int *poutbuf_size, const uint8_t *buf, int buf_size)
 

Variables

const FFCodecParser ff_jpeg2000_parser
 

Detailed Description

JPEG2000 parser.

Definition in file jpeg2000_parser.c.

Enumeration Type Documentation

◆ frame_type

enum frame_type
Enumerator
jp2_file 
j2k_cstream 

Definition at line 32 of file jpeg2000_parser.c.

Function Documentation

◆ reset_context()

static void reset_context ( JPEG2000ParserContext m)
inlinestatic

Definition at line 50 of file jpeg2000_parser.c.

Referenced by find_frame_end().

◆ info_marker()

static uint8_t info_marker ( uint16_t  marker)
static

Definition at line 67 of file jpeg2000_parser.c.

Referenced by find_frame_end().

◆ find_frame_end()

static int find_frame_end ( JPEG2000ParserContext m,
const uint8_t *  buf,
int  buf_size 
)
static

Find the end of the current frame in the bitstream.

Returns
the position of the first byte of the next frame, or -1

Definition at line 94 of file jpeg2000_parser.c.

Referenced by jpeg2000_parse().

◆ jpeg2000_parse()

static int jpeg2000_parse ( AVCodecParserContext s,
AVCodecContext avctx,
const uint8_t **  poutbuf,
int *  poutbuf_size,
const uint8_t *  buf,
int  buf_size 
)
static

Definition at line 189 of file jpeg2000_parser.c.

Variable Documentation

◆ ff_jpeg2000_parser

const FFCodecParser ff_jpeg2000_parser
Initial value:

Definition at line 215 of file jpeg2000_parser.c.

ff_parse_close
av_cold void ff_parse_close(AVCodecParserContext *s)
Definition: parser.c:298
close
static av_cold void close(AVCodecParserContext *s)
Definition: apv_parser.c:136
jpeg2000_parse
static int jpeg2000_parse(AVCodecParserContext *s, AVCodecContext *avctx, const uint8_t **poutbuf, int *poutbuf_size, const uint8_t *buf, int buf_size)
Definition: jpeg2000_parser.c:189
parse
static int parse(AVCodecParserContext *s, AVCodecContext *avctx, const uint8_t **poutbuf, int *poutbuf_size, const uint8_t *buf, int buf_size)
Definition: apv_parser.c:46
JPEG2000ParserContext
Definition: jpeg2000_parser.c:37
AV_CODEC_ID_JPEG2000
@ AV_CODEC_ID_JPEG2000
Definition: codec_id.h:140
PARSER_CODEC_LIST
#define PARSER_CODEC_LIST(...)
Definition: parser_internal.h:76