Go to the documentation of this file.
   37 #define DIRAC_PARSE_INFO_PREFIX 0x42424344 
   57                           const uint8_t *buf, 
int buf_size)
 
   63         for (
i = 0; 
i < buf_size; 
i++) {
 
   77         for (; 
i < buf_size; 
i++) {
 
  105     static const uint8_t valid_pu_types[] = {
 
  106         0x00, 0x10, 0x20, 0x30, 0x08, 0x48, 0xC8, 0xE8, 0x0A, 0x0C, 0x0D, 0x0E,
 
  107         0x4C, 0x09, 0xCC, 0x88, 0xCB
 
  120     for (
i = 0; 
i < 17; 
i++)
 
  121         if (valid_pu_types[
i] == pu->
pu_type)
 
  138                                int next, 
const uint8_t **buf, 
int *buf_size)
 
  149         if (*buf_size == 0 && pc->
buffer[4] == 0x10) {
 
  151             *buf_size = pc->
index;
 
  191             *buf_size               = next - 9;
 
  205         if ((pu.
pu_type & 0x08) != 0x08) {
 
  213             uint8_t *cur_pu = pc->
buffer +
 
  216             if (
s->last_pts == 0 && 
s->last_dts == 0)
 
  219                 s->dts = 
s->last_dts + 1;
 
  239                        const uint8_t **poutbuf, 
int *poutbuf_size,
 
  240                        const uint8_t *buf, 
int buf_size)
 
  251         *poutbuf_size = buf_size;
 
  264     *poutbuf_size = buf_size;
 
  
Filter the word “frame” indicates either a video frame or a group of audio as stored in an AVFrame structure Format for each input and each output the list of supported formats For video that means pixel format For audio that means channel sample they are references to shared objects When the negotiation mechanism computes the intersection of the formats supported at each end of a all references to both lists are replaced with a reference to the intersection And when a single format is eventually chosen for a link amongst the remaining all references to the list are updated That means that if a filter requires that its input and output have the same format amongst a supported all it has to do is use a reference to the same list of formats query_formats can leave some formats unset and return AVERROR(EAGAIN) to cause the negotiation mechanism toagain later. That can be used by filters with complex requirements to use the format negotiated on one link to set the formats supported on another. Frame references ownership and permissions
 
static int dirac_combine_frame(AVCodecParserContext *s, AVCodecContext *avctx, int next, const uint8_t **buf, int *buf_size)
 
int has_b_frames
Size of the frame reordering buffer in the decoder.
 
void * av_fast_realloc(void *ptr, unsigned int *size, size_t min_size)
Reallocate the given buffer if it is not large enough, otherwise do nothing.
 
static void dirac_parse_close(AVCodecParserContext *s)
 
static int find_frame_end(DiracParseContext *pc, const uint8_t *buf, int buf_size)
 
#define AV_NOPTS_VALUE
Undefined timestamp value.
 
uint64_t_TMPL AV_WL64 unsigned int_TMPL AV_WL32 unsigned int_TMPL AV_WL24 unsigned int_TMPL AV_WL16 uint64_t_TMPL AV_WB64 unsigned int_TMPL AV_RB32
 
static int unpack_parse_unit(DiracParseUnit *pu, DiracParseContext *pc, int offset)
 
Find the end of the current frame in the bitstream.
 
it s the only field you need to keep assuming you have a context There is some magic you don t need to care about around this just let it vf offset
 
static int dirac_parse(AVCodecParserContext *s, AVCodecContext *avctx, const uint8_t **poutbuf, int *poutbuf_size, const uint8_t *buf, int buf_size)
 
#define PARSER_FLAG_COMPLETE_FRAMES
 
#define i(width, name, range_min, range_max)
 
main external API structure.
 
const AVCodecParser ff_dirac_parser
 
@ AV_PICTURE_TYPE_B
Bi-dir predicted.
 
#define DIRAC_PARSE_INFO_PREFIX